Created attachment 1135303 [details] kxml2 compat package spec with failing %mvn_install macro Description of problem: When attempting to build kxml as a compat package, xmvn fails in the install phase with: DEBUG] Assigning installer for each installable artifact [DEBUG] Installing artifacts [DEBUG] Installing net.sf.kxml:kxml2:pom:2.3.0 using org.fedoraproject.xmvn.tools.install.impl.DefaultArtifactInstaller [TRACE] Native code not found inside /builddir/build/SOURCES/kxml2-2.3.0.pom [TRACE] Trying to inject manifest to net.sf.kxml:kxml2:pom:2.3.0 [TRACE] Manifest injection skipped: no pre-existing manifest found to update [INFO] Installing artifact net.sf.kxml:kxml2:pom:2.3.0 [DEBUG] Installing net.sf.kxml:kxml2:jar:2.3.0 using org.fedoraproject.xmvn.tools.install.impl.DefaultArtifactInstaller [TRACE] Native code not found inside /builddir/build/BUILD/kxml-2.3.0/dist/kxml2-2.3.0.jar [TRACE] Trying to inject manifest to net.sf.kxml:kxml2:jar:2.3.0 [TRACE] Injected field JavaPackages-GroupId: net.sf.kxml [TRACE] Injected field JavaPackages-ArtifactId: kxml2 [TRACE] Not injecting field JavaPackages-Extension (it has default value "jar") [TRACE] Not injecting field JavaPackages-Classifier (it has default value "") [TRACE] Injected field JavaPackages-Version: 2.3.0 Unhandled exception java.lang.RuntimeException: java.util.zip.ZipException: duplicate entry: META-INF/services/org.xmlpull.v1.XmlPullParserFactory at org.fedoraproject.xmvn.tools.install.impl.JarUtils.injectManifest(JarUtils.java:213) at org.fedoraproject.xmvn.tools.install.impl.DefaultArtifactInstaller.install(DefaultArtifactInstaller.java:82) at org.fedoraproject.xmvn.tools.install.impl.DefaultInstaller.installArtifact(DefaultInstaller.java:235) at org.fedoraproject.xmvn.tools.install.impl.DefaultInstaller.install(DefaultInstaller.java:345) at org.fedoraproject.xmvn.tools.install.cli.InstallerCli.run(InstallerCli.java:53) at org.fedoraproject.xmvn.tools.install.cli.InstallerCli.main(InstallerCli.java:72) Caused by: java.util.zip.ZipException: duplicate entry: META-INF/services/org.xmlpull.v1.XmlPullParserFactory at java.util.zip.ZipOutputStream.putNextEntry(ZipOutputStream.java:232) at java.util.jar.JarOutputStream.putNextEntry(JarOutputStream.java:109) at org.fedoraproject.xmvn.tools.install.impl.JarUtils.injectManifest(JarUtils.java:203) ... 5 more RPM build errors: error: Bad exit status from /var/tmp/rpm-tmp.TZHhK0 (%install) Bad exit status from /var/tmp/rpm-tmp.TZHhK0 (%install) Child return code was: 1 EXCEPTION: Command failed. See logs for output. # bash --login -c /usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/kxml2.spec Traceback (most recent call last): File "/usr/lib/python3.4/site-packages/mockbuild/trace_decorator.py", line 88, in trace result = func(*args, **kw) File "/usr/lib/python3.4/site-packages/mockbuild/util.py", line 547, in do raise exception.Error("Command failed. See logs for output.\n # %s" % (command,), child.returncode) mockbuild.exception.Error: Command failed. See logs for output. # bash --login -c /usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/kxml2.spec LEAVE do --> EXCEPTION RAISED The spec file I've used is attached. It seems maven30-xmvn needs a backport of: https://github.com/mizdebsk/xmvn/commit/9a326bd401d3f82ce09be69fec55d48fb39d3bea An SRPM and full log of the failure is here: https://copr.fedorainfracloud.org/coprs/jerboaa/thermostat-latest/build/167520/
Created attachment 1334726 [details] Reproducer java -cp $(build-classpath xmvn objectweb-asm slf4j/api slf4j/simple):rep.jar rep.DuplicateManifestReproducer rep.jar
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHEA-2017:3022