]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
fix up makefile patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 20 Aug 2022 18:12:56 +0000 (20:12 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 20 Aug 2022 18:12:56 +0000 (20:12 +0200)
queue-4.14/makefile-link-with-z-noexecstack-no-warn-rwx-segments.patch
queue-4.14/x86-link-vdso-and-boot-with-z-noexecstack-no-warn-rwx-segments.patch
queue-4.19/makefile-link-with-z-noexecstack-no-warn-rwx-segments.patch
queue-4.19/x86-link-vdso-and-boot-with-z-noexecstack-no-warn-rwx-segments.patch
queue-4.9/makefile-link-with-z-noexecstack-no-warn-rwx-segments.patch
queue-4.9/x86-link-vdso-and-boot-with-z-noexecstack-no-warn-rwx-segments.patch
queue-5.10/makefile-link-with-z-noexecstack-no-warn-rwx-segments.patch
queue-5.10/x86-link-vdso-and-boot-with-z-noexecstack-no-warn-rwx-segments.patch
queue-5.4/makefile-link-with-z-noexecstack-no-warn-rwx-segments.patch
queue-5.4/x86-link-vdso-and-boot-with-z-noexecstack-no-warn-rwx-segments.patch

index b021329f2405166ab2a7498ada1b5c07eb6f92c2..0a79c1d77f8dea4e8721d0bddc8eee1f6a5dbfbf 100644 (file)
@@ -40,19 +40,17 @@ Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- Makefile |    5 +++++
- 1 file changed, 5 insertions(+)
+ Makefile |    +++
+ 1 file changed, 3 insertions(+)
 
 --- a/Makefile
 +++ b/Makefile
-@@ -873,6 +873,11 @@ ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATI
+@@ -873,6 +873,9 @@ ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATI
  LDFLAGS_vmlinux       += $(call ld-option, --gc-sections,)
  endif
  
 +LDFLAGS       += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +LDFLAGS       += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  ifeq ($(CONFIG_STRIP_ASM_SYMS),y)
  LDFLAGS_vmlinux       += $(call ld-option, -X,)
index da767fd91d83c5856627b9a8ebfb3e783d835140..4a81185cd051024b98adcc7a400655bd93bc6bb6 100644 (file)
@@ -41,9 +41,9 @@ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
  arch/x86/boot/Makefile            |    2 +-
- arch/x86/boot/compressed/Makefile |    6 ++++++
+ arch/x86/boot/compressed/Makefile |    ++++
  arch/x86/entry/vdso/Makefile      |    2 +-
- 3 files changed, 8 insertions(+), 2 deletions(-)
+ 3 files changed, 6 insertions(+), 2 deletions(-)
 
 --- a/arch/x86/boot/Makefile
 +++ b/arch/x86/boot/Makefile
@@ -58,15 +58,13 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  
 --- a/arch/x86/boot/compressed/Makefile
 +++ b/arch/x86/boot/compressed/Makefile
-@@ -55,6 +55,12 @@ else
+@@ -55,6 +55,10 @@ else
  LDFLAGS += $(shell $(LD) --help 2>&1 | grep -q "\-z noreloc-overflow" \
        && echo "-z noreloc-overflow -pie --no-dynamic-linker")
  endif
 +
 +LDFLAGS += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +LDFLAGS += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  LDFLAGS_vmlinux := -T
  
index 7f89376268766cdddf952d6f0e4a58a002d8b472..ad1ba857065e9446c0ed22009cf1482a7202db31 100644 (file)
@@ -40,19 +40,17 @@ Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- Makefile |    5 +++++
- 1 file changed, 5 insertions(+)
+ Makefile |    +++
+ 1 file changed, 3 insertions(+)
 
 --- a/Makefile
 +++ b/Makefile
-@@ -876,6 +876,11 @@ LDFLAGS_BUILD_ID := $(call ld-option, --
+@@ -876,6 +876,9 @@ LDFLAGS_BUILD_ID := $(call ld-option, --
  KBUILD_LDFLAGS_MODULE += $(LDFLAGS_BUILD_ID)
  LDFLAGS_vmlinux += $(LDFLAGS_BUILD_ID)
  
 +KBUILD_LDFLAGS        += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +KBUILD_LDFLAGS        += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  ifeq ($(CONFIG_STRIP_ASM_SYMS),y)
  LDFLAGS_vmlinux       += $(call ld-option, -X,)
index 47aa9cb5cf19ee23b7ffabe3994d28929b17df64..536fb8f276c4daeffac59643dd216e27a78bdd6b 100644 (file)
@@ -41,9 +41,9 @@ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
  arch/x86/boot/Makefile            |    2 +-
- arch/x86/boot/compressed/Makefile |    6 ++++++
+ arch/x86/boot/compressed/Makefile |    ++++
  arch/x86/entry/vdso/Makefile      |    2 +-
- 3 files changed, 8 insertions(+), 2 deletions(-)
+ 3 files changed, 6 insertions(+), 2 deletions(-)
 
 --- a/arch/x86/boot/Makefile
 +++ b/arch/x86/boot/Makefile
@@ -58,15 +58,13 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  
 --- a/arch/x86/boot/compressed/Makefile
 +++ b/arch/x86/boot/compressed/Makefile
-@@ -57,6 +57,12 @@ else
+@@ -57,6 +57,10 @@ else
  KBUILD_LDFLAGS += $(shell $(LD) --help 2>&1 | grep -q "\-z noreloc-overflow" \
        && echo "-z noreloc-overflow -pie --no-dynamic-linker")
  endif
 +
 +KBUILD_LDFLAGS += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +KBUILD_LDFLAGS += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  LDFLAGS_vmlinux := -T
  
index 398b6eb2fb3e9cc62703647624b9e0de1a4a9410..a95109c3d5de143ae2fae3c871c3e610bf630783 100644 (file)
@@ -40,19 +40,17 @@ Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- Makefile |    5 +++++
- 1 file changed, 5 insertions(+)
+ Makefile |    +++
+ 1 file changed, 3 insertions(+)
 
 --- a/Makefile
 +++ b/Makefile
-@@ -870,6 +870,11 @@ ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATI
+@@ -870,6 +870,9 @@ ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATI
  LDFLAGS_vmlinux       += $(call ld-option, --gc-sections,)
  endif
  
 +LDFLAGS       += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +LDFLAGS       += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  ifeq ($(CONFIG_STRIP_ASM_SYMS),y)
  LDFLAGS_vmlinux       += $(call ld-option, -X,)
index f41cd82cf6ff4a81742ea51bca6dd827dede160f..811a66b049a12dfbe5381e3caba2160b7597ab82 100644 (file)
@@ -41,9 +41,9 @@ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
  arch/x86/boot/Makefile            |    2 +-
- arch/x86/boot/compressed/Makefile |    6 ++++++
+ arch/x86/boot/compressed/Makefile |    ++++
  arch/x86/entry/vdso/Makefile      |    2 +-
- 3 files changed, 8 insertions(+), 2 deletions(-)
+ 3 files changed, 6 insertions(+), 2 deletions(-)
 
 --- a/arch/x86/boot/Makefile
 +++ b/arch/x86/boot/Makefile
@@ -58,15 +58,13 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  
 --- a/arch/x86/boot/compressed/Makefile
 +++ b/arch/x86/boot/compressed/Makefile
-@@ -54,6 +54,12 @@ else
+@@ -54,6 +54,10 @@ else
  LDFLAGS += $(shell $(LD) --help 2>&1 | grep -q "\-z noreloc-overflow" \
        && echo "-z noreloc-overflow -pie --no-dynamic-linker")
  endif
 +
 +LDFLAGS += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +LDFLAGS += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  LDFLAGS_vmlinux := -T
  
index 0ec29b55e96cb97a0f0bfc778af165b492214fb1..bc1fb3be808e752e09dd77c738081aab37f3ec7e 100644 (file)
@@ -40,19 +40,17 @@ Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- Makefile |    5 +++++
- 1 file changed, 5 insertions(+)
+ Makefile |    +++
+ 1 file changed, 3 insertions(+)
 
 --- a/Makefile
 +++ b/Makefile
-@@ -983,6 +983,11 @@ KBUILD_CFLAGS   += $(KCFLAGS)
+@@ -983,6 +983,9 @@ KBUILD_CFLAGS   += $(KCFLAGS)
  KBUILD_LDFLAGS_MODULE += --build-id=sha1
  LDFLAGS_vmlinux += --build-id=sha1
  
 +KBUILD_LDFLAGS        += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +KBUILD_LDFLAGS        += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  ifeq ($(CONFIG_STRIP_ASM_SYMS),y)
  LDFLAGS_vmlinux       += $(call ld-option, -X,)
index 67442190ed28cde67719383f9de432206ab928e6..0ca022d6bc72d4a964cbd4acb23bf7ebde2f7b6f 100644 (file)
@@ -41,9 +41,9 @@ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
  arch/x86/boot/Makefile            |    2 +-
- arch/x86/boot/compressed/Makefile |    4 ++++
+ arch/x86/boot/compressed/Makefile |    ++
  arch/x86/entry/vdso/Makefile      |    2 +-
- 3 files changed, 6 insertions(+), 2 deletions(-)
+ 3 files changed, 4 insertions(+), 2 deletions(-)
 
 --- a/arch/x86/boot/Makefile
 +++ b/arch/x86/boot/Makefile
@@ -58,14 +58,12 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  
 --- a/arch/x86/boot/compressed/Makefile
 +++ b/arch/x86/boot/compressed/Makefile
-@@ -68,6 +68,10 @@ LDFLAGS_vmlinux := -pie $(call ld-option
+@@ -68,6 +68,8 @@ LDFLAGS_vmlinux := -pie $(call ld-option
  ifdef CONFIG_LD_ORPHAN_WARN
  LDFLAGS_vmlinux += --orphan-handling=warn
  endif
 +LDFLAGS_vmlinux += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +LDFLAGS_vmlinux += $(call ld-option,--no-warn-rwx-segments)
-+endif
  LDFLAGS_vmlinux += -T
  
  hostprogs     := mkpiggy
index 62874fc6aba08ede7314a2e344e16a676b418109..3f0d3efceda2e831b9e3741a9799ef7ec5f2f38c 100644 (file)
@@ -40,19 +40,17 @@ Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- Makefile |    5 +++++
- 1 file changed, 5 insertions(+)
+ Makefile |    +++
+ 1 file changed, 3 insertions(+)
 
 --- a/Makefile
 +++ b/Makefile
-@@ -932,6 +932,11 @@ KBUILD_CFLAGS   += $(KCFLAGS)
+@@ -932,6 +932,9 @@ KBUILD_CFLAGS   += $(KCFLAGS)
  KBUILD_LDFLAGS_MODULE += --build-id
  LDFLAGS_vmlinux += --build-id
  
 +KBUILD_LDFLAGS        += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +KBUILD_LDFLAGS        += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  ifeq ($(CONFIG_STRIP_ASM_SYMS),y)
  LDFLAGS_vmlinux       += $(call ld-option, -X,)
index ea8e71118f823c5af99904b6c6610abe932a9c61..cc84125c578663e2dce3c35d05cb58af3bfec284 100644 (file)
@@ -41,9 +41,9 @@ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
  arch/x86/boot/Makefile            |    2 +-
- arch/x86/boot/compressed/Makefile |    6 ++++++
+ arch/x86/boot/compressed/Makefile |    ++++
  arch/x86/entry/vdso/Makefile      |    2 +-
- 3 files changed, 8 insertions(+), 2 deletions(-)
+ 3 files changed, 6 insertions(+), 2 deletions(-)
 
 --- a/arch/x86/boot/Makefile
 +++ b/arch/x86/boot/Makefile
@@ -58,15 +58,13 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  
 --- a/arch/x86/boot/compressed/Makefile
 +++ b/arch/x86/boot/compressed/Makefile
-@@ -57,6 +57,12 @@ else
+@@ -57,6 +57,10 @@ else
  KBUILD_LDFLAGS += $(shell $(LD) --help 2>&1 | grep -q "\-z noreloc-overflow" \
        && echo "-z noreloc-overflow -pie --no-dynamic-linker")
  endif
 +
 +KBUILD_LDFLAGS += -z noexecstack
-+ifeq ($(CONFIG_LD_IS_BFD),y)
 +KBUILD_LDFLAGS += $(call ld-option,--no-warn-rwx-segments)
-+endif
 +
  LDFLAGS_vmlinux := -T