Skip to content

Commit

Permalink
Merge branch 'master' of github.com:adoptium/temurin-build into cdx_106
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-m-leonard committed Nov 5, 2024
2 parents b61988b + cb952f4 commit 3813039
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 8 deletions.
12 changes: 9 additions & 3 deletions sbin/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,18 @@ configureDevKitConfigureParameter() {
if [[ "$OSTYPE" == "cygwin" ]] || [[ "$OSTYPE" == "msys" ]]; then
# Windows DevKit, currently only Redist DLLs

# Default to build architecture unless target ARCHITECTURE variable is set
local target_arch="${BUILD_CONFIG[OS_ARCHITECTURE]}"
if [ ${ARCHITECTURE+x} ] && [ -n "${ARCHITECTURE}" ]; then
target_arch="${ARCHITECTURE}"
fi
echo "Target architecture for Windows devkit: ${target_arch}"

# This is TARGET Architecture for the Redist DLLs to use
# ARCHITECTURE is set to the "target" architecture by caller, or defaults to build architecture if not set
local dll_arch
if [[ "${ARCHITECTURE}" == "x86-32" ]]; then
if [[ "${target_arch}" == "x86-32" ]]; then
dll_arch="x86"
elif [[ "${ARCHITECTURE}" == "aarch64" ]]; then
elif [[ "${target_arch}" == "aarch64" ]]; then
dll_arch="arm64"
else
dll_arch="x64"
Expand Down
2 changes: 1 addition & 1 deletion test/system/reproducibleCompare/playlist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<test>
<testCaseName>Rebuild_Same_JDK_Reproducibility_Test</testCaseName>
<command>docker container rm -f reproducibleCompare; \
docker run -v "$(TEST_RESROOT):/home/jenkins/test" -w "/home/jenkins/" -v "$(TEST_JDK_HOME):/home/jenkins/jdkbinary/" --name reproducibleCompare centos:7 /bin/bash /home/jenkins/test/linux_repro_build_compare.sh $(SBOM_FILE) /home/jenkins/jdkbinary; \
docker run --sysctl net.ipv6.conf.all.disable_ipv6=0 --sysctl net.ipv6.conf.default.disable_ipv6=0 -v "$(TEST_RESROOT):/home/jenkins/test" -w "/home/jenkins/" -v "$(TEST_JDK_HOME):/home/jenkins/jdkbinary/" --name reproducibleCompare centos:7 /bin/bash /home/jenkins/test/linux_repro_build_compare.sh $(SBOM_FILE) /home/jenkins/jdkbinary; \
$(TEST_STATUS); \
docker cp reproducibleCompare:/home/jenkins/reprotest.diff ./; \
docker cp reproducibleCompare:/home/jenkins/reproJDK.tar.gz ./; \
Expand Down
7 changes: 7 additions & 0 deletions tooling/reproducible/repro_compare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,13 @@ diff -r -q "${JDK_DIR1}" "${JDK_DIR2}" > "${output}" || rc=$?

cat "${output}"

grep "Files .*" "${output}" | while read -r line; do
FILE1=$(echo "$line" | awk '{print $2}')
FILE2=$(echo "$line" | awk '{print $4}')
echo "diff -c on $FILE1 and $FILE2"
diff -c "$FILE1" "$FILE2"
done

num_differences=$(wc -l < "${output}")
echo "Number of differences: ${num_differences}"
repro_pc100=$(( (files1-num_differences)*100*100/files1 ))
Expand Down
10 changes: 6 additions & 4 deletions tooling/reproducible/windows_repro_build_compare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -684,10 +684,12 @@ Check_Architecture
echo "---------------------------------------------"
Check_VS_Versions
echo "---------------------------------------------"
Get_SRC_UCRT_Version
echo "---------------------------------------------"
Check_UCRT_Location
echo "---------------------------------------------"
if [[ "${buildArgs}" != *"--use-adoptium-devkit"* ]]; then
Get_SRC_UCRT_Version
echo "---------------------------------------------"
Check_UCRT_Location
echo "---------------------------------------------"
fi
echo "All Validation Checks Passed - Proceeding To Build"
echo "---------------------------------------------"
Check_And_Install_Ant
Expand Down

0 comments on commit 3813039

Please sign in to comment.