cancel
Showing results for 
Search instead for 
Did you mean: 

NoSuchMethodError: java.io.File.canExecute()Z during ant run

activiti-admin
Champ in-the-making
Champ in-the-making
Same error using JDK1.5 on Mac and JDK 1.5 and 1.6 on Win XP.

C:\asamuel\tools\activiti-5.0.alpha1\setup>set JAVACMD=c:\asamuel\tools\Java\jdk1.5.0\bin\java

C:\asamuel\tools\activiti-5.0.alpha1\setup>ant
Buildfile: build.xml
     [echo] Activiti home = ..
     [echo] Activiti version = 5.0.alpha1

h2.install:

internal.classpath.libs:

internal.taskdef.launch:

h2.start:

BUILD FAILED
java.lang.NoSuchMethodError: java.io.File.canExecute()Z
        at org.activiti.impl.ant.LaunchTask.isExecutable(LaunchTask.java:73)
        at org.activiti.impl.ant.LaunchTask.getExecutable(LaunchTask.java:57)
        at org.activiti.impl.ant.LaunchTask.execute(LaunchTask.java:40)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
        at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav
a:106)
        at org.apache.tools.ant.Task.perform(Task.java:348)
        at org.apache.tools.ant.Target.execute(Target.java:357)
        at org.apache.tools.ant.Target.performTasks(Target.java:385)
        at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
        at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExe
cutor.java:41)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
        at org.apache.tools.ant.Main.runBuild(Main.java:758)
        at org.apache.tools.ant.Main.startAnt(Main.java:217)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)

Total time: 1 second
8 REPLIES 8

tombaeyens
Champ in-the-making
Champ in-the-making
canExecute is indeed a Java 6 method.  we'll replace it.  thanks!

activiti-admin
Champ in-the-making
Champ in-the-making
Hi Tom,

I'm getting the same error. Is there a solution for this or do I just have to wait?

Silvion Moesan
Senior Consultant Alfresco

jeff1
Champ in-the-making
Champ in-the-making
hi, silvion, if you can't wait, set java command point to jdk1.6_home/bin/java.exe and try
tom will fix this and make it jdk1.5 capacitable

activiti-admin
Champ in-the-making
Champ in-the-making
Thanks for the feedback. I'd changed the JAVA_HOME, but forgot the addition to PATH.

Now it works fine, except the activiti-modeler, which doesn't start at all.

Kind regards,

Silvion Moesan
Senior Alfresco Consultant

activiti-admin
Champ in-the-making
Champ in-the-making
Silvion, what do you mean by "doesn't start at all"?

Did you read that "How to ask questions the smart way" article?

activiti-admin
Champ in-the-making
Champ in-the-making
I mean:

The activiti-modeler.war file is placed in the tomcat/webapps folder, however when I try to go to http://localhost:8080/activiti/modeler/p/explorer I don't see the modeler and I see nothing in the logfiles.

Silvion Moesan
Senior Alfresco Consultant

wuarron
Champ in-the-making
Champ in-the-making
I get the same error on alpha-3. must use jdk6?

tombaeyens
Champ in-the-making
Champ in-the-making
yes.