I have ~x86 and ~amd64 set. I installed the latest eclipse-sdk package which also included ant/ant-core/ant-tasks The build finished fine, but when I attempted to run an ant build.xml inside of eclipse that used the optional ant task PropertyFile I got an error: class org.apache.tools.ant.taskdefs.optional.PropertyFile was not found It pointed me to look at: /usr/lib64/eclipse-3.2/plugins/org.apache.ant_1.6.5/lib I noticed at this point that the plugin seems to be based on ant 1.6.5 yet the ant chosen by portage when emerging eclipse-sdk was ant 1.7.* So I added to my package.mask: >dev-java/ant-1.6.6 >dev-java/ant-core-1.6.6 >dev-java/ant-tasks-1.6.6 I then did emerge -C ant ant-core ant-tasks And then remerged them back in. I then did a recompile emerge on eclipse-sdk `emerge eclipse-sdk` Now the ant scripts work with PropertyFile and the directory noted above contains a lot more jars than it did before. Reproducible: Didn't try
My guess on what happens with the new splitted ant: In splitted ant the /usr/bin/ant wrapper puts all the optional ant jars to CLASSPATH and there is not a unified directory (ant home) any more where all these live. Eclipse is most likely using the ant classes directly and as such the optional jars like ant-nodeps.jar where the PropertyFile task lives are not in classpath. I think to solve this we could modify the eclipse launcher to put all installed ant tasks to CLASSPATH. Is the build.xml you were trying to use something eclipse-sdk generated or something external?
Or do some symlinkfest in, say /usr/share/ant/lib, and point ANT_HOME into /usr/share/ant
How bout this: ant-core installs /etc/env.d/20ant which sets ANT_HOME to /usr/share/ant-core (NEW) ant-tasks would install /etc/env.d/21ant which would override ANT_HOME with /usr/share/ant. it would also symlink all jars from core and tasks into /usr/share/ant/lib - ant script doesn't care, it sets ANT_HOME to /usr/share/ant-core anyway - stuff that doesn't use the script but looks in ANT_HOME/lib would find everything there - except of course dependencies of the tasks, but that's life (any better idea for this?) so the only thing that would need changing is ant-tasks
(In reply to comment #1) > > Is the build.xml you were trying to use something eclipse-sdk generated or > something external? > The build.xml was external, so no additional concern there.
(In reply to comment #4) > (In reply to comment #1) > > > > Is the build.xml you were trying to use something eclipse-sdk generated or > > something external? > > > > The build.xml was external, so no additional concern there. > Can you attach a sample build.xml to test with?
What exactly version of eclipse-sdk? The one from tree or overlay? How bout emerge --info? Also, were you using split-ant-overlay at some point? The ant-tasks-1.7.0.ebuild was incomplete there until some point, but when it was added to main tree it was already complete in a sense that eclipse-sdk ebuild should fill the /usr/lib64/eclipse-3.2/plugins/org.apache.ant_1.6.5/lib directory with all jars, not just the core two. Because I just did what proposed in comment 3 and realized eclipse isn't using ANT_HOME var, but knows only of jars symlinked in that abovementioned directory when emerging. This means one has to remerge eclipse-sdk after upgrade to split-ant to get the symlinks right, but it should work afterwards.
Ah, found the cause. ant-tasks was not registering ant-nodeps into its package.env, so java_pkg-jar-from ant-tasks didn't make a symlink to ant-nodeps.jar which contains PropertyFile. Fixed in ant-tasks-1.7.0-r2. Note that you need to remerge eclipse-sdk after upgrading ant-tasks, to put the change in effect.
Cool, glad it is resolved. Sorry I didn't get back with the examples/information that was requested. (I got my first girlfriend ever about 6 weeks ago, only took me 28 years to do this (typical geek fashion) but needless to say I've had other priorities recently)