When building the project Ant'om I get the error:

D: \ PS2 \ Projects \ Project \ MainModule \ mainmodule.xml: 227: c: \ jdk1.5 does not exist. at org.apache.tools.ant.types.AbstractFileSet.getDirectoryScanner (AbstractFileSet.java:483) at org.apache.tools.ant.types.FileSet.iterator (FileSet.java:69) at org.apache.tools.ant .types.resources.Union.getCollection (Union.java:123) at org.apache.tools.ant.types.resources.Union.getCollection (Union.java:107) at org.apache.tools.ant.types.resources .BaseResourceCollectionContainer.cacheCollection (BaseResourceCollectionContainer.java:265) at org.apache.tools.ant.types.resources.BaseResourceCollectionContainer.iterator (BaseResourceCollectionContainer.java:142) at org.apache.tools.ant.http.h.ty.ty.http.http.html, please click here. .java: 710) at org.apache.tools.ant.types.Path.iterator (Path.java:704) at org.apache.tools.ant.types.resources.Union.getCollection (Union.java:123) at org.apache.tools.ant.types.resources.Union.getCollection (Union.java:107) at org.apache.tools.ant.types.resources.BaseResourceCollectionContainer.cacheCollection (BaseResourceCollectionContainer.java:265) at org.apache. tools.ant.types.resources .BaseResourceCollectionContainer.iterator (BaseResourceCollectionContainer.java:142) at org.apache.tools.ant.types.Path.iterator (Path.java:710) at org.apache.tools.ant.types.Path.iterator (Path.java : 704) at org.apache.tools.ant.types.resources.Union.getCollection (Union.java:123) at org.apache.tools.ant.types.resources.Union.list (Union.java:86) at org.apache.tools.ant.types.Path.list (Path.java.378) at org.apache.tools.ant.types.Path.addExisting (Path.javaι31) at org.apache.tools.ant types.Path.addExisting (Path.javaUE19) at org.apache.tools.ant.types.Path.concatSpecialPath (Path.javainter80) at org.apache.tools.ant.types.Path.concatSystemClasspath (Path. java: 532) at org.apache.tools.ant. at org.apache.tools.ant.taskdefs.compilers.DefaultCompilerAdapter.setupModernJavacCommand lineSwitches (DefaultCompilerAdapter.javaUE40) at org.apache.tools.ant.taskdefs.compilers.JavacExternal.execute (JavacExternal.java:49) at org.apache.tools.ant.taskdefs.Javac.compile (Javac.java: 1134) at org.apache.tools.ant.taskdefs.Javac.execute (Javac.java:912) at org.apache.tools.ant.UnknownElement.execute (UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor8.invoke (Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl. (DispatchUtils.java:106) at org.apache.tools.ant.Task.perform (Task.java=48) at org.apache.tools.ant.Target.execute (Target.java²90) at org.apache. tools.ant.Target.performTasks (Target.java[11) at org.apache.tools.ant.Project.executeSortedTargets (Project.java:1399) at org.apache.tools.ant.Project.executeTarget (Project.java: 1368) at org.apache.tools.ant.helper.DefaultExecutor.executeTargets (DefaultExecutor. java: 41) at org.apache.tools.ant.Project.executeTargets (Project.java:1251) at org.apache.tools.ant.Main.runBuild (Main.java:809) at org.apache.tools.ant .Main.startAnt (Main.java:217) at org.apache.tools.ant.Main.start (Main.java:180) at org.apache.tools.ant.Main.main (Main.java:268) at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke.A.O. invoke (Method.java Redu92) at com.intellij.rt.ant.execution.AntMain2.main (AntMain2.java:30)

In this case, line 227, which is indicated as the one in which the error occurred, looks like this:

executable="C:/Program Files/Java/jdk1.5/bin/javac" 

from the task:

 <javac destdir="${castorbeans.output.dir}" debug="${compiler.debug}" nowarn="${compiler.generate.no.warnings}" memorymaximumsize="${compiler.max.memory}" fork="true" executable="C:/Program Files/Java/jdk1.5/bin/javac"> <compilerarg line="${compiler.args.castorbeans}"/> <bootclasspath refid="castorbeans.module.bootclasspath"/> <classpath refid="castorbeans.module.classpath"/> <src refid="castorbeans.module.sourcepath"/> <patternset refid="excluded.from.compilation.castorbeans"/> </javac> 

What is the reason that the path to jdk is defined as " c:\jdk1.5 " and not " C:/Program Files/Java/jdk1.5/bin/javac "?

  • spaces in the path can cause very strange errors. Try to specify the path without a space. - Mikhail Vaysman

0