Compiling with JRockit using ant

I am considering switching to JRockit.
Our java code is compiled using ant, with the 'javac' task.
The javac task has an option to invoke different compilers:
- classic (the standard compiler of JDK 1.1/1.2) – javac1.1 and javac1.2 can be used as aliases.
- modern (the standard compiler of JDK 1.3/1.4/1.5/1.6) – javac1.3 and javac1.4 and javac1.5 and javac1.6 can be used as aliases.
- jikes (the Jikes compiler).
etc
The Jrockit compiler is not on this list.
I have found a suggestion (http://www2.sys-con.com/ITSG/virtualcd/Java/archives/0811/pepperdine/index.html) to use an exec call as a workaround,
but are there any alternatives? I could perhaps persuade ant to use JRockit by deinstalling any other JDK's and pointing JAVA_HOME to JRockit;
what I want however is to keep the option to use different compilers.
Has anyone got any suggestions?

The javac compiler bundled with JRockit is the exact same one that you get with the Sun JDK. Oracle licenses the JDK (class libraries, tools, etc) from Sun. So I would just set JAVA_HOME to point at JRockit as you suggest.
Henrik

Similar Messages

  • How to compile Java files using Ant in Eclipse

    Hi All ,
    I would like to compile all Java files using Ant in Eclipse.Since am very new to Ant and Eclipse can someone help me to create a build.xml file and let me know how to compile all the java files.
    For ex , I have placed my java files inside the path C:\HEC\Terab.Initially the Terab folder holds 7 jar files which i had decompiled using JD compiler and placed the unzipped 7 folders (which contains the java files ).Now i have imported the HEC project into Eclipse using New ->Project ->Java Project.after importig it throwed me an error saying missing jar files.again i copied the jar files and placed inside Terab folder with other 7 folder.
    Now How i can compile the java files and convert in to class files.Then after compiling the files i will again need to jar all the 7 folder.
    Please tell me the steps i need to follow.How to write an build.xml file ? where i should keep it ? only one build.xml file is enough or should i write 7 build.xml file for each folder ? Please help me out...
    Thanks & Regards
    Kar1983

    put it another way, what I am trying to do is to compile David Brackeen's ch 18 code from his book. The java sourse files can be downloaded here:
    http://www.brackeen.com/javagamebook/
    my question is that how would I complie all of these file so that I can get the program in ch18src\src\com\brackeen\javagamebook\test\ to run?

  • Problem compiling in Linux using ant

    Hi,
    I have a problem using ant in Linux.
    When I build my application using ant in Windows it works fine, but when I try to build the same application with ant in Linux it gives me the following exception:
    /identifier/MidiReader.java:5: error: Class or interface `javax.sound.midi.Sequence' not found in import.
    I have already checked and the 'javax.sound.midi.Sequence' exists in import.
    Can anybody help me?
    Regards,
    David

    In your javac task (in Ant), you need to explicitly include any external JAR's required for compilation (see ant.apache.org's docs for info). Importing them in a Java source file does not tell Ant where to locate the JAR for linking.
    - Saish
    "My karma ran over your dogma." - Anon

  • Compiling flex application using ANT throws error

    Hi i m tryin to compile my flex project using ANT, and i have used [Embed(source="/assets/images/inuse/phonering.png")] lot of places in my project. How can i solve this error. I have lot of swf file also for css.
    Thanks in advance
    Rupam

    OK, I checked my build script and remember having this problem. I'm deploying a war file that contains some java EE and flex code. So my solutions does not apply to your case, but check out this blog post.
    http://www.olocity.com/blogs/2009/05/13/adobe-flex-ant-builds/
    Also this is probably helpful
    http://www.mail-archive.com/[email protected]/msg123564.html//www.mail-archive.com/[email protected]/msg123564.html

  • CompileException: Error compiling web service (using ant jwsc)

    Hi,
    I try to use the ant task jwsc to create my portable artefacts for a web service.
    Unfortunately I get the following exception:
    BUILD FAILED
    C:\Sun\jwsdp-2.0\apache-ant\bin\build.xml:7: weblogic.wsee.tools.jws.build.CompileException: Error compiling web service: C:\Sun\jwsdp-2.0\apache-ant\bin\src\test\WsTest.java
    I do not know why the ant task can not compile my jws file (shown below) whereas Eclipse can!
    package test;
    import javax.jws.WebService;
    @WebService (name="WsTestName", serviceName="WsTestServiceName")
    public class WsTest {
    * @param name
    * @return Say hello to the person.
    public String sayHello(String name) {
    return "Hello, " + name + "!";
    I hope somebody can help me.
    Thanks
    Franz

    I thought I would post an update since I found a solution. The problem was a ClassCast exception in a part of the SSL stack, that wanted to use the ant BuildException class. This has the effect of hiding the real issue which was that the SSL connection was not successfully occuring. The real problem was that the SSL connection started with a WSDL retrieved via SSL, but the connection for the port was through a username/password. When a username/password is used to create a port, the WL stack falls back to http and causes a ClassCast exception on weblogic.wsee.connection.transport.http.HttpTransportInfo. The solution is to create an https transport object when the service impl is created:
    HttpsTransportInfo transport = new HttpsTransportInfo ();
    transport.setUsername (user.getBytes ());
    transport.setPassword (pass.getBytes ());
    gServiceImpl = new PersistenceManagerService_Impl (url, transport);
    and to create the port without parameters:
    port = getServiceImpl ().getPersistenceManagerServicePort ();
    This allows one-way SSL with username/password for the connection.

  • Compiling with mxmlc Using CS3 Components

    Hi, I would like to use the Flex SDK 3.0 to compile a project
    which currently compiles successuflly in Flash CS3 (because it's
    quicker). I am importing assets from swfs using [Embed ...] tags
    without any problems. I can also use CS3 components by exporting
    them to an SWC file, adding that to the library path for mxmlc and
    then reating new instances of them in AS. However, I have some
    assets which contain components which were statically placed within
    them in the CS3 IDE and given an instance name. These are not
    working. For example, the buttons I have typed as
    fl.controls.Button in the AS code but I get a run time error saying
    that it can't coerce a MovieClip instance into a Button. Does
    anyone have any ideas? The CS3 compiler is driving me nuts because
    it's so slow. I used to use MTASC and am looking for something
    similar to work with AS 3.0.

    I agree that compiler is painfully slow, especially when you use a library and have some (one is enough) projects dependendant upon it. Minor change in library starts compiling everything for a few minutes . This really slows development process in later stages. Adobe should do something about this.

  • Error while compiling using ant

    While compiling a project using ant, I got an error that a particular method is missing in the class.
    But the method is actually present in the class.
    What may be the problem?. Any link will be useful.
    Regards,
    Joshua

    Its compiling and running fine in eclipse.

  • Compiling App with JRockit

    All,
    I've installed JRockit 5.0 SP1 on my development machine and updated my domain to use JRockit. Now, If I change the Application Properties to specify the JRockit path for "Java Home:" will this cause Workshop to use JRockit to compile rather than the SUN JDK?
    I exported the ANT build file after making the path change and I see the JRockit jars in the classpath...
    ${weblogic.home}/../jrockit-jdk1.5.0_02/jre/lib/rt.jar;
    ${weblogic.home}/../jrockit-jdk1.5.0_02/lib/tools.jar
    but does that mean that the JRockit java compiler is being used?
    Thanks,
    Bill Stephens

    Thanks for your help Anton. I could manage it by just adding the bundle file to my compiler line in this way:
    $"$COMPILER/adt" -package -target ane bin/MyANE.ane extension.xml -swc MyANE.swc -platform iPhone-ARM library.swf -platformoptions platform.xml libMyANE.a ExternalFramework.framework File.bundle -platform default library.swf
    In this way when the ANE is compiled with the iOS APP the File.bundle is added at the top of the IPA file.

  • JSP precompilation and my .java files compilation issues /  building WAR file using ANT

    Hello.
    I am new to working with WAR files and the whole process of it. A little
    background on what we are using. We are using, WLS 6.1 SP3. I am using the
    ant.bat that is supplied in the bin directory of the WLS install.
    I am trying to work with ANT and getting it to build the file. I am making
    progress, but at a point where I am having trouble getting my java code
    files to compile using ant. I am having one issue and looking to do one
    other item.
    1) I would like to precompile the JSPs if possible prior to putting into the
    WAR file. Not sure if this is done or not, but there was a utility when I
    was working with ibm's app server that gave us the ability to do a batch
    complile. Was thinking that maybe a similair concept is possibly here.
    2) Having issue getting ant to compile code properly. In the compile
    section of the build.xml file for ant, I tell it where the source files are,
    and the destionation folder for the compiled class files. I then try to set
    the classpath so that it finds the .jar files that are necessary for my
    source files to complile. But, it won't find them. And not sure how come.
    I may be going about this all wrong, but dont know. Here is the compile
    section of the build.xml I am using:
    <target name="compile" depends="prepare">
    <javac srcdir="classes" destdir="${deploy.home}/WEB-INF/classes"
    classpath="$(lib.home)"
    debug="on" optimize="on" deprecation="off"/>
    </target>
    One note, I've tried many different items in the classpath line, which
    don't work. if I do *.jar it fails at complie time, invalid argument. As
    well as if I use *.* and so on. if I list the explicit file names, it still
    doesn't seem to find them.
    I was wondering if anyone could help, if you need anymore information let me
    know, I can send the entire build.xml if necessary. I may be missing
    items, seeing that this is my first try at using ANT.
    Any help is appreciated and thanks in advance. Hopefully not sounding too
    off the wall. Hopefully get some clarification and understanding.
    Thank you.
    Kevin.

    Kevin Price wrote:
    Hello.
    I am new to working with WAR files and the whole process of it. A little
    background on what we are using. We are using, WLS 6.1 SP3. I am using the
    ant.bat that is supplied in the bin directory of the WLS install.
    I am trying to work with ANT and getting it to build the file. I am making
    progress, but at a point where I am having trouble getting my java code
    files to compile using ant. I am having one issue and looking to do one
    other item.
    1) I would like to precompile the JSPs if possible prior to putting into the
    WAR file. Not sure if this is done or not, but there was a utility when I
    was working with ibm's app server that gave us the ability to do a batch
    complile. Was thinking that maybe a similair concept is possibly here.you can use weblogic.jspc
    http://e-docs.bea.com/wls/docs70/jsp/reference.html#57794
    or just set the precompile flag in weblogic.xml
    You can configure WebLogic Server to precompile your JSPs when a Web
    Application is deployed or re-deployed or when WebLogic Server starts up
    by setting the precompile parameter to true in the <jsp-descriptor>
    element of the weblogic.xml deployment descriptor.
    >
    2) Having issue getting ant to compile code properly. In the compile
    section of the build.xml file for ant, I tell it where the source files are,
    and the destionation folder for the compiled class files. I then try to set
    the classpath so that it finds the .jar files that are necessary for my
    source files to complile. But, it won't find them. And not sure how come.
    I may be going about this all wrong, but dont know. Here is the compile
    section of the build.xml I am using:
    <target name="compile" depends="prepare">
    <javac srcdir="classes" destdir="${deploy.home}/WEB-INF/classes"
    classpath="$(lib.home)"
    debug="on" optimize="on" deprecation="off"/>
    </target>
    maybe because you are not using curly braces there on lib.home??
    if you do it the way above, you would have to list all your jars
    classpath="$(lib.home)\lib1.jar:$(lib.home)\lib2.jar"
    or you can nest
    <javac srcdir="classes" destdir="${deploy.home}/WEB-INF/classes"
    debug="on" optimize="on" deprecation="off">
         <classpath>
              <fileset dir="${lib.home}" includes="*.jar" />
         </classpath>
    </javac>
    One note, I've tried many different items in the classpath line, which
    don't work. if I do *.jar it fails at complie time, invalid argument. As
    well as if I use *.* and so on. if I list the explicit file names, it still
    doesn't seem to find them.
    I was wondering if anyone could help, if you need anymore information let me
    know, I can send the entire build.xml if necessary. I may be missing
    items, seeing that this is my first try at using ANT.
    Any help is appreciated and thanks in advance. Hopefully not sounding too
    off the wall. Hopefully get some clarification and understanding.
    Thank you.
    Kevin.

  • Problem in compiling with ant?

    Hi,
    I have problem with compiling using ant ..i have build file...and properly place directories.......
    C:/>ant build
    It's giving an error as "Exception in thread "main" java.lang.NoClassDefFoundError: build"
    can any one help me to solve this problem

    Cross-Post:
    http://forum.java.sun.com/thread.jspa?threadID=589924&tstart=0

  • Cannot make .war file using tomcat with eclipse and ant

    i have made all necesary configuration for deploying application using eclipse and ant for the tomcat server.
    when i start the server by clicking the tomcat icon on eclipse toolbar, the message is prompted that "missing application web.xml and using defaults". i have placed the web.xml file in the web/WEB-INF directory of the source project directory.
    also when i use ant by right-clicking on the build.xml file and choose Run as ant.. the process creates a desired .war file in webapps folder of the tomcat server but that war file does not works.
    where is the error i cannot figure out.
    am attaching the code of build.xml for reference.
    please help.
    build.xml:-
    <project name="BecilCTI" default="compile" basedir=".">
    <property file="build.properties"/>
    <property file="${user.home}/build.properties"/>
    <property name="app.name" value="BecilCTI"/>
    <property name="app.path" value="/${app.name}"/>
    <property name="app.version" value="0.1-dev"/>
    <property name="build.home" value="${basedir}/build"/>
    <property name="catalina.home" value="c:/Tomcat_5.5"/> <!-- UPDATE THIS! -->
    <property name="dist.home" value="${basedir}/dist"/>
    <property name="docs.home" value="${basedir}/docs"/>
    <property name="manager.url" value="http://localhost:8080/manager"/>
    <property name="src.home" value="${basedir}/src"/>
    <property name="web.home" value="${basedir}/web"/>
    <property name="compile.debug" value="true"/>
    <property name="compile.deprecation" value="false"/>
    <property name="compile.optimize" value="true"/>
    <!--<property name="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter"/>-->
    <path id="compile.classpath">
    <!-- Include all elements that Tomcat exposes to applications -->
    <pathelement location="${catalina.home}/common/classes"/>
    <fileset dir="${catalina.home}/common/endorsed">
    <include name="*.jar"/>
    </fileset>
    <fileset dir="${catalina.home}/common/lib">
    <include name="*.jar"/>
    </fileset>
    <pathelement location="${catalina.home}/shared/classes"/>
    <fileset dir="${catalina.home}/shared/lib">
    <include name="*.jar"/>
    </fileset>
    </path>
    <target name="all" depends="clean,compile"
    description="Clean build and dist directories, then compile"/>
    <target name="clean"
    description="Delete old build and dist directories">
         <echo message="Cleaning all dirs."/>
    <delete dir="${build.home}"/>
    <delete dir="${dist.home}"/>
    </target>
    <target name="compile" depends="prepare"
    description="Compile Java sources">
    <!-- Compile Java classes as necessary -->
    <mkdir dir="${build.home}/WEB-INF/classes"/>
    <javac srcdir="${src.home}"
    destdir="${build.home}/WEB-INF/classes"
    debug="${compile.debug}"
    deprecation="${compile.deprecation}"
    optimize="${compile.optimize}">
    <classpath refid="compile.classpath"/>
    </javac>
    <!-- Copy application resources -->
    <copy todir="${build.home}/WEB-INF/classes">
    <fileset dir="${src.home}" excludes="**/*.java"/>
    </copy>
    </target>
    <target name="dist" depends="compile"
    description="Create binary distribution">
    <!-- Copy documentation subdirectories
    <mkdir dir="${dist.home}/docs"/>
    <copy todir="${dist.home}/docs">
    <fileset dir="${docs.home}"/>
    </copy> -->
    <!-- Create application JAR file -->
    <jar jarfile="${catalina.home}/webapps/${app.name}.war"
    basedir="${build.home}"/>
    <!-- Copy additional files to ${dist.home} as necessary -->
    </target>
    <target name="install" depends="compile"
    description="Install application to servlet container">
    <deploy url="${manager.url}"
    username="${manager.username}"
    password="${manager.password}"
    path="${app.path}"
    localWar="file://${build.home}"/>
    </target>
    <target name="list"
    description="List installed applications on servlet container">
    <list url="${manager.url}"
    username="${manager.username}"
    password="${manager.password}"/>
    </target>
    <target name="prepare">
    <!-- Create build directories as needed -->
    <mkdir dir="${build.home}"/>
    <mkdir dir="${build.home}/WEB-INF"/>
    <mkdir dir="${build.home}/WEB-INF/classes"/>
    <!-- Copy static content of this web application -->
    <copy todir="${build.home}">
    <fileset dir="${web.home}"/>
    </copy>
    <mkdir dir="${build.home}/WEB-INF/lib"/>
    </target>
    <target name="reload" depends="compile"
    description="Reload application on servlet container">
    <reload url="${manager.url}"
    username="${manager.username}"
    password="${manager.password}"
    path="${app.path}"/>
    </target>
    <target name="remove"
    description="Remove application on servlet container">
    <undeploy url="${manager.url}"
    username="${manager.username}"
    password="${manager.password}"
    path="${app.path}"/>
    </target>
    </project>

    So is context.xml actually overwriting the settings found in server.xml?I think so. The way I understand it is the the context.xml file saves you from having to edit server.xml. It is preferred for each web app to do its own config, rather than lumping them all together in server.xml.
    And what would be the best way to create the war file? IAt its heart, a WAR is just a zip file with its contents laid out in according to the specification of a web application directory structure.
    So the simplest way to make a war file is to zip up your directory structure with a tool like winzip, and rename it to be myApp.war.
    Regarding ant, I would recommend you take a look through [url http://jakarta.apache.org/tomcat/tomcat-4.1-doc/appdev/index.html
    ]this tutorial. It explains the basics of website layout, configuration and deployment.
    On [url http://jakarta.apache.org/tomcat/tomcat-4.1-doc/appdev/source.html] this page  in particular, it includes a link to a basic ant file that you can use as a starting point.
    Cheers,
    evnafets

  • How to compile a class from a Servlet using ant!!!

    Hi I have the following problem:
    I have a Servlet that must compile a java class.
    Here is the code that i use to compile:
    File buildFile = new File(build.xml path);
    String[] arg = { "-buildfile", buildFile.toString(), "compile" };
    Properties userProps = null;
    ClassLoader loader = ClassLoader.getSystemClassLoader();
    Main.start(arg, userProps, loader);
    The build.xml file was written correctly, infact if i lunch the command ant by dos it is correctly done.
    When I put my application in tomcat/webapps and try to compile with code above I have the following error:
    BUILD FAILED C:\......: Could not create task or type of type: property.
    Ant could not find the task or a class this task relies upon.
    This is common and has a number of causes; the usual
    solutions are to read the manual pages then download and
    install needed JAR files, or fix the build file:
    - You have misspelt 'property'.
    Fix: check your spelling.
    - The task needs an external JAR file to execute
    and this is not found at the right place in the classpath.
    Fix: check the documentation for dependencies.
    Fix: declare the task.
    - The task is an Ant optional task and the JAR file and/or libraries implementing the functionality were not found at the time you yourself built your installation of Ant from the Ant sources.
    Fix: Look in the ANT_HOME/lib for the 'ant-' JAR corresponding to the task and make sure it contains more than merely a META-INF/MANIFEST.MF.
    If all it contains is the manifest, then rebuild Ant with the needed libraries present in ${ant.home}/lib/optional/ , or alternatively,
    download a pre-built release version from apache.org
    - The build file was written for a later version of Ant Fix: upgrade to at least the latest release version of Ant
    - The task is not an Ant core or optional task and needs to be declared using <taskdef>.
    - You are attempting to use a task defined using <presetdef> or <macrodef> but have spelt wrong or not defined it at the point of use
    Remember that for JAR files to be visible to Ant tasks implemented in ANT_HOME/lib, the files must be in the same directory or on the classpath
    Please neither file bug reports on this problem, nor email the Ant mailing lists, until all of these causes have been explored, as this is not an Ant bug.

    Java code Snippet
    import org.apache.tools.ant.*;// ant.jar
    String SourceDir="c:\java";
         String DestinationDir="c:\classes";
         Project project = new Project();
         try
    String baseDir = getServletContext().getRealPath( "/WEB-INF/build/");//Build.xml should be in this folder or else make use of the build folder here
         File buildFile = new File( baseDir, "build.xml");
         project.setUserProperty( "SourceDir", SourceDir);
         project.setUserProperty( "DestinationDir", DestinationDir);
         project.setUserProperty( "ant.file", buildFile.getAbsolutePath());
         project.setBaseDir( new File( baseDir));
         project.init();
         ProjectHelper.configureProject( project, buildFile);
         project.executeTarget(project.getDefaultTarget());
         catch (Exception e)
    Build.xml
    <?xml version="1.0"?>
    <project name="Sample" default="compile" basedir=".">
         <property name="SrcDir" value="${SourceDir}"/>
         <property name="DestnDir" value="${DestinationDir}"/>
         <target name="compile">
              <javac srcdir="${SrcDir}" destdir="${DestnDir">
                   <classpath > <!-- If any supporting jars required to compile the file add this-->
                        <fileset dir="${SrcDir}" includes="*.jar" />
                   </classpath>
              </javac>
         </target>
    </project>

  • Compiling with external JARs using Eclipse

    I've spent 3 days on this and I still don't seem to be any nearer solving the problem. I am using a couple of external JAR files within my project and everything is working fine within the IDE, it's when I come to compile my own JAR that I'm having problems. I've tried created my JAR by choosing file->export, but it doesn't seem to pull in the external JARs. My class paths must be correct as I can run it within the IDE, but I'm missing something.
    Next I discovered ANT and had a play with that. After some toil I got it to generate a JAR, but it has two problems. 1. The manifest file cannot be found, but let's forget about that for now, as I haven't really looked into it. 2. The generated JAR is only 250Kb, when (if the external JARs are packaged with it) it should be closer to 5Mb. Again I've set my class paths in the External Tools dialog, but still nothing.
    Could someone please try and point me in the right direction. I've even spent a couple of hours at Borders reading up on ANT and Eclipse, that where my ANT script came from, but it hasn't got me the result I need. If it's any help my build.xml is below
    <?xml version="1.0" encoding = "UTF-8"?>
    <project name="C_G" default="Main Build" basedir=".">
        <property name="bin" location="bin"/>
        <property name="src" location="."/>
        <property name="jardir" location="${bin}/lib"/>
        <property name="jarfile" location="${jardir}/c_g.jar"/>
        <property name="build.compiler"
        value="org.eclipse.jdt.core.JDTCompilerAdapter"/>
        <target name="Main Build" depends="Initialize, Compile, Jar">
            <echo message="Ant Building"/>
        </target>
        <target name="Initialize">
            <delete dir="${bin}"/>
            <delete dir="${jardir}"/>
            <mkdir dir="${bin}"/>
            <mkdir dir="${jardir}"/>
        </target>
        <target name="Compile" depends="Initialize">
            <javac srcdir="${src}"
                destdir="${bin}">
            </javac>
        </target>
        <target name="Jar" depends="Initialize, Compile">
            <jar destfile="${jarfile}" basedir="${bin}"/>
        </target>
    </project>

    Damn it, so I do have to tackle the 'manifest not
    found problem' first then. I would have though
    Eclipse would have made a better job at making the
    manifest file.All I can say: RTFM. This is not an Eclipse support forum. Maybe it does, and you use some incorrect settings.
    I just placed it into the root of the JAR, but when I
    run it can't find itIt doesn't belong there. It goes into a directory named META-INF

  • "Error running javac.exe compiler" when using ant to compile Eclipse plugin

    Hi
    I encounter an error "Error running C:\jdk1.5.0_06\bin\javac.exe compiler" when building my project using ant1.7.
    My project has 10 eclipse plugins, and each plugin is compiled by invoking following ant target
    <!-- ===================================================================
    Compile specified plugin
         target parameters:
              param.plugin.dir: the plugin directory
              param.plugin.targetJarFile: the name of jar file for the given plugin
              param.plugin.src.dir: the folder name of source codes. Note: it is relative path name
              param.fork: indicate if another process is forked to run javac
    =================================================================== -->
    <target name="compilePlugin">
         <!-- Prepare compile environment -->
         <!-- Delete obsolete build folder -->
         <delete dir="${param.plugin.dir}/${build.dir}" quiet="true"/>
         <!-- Delete obsolete jar file -->
         <delete file="${param.plugin.dir}/${param.plugin.targetJarFile}" quiet="true"/>
         <mkdir dir="${param.plugin.dir}/${build.dir}"/>
         <!-- Compile source codes -->
         <javac      srcdir="${param.plugin.dir}/${param.plugin.src.dir}"
                   destdir="${param.plugin.dir}/${build.dir}"
                   failonerror="${javacFailOnError}"
                   verbose="${javacVerbose}"
                   debug="${javacDebugInfo}"
                   deprecation="${javacDeprecation}"
              optimize="${javacOptimize}"
                   source="${javacSource}"
                   target="${javacTarget}"     
                   fork="${param.fork}" memoryInitialSize="256m" memoryMaximumSize="512m">
              <classpath refid="compile.classpath" />
         </javac>
         <!-- Create plugin jar file -->
         <copy todir="${param.plugin.dir}/${build.dir}" failonerror="true">
              <fileset dir="${param.plugin.dir}/${param.plugin.src.dir}" excludes="**/*.java, **/package.htm*" />
         </copy>
         <jar jarfile="${param.plugin.dir}/${param.plugin.targetJarFile}" basedir="${param.plugin.dir}/${build.dir}"/>
         <delete dir="${param.plugin.dir}/${build.dir}" quiet="true"/>
    </target>
    Since each of first 9 plugins contains less than 500 java source files, we always set "param.fork" to false when invoking this ant target.
    For the 10th plugin, it has about 1000 source files. If we set "param.fork" to false, we will get the error "Error running javac.exe compiler". So we have to set "param.fork" to true when compiling it. This week, this plugin contains about 1250 files and we get the same error again when compiling it. I tried to increase the "memoryMaximumSize" to "768", but still couldn't get through it.
    BTW, There are about 150 jar files in our classpath for compiling plugins. Do many jar files cause this problem?
    Any help is highly appreciated.
    Many thanks
    Oceanman

    I encountered a very similar error and I was able to resolve it by removing the following parameters from the javac task:
    fork="${param.fork}"
    memoryInitialSize="256m"
    memoryMaximumSize="512m"My values were not the same as yours, before I removed them, the values were set to:
    fork="true"
    memoryInitialSize="256m"
    memoryMaximumSize="256m" Not sure why this fixed my problem but it did. I was using Ant 1.7 and Java 1.6_07 hope this helps.

  • Using Ant with Oracle

    I am trying to create tables using Ant build scripts for deployment purposes. I am able to create the schema and the sequences. It seems to be able to create tables except for triggers. I cannot create triggers after creating the tables. Ant displays an error whenever it reaches the part of a script which involves the trigger part. I am using the Oracle JDBC thin driver with Ant. Am I missing any files that should be included to support triggers? Is there a work-aorund? I appreciate the help...
    Thanks!

    First of all, for me, this is a complete wrong approach. You should just issue a "drop table <your_tablename>;" and then look if it succeded or not. You can catch the exception and handle it, so the build will not fail.
    If you really want do it with PL/SQL, then never do it the way you have tried to do it. Read the net about SQL injection.
    Remember, dbms_output will write to an output buffer on the server, not on your client. The client had to read from the buffer.
    set serveroutput on is a SQL*Plus command, it will fail if not issued there.
    It would probably make sense to return a value, indicating if the command succeeded or not. So you could code something like:
    SQL> get t
      1  create or replace function sidd ( p_tablename in varchar2 ) return varchar2 as
      2  begin
      3    for rec in ( select table_name
      4                 from   user_tables
      5                 where  table_name = p_tablename
      6               ) loop
      7      begin
      8        execute immediate 'drop table ' || rec.table_name;
      9        dbms_output.put_line( 'table ' || rec.table_name || ' dropped.' );
    10        return 'SUCCEEDED';
    11      exception
    12        when others then
    13          dbms_output.put_line( 'table ' || rec.table_name || ' coud not be dropped.' );
    14          return 'FAILED';
    15      end;
    16    end loop;
    17    return 'FAILED';
    18* end;
    SQL> /
    Function created.
    SQL> exec :ret := sidd ( 'my_t1' );
    PL/SQL procedure successfully completed.
    RET
    FAILED
    SQL> exec :ret := sidd ( 'MY_T1' );
    table MY_T1 dropped.
    PL/SQL procedure successfully completed.
    RET
    SUCCEEDED
    SQL>

Maybe you are looking for

  • Blackberry Bold 9900 OS software update from version 7.0.0 to version 7.1.0

    Helo Everyone I tried to upgrade my Blackberry Bold 9900 device software from version 7.0.0 to version 7.1.0 but having difficulties. I tried using the Blackberry Desktop Manager but there was no version 7.1.0 listed among the available updates. Even

  • Something like Gradient Map in InDesign?

    Hi, Wondering if in the new version of InDesign (CS6) there might be any way to do anything similar to the Gradient Map adjustment layer in Photoshop? I'm open to a plugin or any way to use a Photoshop adjustment layer in InDesign if that's at all po

  • About Collect Statement.

    hi experts,      i am genereating a report in FICO module. i have to fetch teh data from the field DMBTR (AMOUNT). it has both credits anddebits. i have to do calculations and should display the final balance in the report. each GL account number has

  • Need technical person to talk to my tech person

    I've got the server and the RoboSource Control 3.1 has been installed. I'm just the technical writer and unfortunately, I can't get my tech support to read the installation guide. I need a technical person to talk to my tech person to ensure that the

  • HT2486 Why does icloud really mess up my address book?

    Need therapy or Help. All my macs are supposed to link and cotnacts saved, yet i have 2 icloud acocunts in my address book and cannot create groups with out it immediatly adding an icloud group...puzzled. It is me or is address book moving from a rea