r9671 jmb - /trunk/libwapcaplet/Makefile
by netsurf@semichrome.net
Author: jmb
Date: Fri Nov 6 01:05:53 2009
New Revision: 9671
URL: http://source.netsurf-browser.org?rev=9671&view=rev
Log:
-Wextra is only understood by GCC 3.4.6 or later.
It is a more descriptive synonym for -W.
Use -W instead which is understood by all common versions of GCC
(i.e. GCC 2.95 supports it, which is the oldest GCC version we have to support)
Additionally, conditionalise our -Werror usage on whether we're building for
BeOS/Haiku. On these platforms, the standard library headers result in warnings.
GCC 2 is quite happy to build this code on other platforms, so shouldn't be
the trigger for dropping -Werror (even if BeOS is the only target where GCC2 is
likely to be used).
Modified:
trunk/libwapcaplet/Makefile
Modified: trunk/libwapcaplet/Makefile
URL: http://source.netsurf-browser.org/trunk/libwapcaplet/Makefile?rev=9671&r1...
==============================================================================
--- trunk/libwapcaplet/Makefile (original)
+++ trunk/libwapcaplet/Makefile Fri Nov 6 01:05:53 2009
@@ -11,11 +11,12 @@
TESTRUNNER = $(BUILDDIR)/test_testrunner$(EXEEXT)
# Toolchain flags
-WARNFLAGS := -Wall -Wundef -Wpointer-arith -Wcast-align \
+WARNFLAGS := -Wall -W -Wundef -Wpointer-arith -Wcast-align \
-Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes \
- -Wmissing-declarations -Wnested-externs -Werror -pedantic
-ifneq ($(GCCVER),2)
- WARNFLAGS := $(WARNFLAGS) -Wextra
+ -Wmissing-declarations -Wnested-externs -pedantic
+# BeOS/Haiku standard library headers issue warnings
+ifneq ($(TARGET),beos)
+ WARNFLAGS := $(WARNFLAGS) -Werror
endif
CFLAGS := -D_BSD_SOURCE -I$(CURDIR)/include/ \
-I$(CURDIR)/src $(WARNFLAGS) $(CFLAGS)