protobuf fails to build with java-17-openjdk as sytem JDK. See https://fedoraproject.org/wiki/Changes/Java17 . See especially part about known failures: https://fedoraproject.org/wiki/Changes/Java17#common_issues_packagers_can_face_and_gathered_solutions For the build logs, see: https://koji.fedoraproject.org/koji/taskinfo?taskID=82434010 https://kojipkgs.fedoraproject.org/work/tasks/4060/82434060/mock_output.log https://kojipkgs.fedoraproject.org/work/tasks/4060/82434060/hw_info.log https://kojipkgs.fedoraproject.org/work/tasks/4060/82434060/state.log https://kojipkgs.fedoraproject.org/work/tasks/4060/82434060/build.log https://kojipkgs.fedoraproject.org/work/tasks/4060/82434060/root.log We run the rebuild in side tag f36-java17, but as fail ratio was small, we expect this side tag to be merged into rawhide 7 or 8 of February 2022. To reproduce before this date simply: fedpkg clone protobuf; cd protobuf; fedpkg build --target f36-java17; #The target is crucial. After this date the usual fedpkg build in f36 and up should do. We run two reruns your package failed both. We had also run the mass rebuilds in copr since November. We keep all encountered failures. See them here: https://copr.fedorainfracloud.org/coprs/jvanek/java17//package/protobuf You may find interesting additional informations here. Also we were spamming maintainers regualrly, check you spam folder. We had tried aprox 500 packages, and aprox 65 had failed, so the java-17-openjdk will be system JDK in f36, and you should fix your package if you want to keep it alive. Usually the fix is simple, and best is to update the package to latest upstream version. There will be usual mass rebuild once f36 branches. You may got another FTBFS bug. Let us know here if you have any questions, here in bug, or at java-devel.org . We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side if needed.
[ERROR] ServiceTest.testCallMethod:83 » NoClassDefFound Could not initialize class org... [ERROR] ServiceTest.testGetPrototype:107 » ExceptionInInitializer [INFO] [ERROR] Tests run: 1145, Failures: 0, Errors: 2, Skipped: 1 but: [ERROR] com.google.protobuf.ServiceTest.testGetPrototype Time elapsed: 0.021 s <<< ERROR! java.lang.ExceptionInInitializerError at com.google.protobuf.ServiceTest.testGetPrototype(ServiceTest.java:107) Caused by: net.sf.cglib.core.CodeGenerationException: java.lang.reflect.InaccessibleObjectException-->Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) throws java.lang.ClassFormatError accessible: module java.base does not "opens java.lang" to unnamed module @12d5624a at com.google.protobuf.ServiceTest.testGetPrototype(ServiceTest.java:107) Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) throws java.lang.ClassFormatError accessible: module java.base does not "opens java.lang" to unnamed module @12d5624a at com.google.protobuf.ServiceTest.testGetPrototype(ServiceTest.java:107) [ERROR] com.google.protobuf.ServiceTest.testCallMethod Time elapsed: 0.001 s <<< ERROR! java.lang.NoClassDefFoundError: Could not initialize class org.easymock.internal.ClassProxyFactory$2 at com.google.protobuf.ServiceTest.testCallMethod(ServiceTest.java:83) is caused by jdk17. You need to add opens/exports as java/javac args, or to bump to upstream sources supporting that. Maybe jsut disable the tests, but afik the seen issue is correct.
Reported upstream - https://github.com/protocolbuffers/protobuf/issues/9477
This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle. Changing version to 36.
So following the above error seems to make build success: https://koji.fedoraproject.org/koji/taskinfo?taskID=82757599 PR submitted: https://src.fedoraproject.org/rpms/protobuf/pull-request/10 Note that now even on i686 reducing java heap usage seems needed.
https://koji.fedoraproject.org/koji/taskinfo?taskID=82858649
@mtasaka thanks for doing the F36 build.