summaryrefslogtreecommitdiff
path: root/add-secure-compile-options-for-makedumpfile.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2024-07-26 17:19:39 +0000
committerCoprDistGit <infra@openeuler.org>2024-07-26 17:19:39 +0000
commit5be00af7c80ed4972c1f3379e6db9937e1a8b7bd (patch)
tree7938404f19676c304f68d0d47e475fe4a1440452 /add-secure-compile-options-for-makedumpfile.patch
parentad07ec0c7538028e4d732f63e34d58150f5ffd42 (diff)
automatic import of kexec-tools
Diffstat (limited to 'add-secure-compile-options-for-makedumpfile.patch')
-rw-r--r--add-secure-compile-options-for-makedumpfile.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/add-secure-compile-options-for-makedumpfile.patch b/add-secure-compile-options-for-makedumpfile.patch
new file mode 100644
index 0000000..a3207c3
--- /dev/null
+++ b/add-secure-compile-options-for-makedumpfile.patch
@@ -0,0 +1,32 @@
+From 776d8f6355fdf77ec63bae4be09b8f40d0c831ad Mon Sep 17 00:00:00 2001
+From: pengyeqing <pengyeqing@huawei.com>
+Date: Sun, 18 Aug 2019 23:59:23 +0000
+Subject: [PATCH] kexec-tools: add secure compile options for makedumpfile
+
+reason:add secure compile options for makedumpfile
+
+Signed-off-by: pengyeqing <pengyeqing@huawei.com>
+---
+ Makefile | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/makedumpfile-1.6.7/Makefile b/makedumpfile-1.6.7/Makefile
+index 612b9d0..180a64f 100644
+--- a/makedumpfile-1.7.3/Makefile
++++ b/makedumpfile-1.7.3/Makefile
+@@ -10,9 +10,10 @@ endif
+
+ CFLAGS_BASE := $(CFLAGS) -g -O2 -Wall -D_FILE_OFFSET_BITS=64 \
+ -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
+-CFLAGS := $(CFLAGS_BASE) -DVERSION='"$(VERSION)"' -DRELEASE_DATE='"$(DATE)"'
+-CFLAGS_ARCH := $(CFLAGS_BASE)
++CFLAGS := $(CFLAGS_BASE) -DVERSION='"$(VERSION)"' -DRELEASE_DATE='"$(DATE)"' -fstack-protector-strong -Wl,-z,now -fPIE
++CFLAGS_ARCH := $(CFLAGS_BASE) -fPIE
+ # LDFLAGS = -L/usr/local/lib -I/usr/local/include
++LDFLAGS += -pie
+
+ HOST_ARCH := $(shell uname -m)
+ # Use TARGET as the target architecture if specified.
+--
+1.8.3.1
+