diff options
author | Robert Clausecker <fuz@FreeBSD.org> | 2023-04-19 14:00:49 +0200 |
---|---|---|
committer | Robert Clausecker <fuz@FreeBSD.org> | 2023-04-20 13:49:22 +0200 |
commit | 221dac0087ec47c24c00074a6c66479cae9c227b (patch) | |
tree | a0eea893f4e1196b0ba83297ead44a482f6f4ff4 /security/cryptlib/files/patch-tools_ccopts.sh | |
parent | devel/py-fastbencode: update to 0.2 (diff) |
security/cryptlib: fix build on armv6/armv7
The clang option -fsanitize=safe-stack is not supported on armv6/armv7.
Patch the option detection script to not enable it there.
Approved by: portmgr (build fix blanket)
Diffstat (limited to 'security/cryptlib/files/patch-tools_ccopts.sh')
-rw-r--r-- | security/cryptlib/files/patch-tools_ccopts.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/security/cryptlib/files/patch-tools_ccopts.sh b/security/cryptlib/files/patch-tools_ccopts.sh index f0c1781caf8f..ba77cf411fb5 100644 --- a/security/cryptlib/files/patch-tools_ccopts.sh +++ b/security/cryptlib/files/patch-tools_ccopts.sh @@ -1,5 +1,14 @@ --- tools/ccopts.sh.orig 2021-10-21 02:27:26 UTC +++ tools/ccopts.sh +@@ -675,7 +675,7 @@ hasSafeStackLibs() + + if [ $ISCLANG -gt 0 ] && [ $ISSPECIAL -eq 0 ] ; then + if [ $COMPILER_VER -ge 47 ] ; then +- if [ "$OSNAME" = "Darwin" ] || [ "$OSNAME" = "OpenBSD" ] ; then ++ if [ "$OSNAME" = "Darwin" ] || [ "$OSNAME" = "OpenBSD" ] || [ "$OSNAME" = "FreeBSD" -a "$ARCH" = "arm" ] ; then + # The versions of clang shipped with OS X or OpenBSD don't + # support -fsanitize=safe-stack even as late as clang 12, so + # there's not much that we can do. @@ -892,31 +892,6 @@ fi # a big deal. As a convenient side-effect, this also enables the use of # ASLR where it's supported. |