Adjust system NSS patch for -Wl,--as-needed flag.

redhat-rpm-config package introduced default linker
flag -Wl,--as-needed. This broke the build of SunEC via
system NSS. Filter flag -Wl,--as-needed for this library's
build.

Resolves: RHBZ#1623437
This commit is contained in:
Severin Gehwolf 2018-08-29 14:14:17 +02:00
parent 679939b0ad
commit 7c23b900d4
2 changed files with 13 additions and 3 deletions

View File

@ -94,8 +94,13 @@ diff --git a/make/lib/Lib-jdk.crypto.ec.gmk b/make/lib/Lib-jdk.crypto.ec.gmk
$(eval $(call SetupJdkLibrary, BUILD_LIBSUNEC, \
NAME := sunec, \
TOOLCHAIN := TOOLCHAIN_LINK_CXX, \
@@ -58,6 +64,7 @@
LDFLAGS := $(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK), \
@@ -47,9 +52,11 @@
CXXFLAGS := $(BUILD_LIBSUNEC_CXXFLAGS_JDKLIB), \
DISABLED_WARNINGS_gcc := sign-compare implicit-fallthrough, \
DISABLED_WARNINGS_microsoft := 4101 4244 4146 4018, \
- LDFLAGS := $(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK), \
+ LDFLAGS := $(subst -Xlinker --as-needed,, \
+ $(subst -Wl$(COMMA)--as-needed,, $(LDFLAGS_JDKLIB))) $(LDFLAGS_CXX_JDK), \
LDFLAGS_macosx := $(call SET_SHARED_LIBRARY_ORIGIN), \
LIBS := $(LIBCXX), \
+ LIBS_linux := -lc $(NSS_LIBS), \

View File

@ -835,7 +835,7 @@ Provides: java-%{javaver}-%{origin}-src%{?1} = %{epoch}:%{version}-%{release}
Name: java-%{javaver}-%{origin}
Version: %{newjavaver}.%{buildver}
Release: 7%{?dist}
Release: 8%{?dist}
# java-1.5.0-ibm from jpackage.org set Epoch to 1 for unknown reasons
# and this change was brought into RHEL-4. java-1.5.0-ibm packages
# also included the epoch in their virtual provides. This created a
@ -1724,6 +1724,11 @@ require "copy_jdk_configs.lua"
%changelog
* Wed Aug 29 2018 Severin Gehwolf <sgehwolf@redhat.com> - 1:11.0.ea.22-8
- Adjust system NSS patch, RHBZ-1565658-system-nss-SunEC.patch, so
as to filter -Wl,--as-needed from linker flags. Fixes FTBFS issue.
Resolves: RHBZ#1623437
* Thu Aug 23 2018 Jiri Vanek <jvanek@redhat.com> - 1:11.0.ea.22-6
- dissabled accessibility, fixed provides for main package's debug variant