Thnkas Jan, I'll try your solution. -----Mensagem original----- De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Enviada em: segunda-feira, 25 de outubro de 2004 03:49 Para: [EMAIL PROTECTED] Assunto: AW: Convert to Ant
Defining the classpath is done with a <path>. Compiler is called via <javac> and the program is run with <java>. So you´ll get something like that (not tested): <!-- cd oreilly-aop/example1 --> oreilly-aop/example1/build.xml: ---8-<---------8-<---------8-<---------8-<---------8-<---------8-<------ <project default="run"> <!-- for easier changing to better project structure --> <property name="src.dir" value="."/> <property name="classes.dir" value="."/> <!-- export CLASSPATH=.;jboss-common.jar;jboss-aop.jar;javassist.jar --> <path id="classpath"> <fileset dir="." includes="jboss-common.jar,jboss-aop.jar,javassist.jar,"/> <fileset dir="${classes.dir}"/> </path> <!-- javac *.java --> <target name="compile"> <javac srcdir="${src.dir}" destdir="${classes.dir}" classpathref="classpath"/> </target> <!-- java -Djava.system.class.loader=org.jboss.aop.standalone.SystemClassLoader --> <target name="run" depends="compile"> <java classpathref="classpath"> <sysproperty name="java.system.class.loader" value="org.jboss.aop.standalone.SystemClassLoader"/> </java> </target> </project> ---8-<---------8-<---------8-<---------8-<---------8-<---------8-<------ Maybe you need to set >>fork="true"<< in the <java> task. AND: what should be started? You havent specified that. Neither the classname (use the classname attribute for that) nor the jar file (jar attribute). Jan > -----Ursprüngliche Nachricht----- > Von: Kris Read [mailto:[EMAIL PROTECTED] > Gesendet am: Montag, 25. Oktober 2004 08:34 > An: Ant Users List > Betreff: Re: Convert to Ant > > Hello, > > Ant is not a scripting language! > > Look in the Ant manual under the <java> and <javac> tasks. > > http://ant.apache.org > > > > On Sun, 24 Oct 2004 09:31:22 -0300, André Dantas Rocha > <[EMAIL PROTECTED]> wrote: > > Hi, > > > > I'm new in Ant and wold like to convert those lines to Ant > script. How can I > > do it? > > > > Thanks, > > > > André > > > > $ cd oreilly-aop/example1 > > $ export CLASSPATH=.;jboss-common.jar;jboss-aop.jar;javassist.jar > > $ javac *.java > > $ java > -Djava.system.class.loader=org.jboss.aop.standalone.SystemClassLoader > > POJO > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]