Bug 131141 - dev-java/xerces USE="-examples" should not install xercesSamples.jar
|
Bug#:
131141
|
Product: Gentoo Linux
|
Version: 2006.0
|
Platform: All
|
|
OS/Version: Linux
|
Status: RESOLVED
|
Severity: normal
|
Priority: P2
|
|
Resolution: FIXED
|
Assigned To: java@gentoo.org
|
Reported By: h.mth@web.de
|
|
Component: Ebuilds
|
|
|
URL:
|
|
Summary: dev-java/xerces USE="-examples" should not install xercesSamples.jar
|
|
Keywords:
|
|
Status Whiteboard:
|
|
Opened: 2006-04-24 13:17 0000
|
Something like
'use examples || rm ${S}/build/xercesSamples.jar'
in src_install before java-pkg_dojar.
I'm attaching a patch so that xercesSamples.jar is not installed into
/usr/share/xerces-2/lib when the examples use flag is not set. The patch is
against the xerces 2.7.1-r1 ebuild in portage. I've tested it, and the change
also works with the java experimental 2.8.0 ebuild.
Created an attachment (id=93314) [details]
examples patch
I realized there was a better way to do this as soon as I submitted the last
patch.
This removes the samples jar file earlier in the build process. There's no
reason to wait until the samples jar is in image before removing it.
Thanks for your attempt. However, compiled examples should never go to
/usr/share/package/lib through java-pkg_dojar, no matter the useflag. Examples
source should go to /usr/share/doc/${PF}/examples as the ebuild does, and
compiled examples are probably of no use so the jar can just be removed in any
case. Ideally it wouldn't even have to be built, that would probably require
some manual build.xml patching or finding a better target(s) to pass to eant.
You're right.
[echo] jar --> generates the xercesImpl.jar file
[echo] jars --> generates xercesImpl & xercesSamples jars
It looks like we can change the build target to 'jar' and we won't have to deal
with the samples jar. As you mentioned, a binary examples jar isn't that useful
anyway.
The jars target builds three files: xercesImpl.jar, xercesSamples.jar and
xml-apis.jar. The jar target only builds xercesImpl.jar.
xml-commons-external already provides xml-apis.jar, but according to Bug #82561
removing the jar from xerces will break some ebuilds. Those will have to be
fixed before the target can be changed.
(In reply to comment #5)
> You're right.
> [echo] jar --> generates the xercesImpl.jar file
> [echo] jars --> generates xercesImpl & xercesSamples jars
> It looks like we can change the build target to 'jar' and we won't have to deal
> with the samples jar. As you mentioned, a binary examples jar isn't that useful
> anyway.
Yeah.
> The jars target builds three files: xercesImpl.jar, xercesSamples.jar and
> xml-apis.jar. The jar target only builds xercesImpl.jar.
> xml-commons-external already provides xml-apis.jar, but according to Bug #82561
> removing the jar from xerces will break some ebuilds. Those will have to be
> fixed before the target can be changed.
Well the jars target just copies the xml-apis.jar from one dir to another. It's
taken from xml-commons-external, not built here. So the ebuild could just copy
it itself (until bug 82561 is solved and this copying is no more needed) and
then jar target would be enough, without building the samples.
Created an attachment (id=93356) [details]
use jar target
This uses the jar target so that the samples are not built, and installs a
symlink so that xerces-2/lib/xml-apis.jar points to the xml-commons-external
jar that was used in building xerces.
Fixed in 2.8.0-r1 in migrated-java-experimental-overlay.
Fixed in xerces-2.7.1-r2 in the tree. Thanks everyone.