Open
Description
Is your feature request related to a problem? Please describe.
The (classic) x86_64 make build process of OpenJDK 17 and 21 is more versatile by adding the switch --build=x86_64-unknown-linux-gnu
. With this, the make build of OpenJDK17 and OpenJDK21 succeeds e.g. on wsl as well. For a rich Broadcom ecosystem, you are the engineers, could you integrate the change, please?
I tried to populate a pull request but in branches 3/4/5/master/dev are different versions which led me to the conclusion better asking first.
Describe the solution you'd like
This is the fix for make build in non-VVF environment
%ifarch aarch64
sh ./configur* \
--with-target-bits=64 \
--enable-headless-only \
--with-extra-cxxflags="-Wno-error -fno-delete-null-pointer-checks -fno-lifetime-dse" \
--with-extra-cflags="-fno-delete-null-pointer-checks -Wno-error -fno-lifetime-dse" \
--with-freetype-include=%{_includedir}/freetype2 \
--with-freetype-lib=%{_libdir} \
--with-stdc++lib=dynamic \
--disable-warnings-as-errors
%else
sh ./configur* \
--with-target-bits=64 \
--enable-headless-only \
--with-extra-cxxflags="-Wno-error -fno-delete-null-pointer-checks -fno-lifetime-dse" \
--with-extra-cflags="-fno-delete-null-pointer-checks -Wno-error -fno-lifetime-dse" \
--with-freetype-include=%{_includedir}/freetype2 \
--with-freetype-lib=%{_libdir} \
--with-stdc++lib=dynamic \
--build=x86_64-unknown-linux-gnu \
--disable-warnings-as-errors
%endif
Describe alternatives you've considered
This has been tested for a successful make build.
cd photon
cp SPECS/openjdk/openjdk17.spec openjdk17.spec.tmp
sudo sed "s/--disable-warnings-as-errors/--disable-warnings-as-errors --build=x86_64-unknown-linux-gnu/" openjdk17.spec.tmp > SPECS/openjdk/openjdk17.spec
rm openjdk17.spec.tmp
cp SPECS/openjdk/openjdk21.spec openjdk21.spec.tmp
sudo sed "s/--disable-warnings-as-errors/--disable-warnings-as-errors --build=x86_64-unknown-linux-gnu/" openjdk21.spec.tmp > SPECS/openjdk/openjdk21.spec
rm openjdk21.spec.tmp
Additional context
No response