]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
Makefile: Warn for unused macros only on Linux.
authorAndre Noll <maan@systemlinux.org>
Mon, 4 Jun 2012 08:29:42 +0000 (10:29 +0200)
committerAndre Noll <maan@systemlinux.org>
Mon, 4 Jun 2012 08:29:42 +0000 (10:29 +0200)
We need these macros at several places, but each of them causes
a compilier warning on FreeBSD and NetBSD where these macros are
not used at all.

This patch moves the -Wunused-macros option to the Linux-only
section.

Makefile.in

index 5760cad42189fbade5920b4d24573fc5407bc603..30a5c015a6f982dd5703aa51498aa89eda347b4e 100644 (file)
@@ -45,6 +45,8 @@ ifeq ($(uname_s),Linux)
        LDFLAGS += -Wl,--gc-sections
        CPPFLAGS += -Wstrict-prototypes
        CPPFLAGS += -Wshadow
        LDFLAGS += -Wl,--gc-sections
        CPPFLAGS += -Wstrict-prototypes
        CPPFLAGS += -Wshadow
+       # causes warnings on *BSD for the feature test macros
+       CPPFLAGS += -Wunused-macros
 endif
 CPPFLAGS += -Os
 CPPFLAGS += -Wuninitialized
 endif
 CPPFLAGS += -Os
 CPPFLAGS += -Wuninitialized
@@ -56,7 +58,6 @@ CPPFLAGS += -DCODENAME='"$(codename)"'
 CPPFLAGS += -DCC_VERSION='"$(cc_version)"'
 CPPFLAGS += -Werror-implicit-function-declaration
 CPPFLAGS += -Wmissing-noreturn
 CPPFLAGS += -DCC_VERSION='"$(cc_version)"'
 CPPFLAGS += -Werror-implicit-function-declaration
 CPPFLAGS += -Wmissing-noreturn
-CPPFLAGS += -Wunused-macros
 CPPFLAGS += -Wbad-function-cast
 CPPFLAGS += -fno-strict-aliasing
 CPPFLAGS += -DMAIN_INPUT_FILE_IS_$(*F)
 CPPFLAGS += -Wbad-function-cast
 CPPFLAGS += -fno-strict-aliasing
 CPPFLAGS += -DMAIN_INPUT_FILE_IS_$(*F)