i am facing an issue in an ant build xml during compile process. My Ant command is pretty simple:
<target name="compile" description="Compilation target">
<javac srcdir="src" destdir="JARbuild">
<compilerarg value="-Xlint:deprecation"/>
</javac>
</target>
However i always get the following error
error: cannot find symbol
private final static JSObject jso = JSObject.getWindow(JMain.getInstance());
I am able to compile my project with netbeans ide, without running into an error, since the corresponding jar file (plugin.jar) is recognized as a library. I tried to add the library to classPath by setting sth. similar to:
<classpath>
<path>
<pathelement location="C:\Program Files\Java\jre7\lib\plugin.jar" />
</path>
</classpath>
However error still occurs. Somebody got a solution? Thanks.
Have you tried using escaped-backlashes, or unix-style seprators in your Windows path?
Eg
<pathelement location="C:\\Program Files\\Java\\jre7\\lib\\plugin.jar"
or
<pathelement location="C:/Program Files/Java/jre7/lib/plugin.jar"
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.