From af93ebf6add8f13ee2c3b357d8b737fd62123bee Mon Sep 17 00:00:00 2001 From: Al Stone Date: Oct 01 2014 19:31:13 +0000 Subject: Add use of %__global_ldflags. Closes BZ#1126134. Signed-off-by: Al Stone --- diff --git a/OPT_LDFLAGS.patch b/OPT_LDFLAGS.patch new file mode 100644 index 0000000..70ffaf4 --- /dev/null +++ b/OPT_LDFLAGS.patch @@ -0,0 +1,34 @@ +diff -Naur acpica-unix2-20140926/generate/unix/Makefile.config acpica-unix2-20140926-patch/generate/unix/Makefile.config +--- acpica-unix2-20140926/generate/unix/Makefile.config 2014-09-26 12:02:29.000000000 -0600 ++++ acpica-unix2-20140926-patch/generate/unix/Makefile.config 2014-10-01 12:53:53.510530248 -0600 +@@ -23,6 +23,9 @@ + # OPT_CFLAGS can be overridden on the make command line by + # adding OPT_CFLAGS="..." to the invocation. + # ++# OPT_LDFLAGS can be overridden on the make command line by ++# adding OPT_LDFLAGS="..." to the invocation. ++# + # Notes: + # gcc should be version 4 or greater, otherwise some of the options + # used will not be recognized. +@@ -43,7 +46,7 @@ + OBJDIR = obj + BINDIR = bin + COMPILEOBJ = $(CC) -c $(CFLAGS) $(OPT_CFLAGS) -o $@ $< +-LINKPROG = $(CC) $(OBJECTS) -o $(PROG) $(LDFLAGS) ++LINKPROG = $(CC) $(OBJECTS) -o $(PROG) $(LDFLAGS) $(OPT_LDFLAGS) + PREFIX ?= /usr + INSTALLDIR = $(PREFIX)/bin + UNAME_S := $(shell uname -s) +@@ -136,6 +139,11 @@ + OPT_CFLAGS ?= $(CWARNINGFLAGS) + + # ++# Common linker flags ++# ++OPT_LDFLAGS ?= ++ ++# + # Optionally disable optimizations. Optimization causes problems on + # some compilers such as gcc 4.4 + # diff --git a/acpica-tools.spec b/acpica-tools.spec index 457ab76..997ff55 100644 --- a/acpica-tools.spec +++ b/acpica-tools.spec @@ -31,6 +31,7 @@ Patch4: asllookup-miscompare.patch Patch5: aapits-makefile.patch Patch6: re-enable-big-endian.patch Patch7: aslts-always-reports.patch +Patch8: OPT_LDFLAGS.patch BuildRequires: bison patchutils flex @@ -89,6 +90,7 @@ gzip -dc %{SOURCE1} | tar -x --strip-components=1 -f - %patch5 -p1 -b .aapits-makefile %patch6 -p1 -b .re-enable-big-endian %patch7 -p1 -b .aslts-always-reports +%patch8 -p1 -b .OPT_LDFLAGS cp -p %{SOURCE2} README.Fedora cp -p %{SOURCE3} iasl.1 @@ -111,7 +113,7 @@ chmod a-x source/compiler/new_table.txt %build -make OPT_CFLAGS="%{optflags}" +make OPT_CFLAGS="%{optflags}" OPT_LDFLAGS="%{__global_ldflags}" %install @@ -198,6 +200,7 @@ fi - Refresh patches - Add patch to ensure ASLTS always reports when an error occurs, instead of glossing over it. +- Add use of %__global_ldflags. Closes BZ#1126134. * Fri Aug 29 2014 Al Stone - 20140828-1 - Update to latest upstream. Closes BZ#1135352.