[MLton-commit] r4557
Matthew Fluet
MLton@mlton.org
Sun, 21 May 2006 07:31:55 -0700
Fine-grained gcc options
----------------------------------------------------------------------
U mlton/branches/on-20050822-x86_64-branch/runtime/Makefile
----------------------------------------------------------------------
Modified: mlton/branches/on-20050822-x86_64-branch/runtime/Makefile
===================================================================
--- mlton/branches/on-20050822-x86_64-branch/runtime/Makefile 2006-05-21 14:26:24 UTC (rev 4556)
+++ mlton/branches/on-20050822-x86_64-branch/runtime/Makefile 2006-05-21 14:31:54 UTC (rev 4557)
@@ -83,10 +83,11 @@
GCOPTCFLAGS = $(GCOPTFLAGS)
WARNCFLAGS =
WARNCFLAGS += -pedantic -Wall
+ifeq ($(findstring $(GCC_MAJOR_VERSION), 3),$(GCC_MAJOR_VERSION))
+WARNCFLAGS += -W
+endif
ifeq ($(findstring $(GCC_MAJOR_VERSION), 4),$(GCC_MAJOR_VERSION))
WARNCFLAGS += -Wextra
-else
-WARNCFLAGS += -W
endif
# -Wformat=2 implies -Wformat-nonliteral, which causes spurious warnings.
WARNCFLAGS += -Wformat=2