Ver código fonte

Revert "Update compilation warning flags (#1151)"

This reverts commit 2528854664b78a7db24cbe97b5b4e8bd52e1f18c.
raysan5 5 anos atrás
pai
commit
66e0d774bd
2 arquivos alterados com 4 adições e 8 exclusões
  1. 2 4
      examples/Makefile
  2. 2 4
      src/Makefile

+ 2 - 4
examples/Makefile

@@ -182,14 +182,12 @@ endif
 #  -O1                  defines optimization level
 #  -O1                  defines optimization level
 #  -g                   include debug information on compilation
 #  -g                   include debug information on compilation
 #  -s                   strip unnecessary data from build
 #  -s                   strip unnecessary data from build
+#  -Wall                turns on most, but not all, compiler warnings
 #  -std=c99             defines C language mode (standard C from 1999 revision)
 #  -std=c99             defines C language mode (standard C from 1999 revision)
 #  -std=gnu99           defines C language mode (GNU C from 1999 revision)
 #  -std=gnu99           defines C language mode (GNU C from 1999 revision)
 #  -Wno-missing-braces  ignore invalid warning (GCC bug 53119)
 #  -Wno-missing-braces  ignore invalid warning (GCC bug 53119)
 #  -D_DEFAULT_SOURCE    use with -std=c99 on Linux and PLATFORM_WEB, required for timespec
 #  -D_DEFAULT_SOURCE    use with -std=c99 on Linux and PLATFORM_WEB, required for timespec
-CFLAGS += -std=c99 -D_DEFAULT_SOURCE -Wno-missing-braces
-
-# Define compiler warning flags:
-CFLAGS += -Wbool-compare -Wbool-operation -Wbuiltin-declaration-mismatch -Wcast-align -Wchar-subscripts -Wchkp -Wdeprecated -Wformat-overflow -Wfree-nonheap-object -Wimplicit -Wint-in-bool-context -Wint-to-pointer-cast -Wmissing-parameter-type  -Woverlength-strings -Wpointer-sign -Wpointer-to-int-cast -Wunused-label -Wunused-local-typedefs -Wunused-result 
+CFLAGS += -Wall -std=c99 -D_DEFAULT_SOURCE -Wno-missing-braces
 
 
 ifeq ($(BUILD_MODE),DEBUG)
 ifeq ($(BUILD_MODE),DEBUG)
     CFLAGS += -g
     CFLAGS += -g

+ 2 - 4
src/Makefile

@@ -265,16 +265,14 @@ endif
 #  -O1                      defines optimization level
 #  -O1                      defines optimization level
 #  -g                       include debug information on compilation
 #  -g                       include debug information on compilation
 #  -s                       strip unnecessary data from build
 #  -s                       strip unnecessary data from build
+#  -Wall                    turns on most, but not all, compiler warnings
 #  -std=c99                 defines C language mode (standard C from 1999 revision)
 #  -std=c99                 defines C language mode (standard C from 1999 revision)
 #  -std=gnu99               defines C language mode (GNU C from 1999 revision)
 #  -std=gnu99               defines C language mode (GNU C from 1999 revision)
 #  -Wno-missing-braces      ignore invalid warning (GCC bug 53119)
 #  -Wno-missing-braces      ignore invalid warning (GCC bug 53119)
 #  -D_DEFAULT_SOURCE        use with -std=c99 on Linux and PLATFORM_WEB, required for timespec
 #  -D_DEFAULT_SOURCE        use with -std=c99 on Linux and PLATFORM_WEB, required for timespec
 #  -Werror=pointer-arith    catch unportable code that does direct arithmetic on void pointers
 #  -Werror=pointer-arith    catch unportable code that does direct arithmetic on void pointers
 #  -fno-strict-aliasing     jar_xm.h does shady stuff (breaks strict aliasing)
 #  -fno-strict-aliasing     jar_xm.h does shady stuff (breaks strict aliasing)
-CFLAGS += -D_DEFAULT_SOURCE -Wno-missing-braces -Werror=pointer-arith -fno-strict-aliasing
-
-# Define compiler warning flags:
-CFLAGS += -Wbool-compare -Wbool-operation -Wbuiltin-declaration-mismatch -Wcast-align -Wchar-subscripts -Wchkp -Wdeprecated -Wformat-overflow -Wfree-nonheap-object -Wimplicit -Wint-in-bool-context -Wint-to-pointer-cast -Wmissing-parameter-type  -Woverlength-strings -Wpointer-sign -Wpointer-to-int-cast -Wunused-label -Wunused-local-typedefs -Wunused-result 
+CFLAGS += -Wall -D_DEFAULT_SOURCE -Wno-missing-braces -Werror=pointer-arith -fno-strict-aliasing
 
 
 ifeq ($(PLATFORM), PLATFORM_WEB)
 ifeq ($(PLATFORM), PLATFORM_WEB)
     CFLAGS += -std=gnu99
     CFLAGS += -std=gnu99