aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric <ewild@sysmocom.de>2023-08-30 11:54:12 +0200
committerEric <ewild@sysmocom.de>2023-08-30 11:54:26 +0200
commit287ae681b726c746958347752c271c818e277e75 (patch)
tree96fab8d765b280b3c0c4c95f054dbb0816d584d5
parentcca5d93f661b27a1895dc12c624cd1a93b0a9c05 (diff)
ms/va: make ancient gcc < 8 happy
-rw-r--r--Transceiver52M/grgsm_vitac/grgsm_vitac.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/Transceiver52M/grgsm_vitac/grgsm_vitac.h b/Transceiver52M/grgsm_vitac/grgsm_vitac.h
index d00c3ad..c1e470c 100644
--- a/Transceiver52M/grgsm_vitac/grgsm_vitac.h
+++ b/Transceiver52M/grgsm_vitac/grgsm_vitac.h
@@ -42,6 +42,10 @@
#define MULTI_VER_TARGET_ATTR_CLANGONLY
#endif
+/* ancient gcc < 8 has no attribute, clang always pretends to be gcc 4 */
+#if !defined(__clang__) && __GNUC__ < 8
+#define NO_UBSAN __attribute__((no_sanitize_undefined))
+#else
#if defined(__has_attribute)
#if __has_attribute(no_sanitize)
#define NO_UBSAN __attribute__((no_sanitize("undefined")))
@@ -49,6 +53,7 @@
#else
#define NO_UBSAN
#endif
+#endif
#define SYNC_SEARCH_RANGE 30
const int d_OSR(4);