Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] AspectJ Ant task bug ?

Are you sure it isn't because of other problems in your build.xml?

If I do a diff between your two .txt files I see the contents of
exemple.jar (the classes in the inpath folder) get deleted and then
never recreated in the inpath folder and then not woven.

I see where you build your code into the basedir/build, then I see a
jar built from that into basedir/inpath/exemple1.jar. Where is the
line that expands exemple1.jar  into the inpath folder?  If you are
doing it manually and then rerunning that build.xml, then your

<delete>
        <fileset dir="${basedir}" includes="**/*.class" />
</delete>

will be deleting all the classes from in that inpath at the start.

Andy.

2008/7/9  <jeanlouis.pasturel@xxxxxxxxxxxxxxxxxx>:
>
> Andy, Andrew,
> Sorry for my misunderstanding...
>
> I join the ant traces in the two compilations (with packaged classes and
> unpackaged classes) and the build.xml file
> With unpackaged classes in the inpath folder, the classes are not woven,
> with the packaged classes in the inpath they are woven.
>
>
>
> Jean-Louis Pasturel
>
>
> -----Message d'origine-----
> De : aspectj-users-bounces@xxxxxxxxxxx
> [mailto:aspectj-users-bounces@xxxxxxxxxxx] De la part de Andy Clement
> Envoyé : mardi 8 juillet 2008 19:56
> À : aspectj-users@xxxxxxxxxxx
> Objet : Re: [aspectj-users] AspectJ Ant task bug ?
>
> I just tried to recreate this, but it always just works for me.  As
> Andrew says, it would be useful to see the output - and can you run
> ant with "-verbose" (in addition to leaving verbose switched on the
> for the iajc call) - and show the output of that, mine was:
>
> C:\aspectj162-dev\doc\examples\foo>ant -verbose
> Apache Ant version 1.7.0 compiled on December 13 2006
> Buildfile: build.xml
> Detected Java version: 1.6 in: c:\jvms\jdk1.6.0_06\jre
> Detected OS: Windows XP
> parsing buildfile C:\aspectj162-dev\doc\examples\foo\build.xml with URI =
> file:/
> C:/aspectj162-dev/doc/examples/foo/build.xml
> Project base dir set to: C:\aspectj162-dev\doc\examples\foo
> [antlib:org.apache.tools.ant] Could not load definitions from resource
> org/apach
> e/tools/ant/antlib.xml. It could not be found.
> Build sequence for target(s) `def' is [init, def]
> Complete build sequence is [init, def, ]
>
> init:
>
> def:
>     [iajc] ajc [-source, 1.3, -d,
> C:\aspectj162-dev\doc\examples\foo\outpath, -
> verbose, -classpath,
> C:\aspectj162-dev\doc\examples\foo\lib\aspectjrt.jar;C:\asp
> ectj162-dev\doc\examples\foo\perfAspects13.jar, -inpath,
> C:\aspectj162-dev\doc\e
> xamples\foo\inpath, -argfile,
> C:\aspectj162-dev\doc\examples\foo\src\args3.lst]
>     [iajc] forking [c:\jvms\jdk1.6.0_06\jre\bin\javaw.exe, -Xmx512m,
> -classpath
> , c:\aspectj162-dev\lib\aspectjtools.jar, org.aspectj.tools.ajc.Main,
> -source, 1
> .3, -d, C:\aspectj162-dev\doc\examples\foo\outpath, -verbose, -classpath,
> C:\asp
> ectj162-dev\doc\examples\foo\lib\aspectjrt.jar;C:\aspectj162-dev\doc\example
> s\fo
> o\perfAspects13.jar, -inpath, C:\aspectj162-dev\doc\examples\foo\inpath,
> -argfil
> e, C:\aspectj162-dev\doc\examples\foo\src\args3.lst]
>     [iajc] directory classpath entry does not exist:
> c:\jvms\jdk1.6.0_06\jre\li
> b\sunrsasign.jar
>     [iajc]
>     [iajc] zipfile classpath entry does not exist:
> c:\jvms\jdk1.6.0_06\jre\clas
> ses
>     [iajc]
>     [iajc] directory classpath entry does not exist:
> C:\aspectj162-dev\doc\exam
> ples\foo\perfAspects13.jar
>     [iajc]
>     [iajc] Pipelining compilation
>     [iajc]
>     [iajc] compiling
> C:\aspectj162-dev\doc\examples\foo\src\iep\perf\aspect13\c
> oncreteAspect\DurationSimpleMethod.aj
>     [iajc]
>     [iajc] weaver operating in reweavable mode.  Need to verify any
> required ty
> pes exist.
>     [iajc]
>     [iajc] woven aspect iep.perf.aspect13.concreteAspect.X (from
> C:\aspectj162-
> dev\doc\examples\foo\src\iep\perf\aspect13\concreteAspect\DurationSimpleMeth
> od.a
> j)
>     [iajc]
>     [iajc] woven class jlp.example1.jvm13.A (from
> C:\aspectj162-dev\doc\example
> s\foo\inpath\jlp\example1\jvm13\A.class)
>     [iajc]
>     [iajc] woven class jlp.example1.jvm13.B (from
> C:\aspectj162-dev\doc\example
> s\foo\inpath\jlp\example1\jvm13\B.class)
>     [iajc]
>     [iajc] Compiler took 968ms
>     [iajc]
>
> BUILD SUCCESSFUL
> Total time: 1 second
>
> With classes A and B in the inpath directory - and they are still
> there afterwards (and they are in the output folder too).
>
> The IAJC task is just a very thin wrapper over ajc, so hard to see why
> on earth it would be removing any input class files.
>
> Andy.
>
> 2008/7/8 Andrew Eisenberg <andrew@xxxxxxxxxxxx>:
>>> I join the two outputs ( OK and KO)  as Andrew told to me.
>>
>> I wasn't looking for the class files, but rather the output from the
>> ant log that describes the targets that were run and their status.
>> This might hint at what happened.
>> _______________________________________________
>> aspectj-users mailing list
>> aspectj-users@xxxxxxxxxxx
>> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>>
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>
>
> *********************************
> This message and any attachments (the "message") are confidential and intended solely for the addressees.
> Any unauthorised use or dissemination is prohibited.
> Messages are susceptible to alteration.
> France Telecom Group shall not be liable for the message if altered, changed or falsified.
> If you are not the intended addressee of this message, please cancel it immediately and inform the sender.
> ********************************
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>
>


Back to the top