summaryrefslogtreecommitdiff
path: root/debian/patches/conditional-stack-protector-all.patch
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2020-04-17 20:57:34 +0100
committerColin Watson <cjwatson@debian.org>2020-04-18 09:48:21 +0100
commitdf7226c4b684fd229dc046388225c69ded877721 (patch)
treee69014e1ee868c4ec178b8a36baae7de31786beb /debian/patches/conditional-stack-protector-all.patch
parentf794345c2d734f593da8ed7754e5dbb5809c688d (diff)
parent75073d0a8478441cc97a6efa10b566c5fb1dac81 (diff)
Update upstream source from tag 'upstream/1.4.0'
Update to upstream version '1.4.0' with Debian dir 64889867df57bd13ea0cb964223697d378d391ce
Diffstat (limited to 'debian/patches/conditional-stack-protector-all.patch')
-rw-r--r--debian/patches/conditional-stack-protector-all.patch31
1 files changed, 0 insertions, 31 deletions
diff --git a/debian/patches/conditional-stack-protector-all.patch b/debian/patches/conditional-stack-protector-all.patch
deleted file mode 100644
index 99fa85e..0000000
--- a/debian/patches/conditional-stack-protector-all.patch
+++ /dev/null
@@ -1,31 +0,0 @@
1Subject: Only use -fstack-protector-all if it is supported
2
3This flag isn't available on all Debian ports.
4
5Origin: vendor
6From: Colin Watson <cjwatson@debian.org>
7Reviewed-by: nicoo <nicoo@debian.org>
8Forwarded: https://github.com/Yubico/libfido2/pull/130
9Applied-Upstream: not-yet
10Last-Update: 2020-02-23
11
12---
13 CMakeLists.txt | 5 ++++-
14 1 file changed, 4 insertions(+), 1 deletion(-)
15
16diff --git a/CMakeLists.txt b/CMakeLists.txt
17index c7c5991..07ca5e1 100644
18--- a/CMakeLists.txt
19+++ b/CMakeLists.txt
20@@ -114,7 +114,10 @@ else()
21 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wbad-function-cast")
22 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pedantic")
23 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pedantic-errors")
24- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fstack-protector-all")
25+ check_c_compiler_flag("-fstack-protector-all" HAVE_STACK_PROTECTOR_ALL)
26+ if(HAVE_STACK_PROTECTOR_ALL)
27+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fstack-protector-all")
28+ endif()
29 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
30
31 set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -g2")