Hi all,
I am trying to reproduce v0.4.0 of <https://github.com/apache/sling-org-apache-sling-feature-extension-unpack/tree/org.apache.sling.feature.extension.unpack-0.4.0?tab=readme-ov-file> sling-org-apache-sling-feature-extension-unpack<https://github.com/apache/sling-org-apache-sling-feature-extension-unpack/tree/org.apache.sling.feature.extension.unpack-0.4.0?tab=readme-ov-file> which means I am cloning the source code, rebuilding, and comparing the artifacts to ones on Maven central. I am using JDK version ``` openjdk version "11.0.26" 2025-01-21 OpenJDK Runtime Environment (build 11.0.26+4-post-Ubuntu-1ubuntu122.04) OpenJDK 64-Bit Server VM (build 11.0.26+4-post-Ubuntu-1ubuntu122.04, mixed mode, sharing) ``` and maven command ``` mvn -Papache-release clean package -DskipTests -Dmaven.javadoc.skip -Dgpg.skip ``` as suggested here<https://github.com/jvm-repo-rebuild/reproducible-central/blob/master/content/org/apache/sling/org.apache.sling.feature.extension.unpack/org.apache.sling.feature.extension.unpack-0.4.0.buildspec> on Reproducible Central. However, when I build this project on my local, I see that one artifact, https://repo1.maven.org/maven2/org/apache/sling/org.apache.sling.feature.extension.unpack/0.4.0/org.apache.sling.feature.extension.unpack-0.4.0.tar.gz, differs from the one on Maven Central. The differences majorly are: 1. Text deleted from LICENSE ``` For the org.osgi:org.osgi.util.function v1.0.0 (http://www.osgi.org/) component This is licensed under The Apache Software License, Version 2.0 -For the org.osgi:osgi.annotation v8.1.0 (https://docs.osgi.org/) component -This is licensed under Apache-2.0 - For the org.osgi:osgi.core v6.0.0 (http://www.osgi.org/) component This is licensed under The Apache Software License, Version 2.0 ``` 2. Time embedded in executable fc -exec \"$JAVACMD\" $JAVA_OPTS -Dproject.artifactId=org.apache.sling.feature.extension.unpack -Dproject.version=0.4.0 -Dbuild.timestamp=2024-01-19T11:53:59Z -Duser.timezone=UTC -Dfile.encoding=UTF-8 \\ +exec \"$JAVACMD\" $JAVA_OPTS -Dproject.artifactId=org.apache.sling.feature.extension.unpack -Dproject.version=0.4.0 -Dbuild.timestamp=2024-10-19T08:04:43Z -Duser.timezone=UTC -Dfile.encoding=UTF-8 \\ 3. Changes in JVM bytecode. Here we see `ldc_w` is replaced with `ldc`. - 9: ldc_w #269 // class \"[Ljava/lang/Character;\" - 12: invokeinterface #247, 2 // InterfaceMethod org/osgi/util/converter/InternalConverting.to:(Ljava/lang/Class;)Ljava/lang/Object; - 17: checkcast #269 // class \"[Ljava/lang/Character;\" - 20: areturn + 3: invokevirtual #132 // Method stringToCharArray:(Ljava/lang/String;)[C + 6: invokevirtual #126 // Method convert:(Ljava/lang/Object;)Lorg/osgi/util/converter/InternalConverting; + 9: ldc #133 // class \"[Ljava/lang/Character;\" I want help to understand why this difference occurred. First, we can look the 3rd difference. This should be solvable by using the precise Java version and vendor the project uses for releases. I could not find this information on your CI<https://ci-builds.apache.org/job/Sling/job/modules/job/sling-org-apache-sling-feature-extension-unpack/job/master/>. Regards, Aman Sharma PhD Student KTH Royal Institute of Technology School of Electrical Engineering and Computer Science (EECS) Department of Theoretical Computer Science (TCS) <http://www.kth.se><https://www.kth.se/profile/amansha><https://www.kth.se/profile/amansha> <https://www.kth.se/profile/amansha>https://algomaster99.github.io/
