Description of problem: xalan in F16 was built with openjdk-1.7.0, and any attempt to use it with openjdk-1.6.0 fails. There's still some discussion about whether openjdk-1.6.0 will be present in rawhide, but right now it's the only thing there. Version-Release number of selected component (if applicable): xalan-j2-2.7.1-6.fc16.noarch How reproducible: Always Steps to Reproduce: 1. Create foo.xml with contents: <?xml version="1.0" ?> <hello>HELLO, WORLD! </hello> 2. Create foo.xsl with contents: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml"> <xsl:output method="text"/> </xsl:stylesheet> 3. /usr/lib/jvm/java-1.6.0/bin/java -cp $( build-classpath xalan-j2 xerces-j2 ) org.apache.xalan.xslt.Process -IN foo.xml -XSL foo.xsl Actual results: Exception in thread "main" java.lang.UnsupportedClassVersionError: org/apache/xalan/xslt/Process : Unsupported major.minor version 51.0 at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:634) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:277) at java.net.URLClassLoader.access$000(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:212) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:205) at java.lang.ClassLoader.loadClass(ClassLoader.java:321) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294) at java.lang.ClassLoader.loadClass(ClassLoader.java:266) Could not find the main class: org.apache.xalan.xslt.Process. Program will exit. Expected results: HELLO, WORLD!
I'll let Andrew/Deepak chime in with their thoughts on OpenJDK 7.
This is going to happen for any applications built with 1.7, unless the explicitly build with target 1.6. As for 1.7.0 not being in rawhide, it has been there for a while: http://koji.fedoraproject.org/koji/buildinfo?buildID=257378
It's not that it's not in rawhide -- it's not in updates-testing. My F16 system is set up to look for packages in 3 locations: 1) https://mirrors.fedoraproject.org/metalink?repo=fedora-$releasever&arch=$basearch 2) https://mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&arch=$basearch 3) https://mirrors.fedoraproject.org/metalink?repo=updates-testing-f$releasever&arch=$basearch I think this is pretty standard, since f16 is branched from rawhide already (please correct me if I'm wrong here). xalan-j2 already went into updates-testing, but openjdk 7 is not in any of those three repos yet. I can and have installed 7 from koji, but that's not the issue here. The issue is that unless openjdk 6 is going to be completely dropped, you can't build critical packages like xalan-j2 with target=1.7. It's going to make openjdk 6 useless. I've posted to the devel list about this as well.
Ah, you mean it is not in F-16. Rawhide is different from F-16 now that they have branched. Yes, there was a problem that caused it to not be on the repos. An update has been submitted for it though, and it has been marked stable. A soon as the system gets around to it, it should appear on the F-16 repos: https://admin.fedoraproject.org/updates/java-1.7.0-openjdk-1.7.0.0-0.1.20110803.fc16
yikes, sorry, I did not realize that I had said rawhide. That was before my morning coffee. :-) I certainly meant F16; sorry for the confusion.
No problem. It seems like for now, rebuilding xalan might be the best thing while we work out the 1.6/1.7 situation. I have expired the buildroot override for 1.7, so it should build with 1.6 again.
This package has changed ownership in the Fedora Package Database. Reassigning to the new owner of this component.
Note: as long as this is being rebuilt, it would be nice if it could include a POM files for each jar.
It doesn't look like xalan-j2 is built with Maven. Are you proposing injecting POMs from somewhere else? What about getting them into xalan upstream first?
Getting it from someplace like this is fine with me: http://repo1.maven.org/maven2/xalan/xalan/2.7.1/xalan-2.7.1.pom Note that maven2-common-poms currently contains /usr/share/maven2/default_poms/JPP-xalan-j2.pom So for that POM I'm really asking that it be moved into the correct package. There should also be POMs for 1) xalan-j2-serializer: http://repo1.maven.org/maven2/xalan/serializer/2.7.1/serializer-2.7.1.pom and 2) xsltc -- there's no upstream POM for this, but something like this is sufficient: <project> <modelVersion>4.0.0</modelVersion> <groupId>xalan</groupId> <artifactId>xsltc</artifactId> <version>2.7.1</version> <dependencies> <dependency> <groupId>xalan</groupId> <artifactId>xalan</artifactId> <version>2.7.1</version> </dependency> </dependencies> </project> I'd love to see official POM files in upstream, but there are already several precedents in Fedora for shipping POMs for maven.org
I'm not a maven expert (nor am I the maintainer of xalan-j2) so I can't help with POM stuff. But I support all efforts with the Fedora Java stack :)
The original issue reported here was fix (xalan-j2 was rebuilt with jdk6). I'll open a separate issue with a patch for the pom addition.