How we can set path path and classpath into an ant build file?
Answer / Tannu Singh
The "path" property in Apache Ant is used to set the system PATH environment variable. This can be useful for adding directories to the PATH that contain executables that will be called during the build process.nnFor example:n<property name="java.home" location="/usr/lib/jvm/java-1.8.0" />n<path id="my.classpath">n <pathelement path="${java.home}/lib/tools.jar" />n</path>nnThe "classpath" property can be used to specify the classpath for a Java compile or run task. This can include directories and JAR files containing classes that need to be compiled or executed.nnFor example:n<javac srcdir="src" destdir="bin" classpath="lib/my-library.jar">n...n</javac>nIn this example, the "classpath" attribute specifies that the "my-library.jar" file should be included in the classpath for the Java compilation task."
| Is This Answer Correct ? | 0 Yes | 0 No |
How to hide password input?
Can you define build tool?
How many types of build tool you know?
Explain how to import .jar files?
Explain how to compile using ant script?
How you can explain ant property?
What is advantage of ant 1.7.1?
How to use ant-contrib tasks?
How can I use ant to run a java application?
Explain how to debug my ant script?
How you can prepare a project in ant?
What are the capabilities of ant?