make/bsd/makefiles/gcc.make
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File hs-comp-code-aging Cdiff make/bsd/makefiles/gcc.make

make/bsd/makefiles/gcc.make

Print this page

        

*** 251,269 **** endif ifeq ($(USE_CLANG), true) # However we need to clean the code up before we can unrestrictedly enable this option with Clang WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses ! WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-compare # Not yet supported by clang in Xcode 4.6.2 # WARNINGS_ARE_ERRORS += -Wno-tautological-constant-out-of-range-compare WARNINGS_ARE_ERRORS += -Wno-delete-non-virtual-dtor -Wno-deprecated -Wno-format -Wno-dynamic-class-memaccess WARNINGS_ARE_ERRORS += -Wno-empty-body endif WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef -Wunused-function -Wformat=2 ifeq ($(USE_CLANG),) # Since GCC 4.3, -Wconversion has changed its meanings to warn these implicit # conversions which might affect the values. Only enable it in earlier versions. ifeq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0" WARNINGS_FLAGS += -Wconversion --- 251,273 ---- endif ifeq ($(USE_CLANG), true) # However we need to clean the code up before we can unrestrictedly enable this option with Clang WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses ! WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-compare -Wno-string-plus-int # Not yet supported by clang in Xcode 4.6.2 # WARNINGS_ARE_ERRORS += -Wno-tautological-constant-out-of-range-compare WARNINGS_ARE_ERRORS += -Wno-delete-non-virtual-dtor -Wno-deprecated -Wno-format -Wno-dynamic-class-memaccess WARNINGS_ARE_ERRORS += -Wno-empty-body endif WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef -Wunused-function -Wformat=2 + ifeq ($(USE_CLANG), true) + WARNING_FLAGS += -Wno-format-nonliteral + endif + ifeq ($(USE_CLANG),) # Since GCC 4.3, -Wconversion has changed its meanings to warn these implicit # conversions which might affect the values. Only enable it in earlier versions. ifeq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0" WARNINGS_FLAGS += -Wconversion
*** 311,331 **** --- 315,355 ---- OPT_CFLAGS/NOOPT=-O0 # Work around some compiler bugs. ifeq ($(USE_CLANG), true) + # Clang 4.2 ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 2), 1) OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT) OPT_CFLAGS/unsafe.o += -O1 endif + # Clang 5.0 + ifeq ($(shell expr $(CC_VER_MAJOR) = 5 \& $(CC_VER_MINOR) = 0), 1) + OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT) + OPT_CFLAGS/unsafe.o += -O1 + endif + # Clang 5.1 + ifeq ($(shell expr $(CC_VER_MAJOR) = 5 \& $(CC_VER_MINOR) = 1), 1) + OPT_CFLAGS/loopTransform.o += $(OPT_CFLAGS/NOOPT) + OPT_CFLAGS/unsafe.o += -O1 + endif else # 6835796. Problem in GCC 4.3.0 with mulnode.o optimized compilation. ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 3), 1) OPT_CFLAGS/mulnode.o += $(OPT_CFLAGS/NOOPT) endif endif + # We want to use libc++ on Clang 5.0 + ifeq ($(USE_CLANG), true) + # Clang 5.x + ifeq ($(shell expr $(CC_VER_MAJOR) = 5), 1) + CFLAGS += -stdlib=libc++ + LFLAGS += -stdlib=libc++ + endif + endif + # Flags for generating make dependency flags. DEPFLAGS = -MMD -MP -MF $(DEP_DIR)/$(@:%=%.d) ifeq ($(USE_CLANG),) ifneq ($(CC_VER_MAJOR), 2) DEPFLAGS += -fpch-deps
*** 362,376 **** # Linker flags # statically link libstdc++.so, work with gcc but ignored by g++ STATIC_STDCXX = -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic - # Ensure use libstdc++ on clang, not libc++ - ifeq ($(USE_CLANG), true) - LFLAGS += -stdlib=libstdc++ - endif - ifeq ($(USE_CLANG),) # statically link libgcc and/or libgcc_s, libgcc does not exist before gcc-3.x. ifneq ("${CC_VER_MAJOR}", "2") STATIC_LIBGCC += -static-libgcc endif --- 386,395 ----
make/bsd/makefiles/gcc.make
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File