diff --git a/gcc-no-undefined-flag-fix.patch b/gcc-no-undefined-flag-fix.patch new file mode 100644 index 0000000..8a627d0 --- /dev/null +++ b/gcc-no-undefined-flag-fix.patch @@ -0,0 +1,35 @@ +From 8880e5b8a295788dcae8f5cc038de92cd97b6807 Mon Sep 17 00:00:00 2001 +From: Simon Horman +Date: Wed, 30 Mar 2011 08:34:39 +0900 +Subject: build: Pass --no-undefined as a linker option +Git-commit: 8880e5b8a295788dcae8f5cc038de92cd97b6807 +Patch-mainline: yes + +gcc-4.6 does not accept --no-undefined as a compiler option + +Reported-by: Civil +Acked-by: "Eric W. Biederman" +Signed-off-by: Simon Horman +Signed-off-by: Jiri Slaby +--- + purgatory/Makefile | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/purgatory/Makefile b/purgatory/Makefile +index ea0c19a..ee1679c 100644 +--- a/purgatory/Makefile ++++ b/purgatory/Makefile +@@ -56,8 +56,8 @@ $(PURGATORY): CPPFLAGS=$($(ARCH)_PURGATORY_EXTRA_CFLAGS) \ + -I$(srcdir)/include \ + -I$(shell $(CC) -print-file-name=include) + $(PURGATORY): LDFLAGS=$($(ARCH)_PURGATORY_EXTRA_CFLAGS)\ +- --no-undefined -nostartfiles -nostdlib -nodefaultlibs \ +- -e purgatory_start -r ++ -Wl,--no-undefined -nostartfiles -nostdlib \ ++ -nodefaultlibs -e purgatory_start -r + + $(PURGATORY): $(PURGATORY_OBJS) + $(MKDIR) -p $(@D) +-- +1.7.4.2 + diff --git a/kexec-tools.changes b/kexec-tools.changes index 8364ff9..5b3eb22 100644 --- a/kexec-tools.changes +++ b/kexec-tools.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue May 17 11:12:54 CEST 2011 - jslaby@suse.de + +- fix build with gcc that doesn't understand --no-undefined + ------------------------------------------------------------------- Sun Sep 12 07:26:33 UTC 2010 - bernhard@bwalle.de diff --git a/kexec-tools.spec b/kexec-tools.spec index 098cf56..8c375c7 100644 --- a/kexec-tools.spec +++ b/kexec-tools.spec @@ -37,6 +37,7 @@ Source3: kexec.init Source4: %{name}-%{version}-rpmlintrc Patch0: %{name}-no-vga-output.diff Patch1: %{name}-xen-static.diff +Patch2: gcc-no-undefined-flag-fix.patch Url: ftp://kernel.org/pub/linux/utils/kernel/kexec/%{name}-%{version}.tar.bz2 BuildRoot: %{_tmppath}/%{name}-%{version}-build #!BuildIgnore: fop @@ -70,6 +71,7 @@ Authors: %setup -q -n kexec-tools-%{version} %patch0 -p1 %patch1 -p1 +%patch2 -p1 %build # disable as-needed