diff --git a/java-11-openjdk.spec b/java-11-openjdk.spec index 8a31304..cdfa14e 100644 --- a/java-11-openjdk.spec +++ b/java-11-openjdk.spec @@ -146,6 +146,9 @@ # 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++ +%ifarch %{ix86} +%global optflags %optflags -fno-PIC +%endif %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||')