From 9d4020fec643e94cd46c97a2974d841ea8e876a3 Mon Sep 17 00:00:00 2001
From: Deuce <shurd@sasktel.net>
Date: Sun, 24 Jan 2021 07:50:10 -0500
Subject: [PATCH] Oh, so much patch.

---
 3rdp/build/cl-no-safe-stack.patch | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/3rdp/build/cl-no-safe-stack.patch b/3rdp/build/cl-no-safe-stack.patch
index ccf91173dd..2ba38b8f62 100644
--- a/3rdp/build/cl-no-safe-stack.patch
+++ b/3rdp/build/cl-no-safe-stack.patch
@@ -22,11 +22,11 @@
 +echo "$LDARGS"
 --- tools/ccopts.sh.orig	2020-11-26 02:40:05.222021000 -0500
 +++ tools/ccopts.sh	2021-01-24 07:41:02.126230000 -0500
-@@ -357,10 +357,10 @@
+@@ -358,9 +358,9 @@
  # tools/getlibs.sh also for clang 4.7 or newer.
  
  if [ $ISCLANG -gt 0 ] && [ $ISSPECIAL -eq 0 ] ; then
--	CLANG_VER="$($CC -dumpversion | tr -d  '.' | cut -c 1-2)" ;
+	CLANG_VER="$($CC -dumpversion | sed -E 's/^([0-9]+)$/\1.0/' | sed -E 's/^([0-9]+)\.([0-9]).*$/\1\2/')" ;
 -	if [ $CLANG_VER -gt 42 ] ; then
 -		CCARGS="$CCARGS -fsanitize=safe-stack" ;
 -	fi ;
-- 
GitLab