Remove OpenJDK compiler flag filters and use build_{c,ld}flags directly
Related: RHEL-131898
This commit is contained in:
parent
e4a332d39c
commit
9f47abacc2
@ -213,15 +213,6 @@
|
||||
%global debugedit %{_rpmconfigdir}/debugedit
|
||||
%endif
|
||||
|
||||
# Filter out flags from the optflags macro that cause problems with the OpenJDK build
|
||||
# We filter out -O flags so that the optimization of HotSpot is not lowered from O3 to O2
|
||||
# We filter out -Wall which will otherwise cause HotSpot to produce hundreds of thousands of warnings (100+mb logs)
|
||||
# We replace it with -Wformat (required by -Werror=format-security) and -Wno-cpp to avoid FORTIFY_SOURCE warnings
|
||||
# We filter out -fexceptions as the HotSpot build explicitly does -fno-exceptions and it's otherwise the default for C++
|
||||
%global ourflags %(echo %optflags | sed -e 's|-Wall|-Wformat -Wno-cpp|' | sed -r -e 's|-O[0-9]*||')
|
||||
%global ourcppflags %(echo %ourflags | sed -e 's|-fexceptions||')
|
||||
%global ourldflags %{__global_ldflags}
|
||||
|
||||
# In some cases, the arch used by the JDK does
|
||||
# not match _arch.
|
||||
# Also, in some cases, the machine name used by SystemTap
|
||||
@ -2040,16 +2031,16 @@ for suffix in %{build_loop} ; do
|
||||
if [ "x$suffix" = "x" ] ; then
|
||||
jdkzip=%{releasezip}
|
||||
staticlibzip=%{staticlibzip}
|
||||
make -C %{nssadapter_name} CFLAGS="%{ourflags}" LDFLAGS="%{ourldflags}"
|
||||
make -C %{nssadapter_name} CFLAGS="%{build_cflags}" LDFLAGS="%{build_ldflags}"
|
||||
elif [ "x$suffix" = "x%{fastdebug_suffix_unquoted}" ] ; then
|
||||
jdkzip=%{fastdebugzip}
|
||||
staticlibzip=%{fastdebugstaticlibzip}
|
||||
make -C %{nssadapter_name} CFLAGS="%{ourflags}" LDFLAGS="%{ourldflags}"
|
||||
make -C %{nssadapter_name} CFLAGS="%{build_cflags}" LDFLAGS="%{build_ldflags}"
|
||||
else # slowdebug
|
||||
jdkzip=%{slowdebugzip}
|
||||
staticlibzip=%{slowdebugstaticlibzip}
|
||||
# Disable _FORTIFY_SOURCE to allow for no optimization
|
||||
make -C %{nssadapter_name} CFLAGS="%{ourflags} -O0 -Wp,-U_FORTIFY_SOURCE" LDFLAGS="%{ourldflags}"
|
||||
make -C %{nssadapter_name} CFLAGS="%{build_cflags} -O0 -Wp,-U_FORTIFY_SOURCE" LDFLAGS="%{build_ldflags}"
|
||||
fi
|
||||
|
||||
installdir=%{installoutputdir -- ${suffix}}
|
||||
@ -2640,8 +2631,10 @@ exit 0
|
||||
- Incorporate new FIPS patch for 25u
|
||||
- Drop static libjvm.a following adjusted build target for portable build
|
||||
- Remove redundant (and now outdated) build targets, jdkimage and static_libs_image
|
||||
- Remove OpenJDK compiler flag filters and use build_{c,ld}flags directly
|
||||
- Resolves: RHEL-133743
|
||||
- Resolves: RHEL-133737
|
||||
- Related: RHEL-131898
|
||||
|
||||
* Mon Dec 08 2025 Thomas Fitzsimmons <fitzsim@redhat.com> - 1:25.0.1.0.8-2
|
||||
- Add java-25-openjdk-crypto-adapter subpackage
|
||||
|
||||
Loading…
Reference in New Issue
Block a user