summaryrefslogtreecommitdiffstats
path: root/GNUmakefile
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2009-10-15 08:15:06 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2009-10-15 08:15:06 +0000
commit1fdf489cae5606abd979d789319894adfd285a76 (patch)
tree002144c1704618760cdc268072caffa3719e5293 /GNUmakefile
parent0614ca434a6ff0995ea52b1852cc4639252931cb (diff)
Turn off stupid warnings when using Sun CC.
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile10
1 files changed, 8 insertions, 2 deletions
diff --git a/GNUmakefile b/GNUmakefile
index f3b2f2e2..8010fa3d 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -1,4 +1,4 @@
-# $Id: GNUmakefile,v 1.116 2009-09-20 22:06:34 tcunha Exp $
+# $Id: GNUmakefile,v 1.117 2009-10-15 08:15:06 nicm Exp $
.PHONY: clean
@@ -6,11 +6,17 @@ VERSION= 1.1
FDEBUG= 1
-CC?= gcc
+CC?= cc
CFLAGS+= -DBUILD="\"$(VERSION)\""
LDFLAGS+= -L/usr/local/lib
LIBS+=
+# Sun CC
+ifneq ($(shell (cc -V 2>&1|awk '/Sun C/' || true)), )
+ CFLAGS+=-erroff=E_EMPTY_DECLARATION
+ FDEBUG=
+endif
+
ifdef FDEBUG
CFLAGS+= -g -ggdb -DDEBUG
CFLAGS+= -Wno-long-long -Wall -W -Wnested-externs -Wformat=2