From a0b9daf63bfb0b5e7cd59806a9329382122dcac6 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Thu, 19 Dec 2013 20:42:59 -0800 Subject: Improve signing script, adjust flags for gcc-4.2 On one of my machines codesign doesn't find my signing key by hash, but does find it by name. Go figure. Also on that same system (32bit Mac Mini with running Snow Leopard / 10.6) gcc 4.2 doesn't support the -unused-result warning. So let's only turn that on for more modern versions of gcc Signed-off-by: Dirk Hohndel --- subsurface-configure.pri | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'subsurface-configure.pri') diff --git a/subsurface-configure.pri b/subsurface-configure.pri index 24bf08638..2a369da2b 100644 --- a/subsurface-configure.pri +++ b/subsurface-configure.pri @@ -10,7 +10,16 @@ # these warnings are in general just wrong and annoying - but should be # turned on every once in a while in case they do show the occasional # actual bug -*-g++* | *-clang*: QMAKE_CFLAGS += -Wno-unused-result -Wno-pointer-sign -fno-strict-overflow +# turns out the gcc 4.2 (as used on MacOS 10.6) doesn't have no-unused-result, yet +*-clang*: QMAKE_CFLAGS += -Wno-unused-result -Wno-pointer-sign -fno-strict-overflow +*-g++*: { + system( g++ --version | grep -e "4\\.2\\." > /dev/null ) { + QMAKE_CFLAGS += -Wno-pointer-sign -fno-strict-overflow + } else { + QMAKE_CFLAGS += -Wno-unused-result -Wno-pointer-sign -fno-strict-overflow + } +} + *-clang*: QMAKE_CFLAGS += -Wno-format-security *-g++*: QMAKE_CXXFLAGS += -fno-strict-overflow !win32: !mac: { -- cgit v1.2.3-70-g09d2