From c2079c8084fe7b9de91d6157afdecb68d4e5a98f Mon Sep 17 00:00:00 2001 From: Dan Horák Date: Mar 12 2018 09:39:24 +0000 Subject: - fix LDFLAGS injection (#1552658) --- diff --git a/qclib-1.3.1-ldflags.patch b/qclib-1.3.1-ldflags.patch new file mode 100644 index 0000000..a47fd79 --- /dev/null +++ b/qclib-1.3.1-ldflags.patch @@ -0,0 +1,20 @@ +diff -up qclib-1.3.1/Makefile.ldflags qclib-1.3.1/Makefile +--- qclib-1.3.1/Makefile.ldflags 2018-03-12 10:36:52.428425169 +0100 ++++ qclib-1.3.1/Makefile 2018-03-12 10:37:27.328425169 +0100 +@@ -8,6 +8,7 @@ VERSION = 1.3.1 + VERM = $(shell echo $(VERSION) | cut -d '.' -f 1) + DOCDIR ?= /usr/share/doc/packages/ + CFLAGS ?= -g -Wall -O2 ++LDFLAGS ?= + CFILES = query_capacity.c query_capacity_data.c query_capacity_sysinfo.c query_capacity_ocf.c \ + query_capacity_hypfs.c query_capacity_sthyi.c + OBJECTS = $(patsubst %.c,%.o,$(CFILES)) +@@ -38,7 +39,7 @@ libqc.a: $(OBJECTS) + $(AR) rcs $@ $^ + + libqc.so.$(VERSION): $(OBJECTS) +- $(LINK) -Wl,-soname,libqc.so.$(VERM) -shared $^ -o $@ ++ $(LINK) $(LDFLAGS) -Wl,-soname,libqc.so.$(VERM) -shared $^ -o $@ + -rm libqc.so.$(VERM) 2>/dev/null + ln -s libqc.so.$(VERSION) libqc.so.$(VERM) + diff --git a/qclib.spec b/qclib.spec index 56bafa2..4f6b359 100644 --- a/qclib.spec +++ b/qclib.spec @@ -1,13 +1,14 @@ Name: qclib Version: 1.3.1 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Library for extraction of system information for Linux on z Systems License: BSD URL: http://www.ibm.com/developerworks/linux/linux390/qclib.html Source0: http://public.dhe.ibm.com/software/dw/linux390/ht_src/%{name}-%{version}.tgz -# Soname will be set upstream in later release # https://bugzilla.redhat.com/show_bug.cgi?id=1306280 Patch0: %{name}-1.3.1-docdir.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1552658 +Patch1: %{name}-1.3.1-ldflags.patch ExclusiveArch: s390 s390x BuildRequires: glibc-static BuildRequires: doxygen @@ -50,7 +51,7 @@ Provides: %{name}-static = %{version}-%{release} %build -make V=1 CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags} all doc +make V=1 CFLAGS="%{build_cflags}" LDFLAGS="%{build_ldflags}" %{?_smp_mflags} all doc %install @@ -80,6 +81,9 @@ make test-sh test %{_libdir}/libqc*.a %changelog +* Mon Mar 12 2018 Dan Horák - 1.3.1-3 +- fix LDFLAGS injection (#1552658) + * Fri Feb 09 2018 Fedora Release Engineering - 1.3.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild