From: Manuel M T Chakravarty Date: Thu, 17 Sep 2009 13:27:06 +0000 (+0000) Subject: Use CONF_CC_OPTS X-Git-Tag: 2009-11-15~305 X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=commitdiff_plain;h=e6ca2d4ac1e3d86bd93e5884fbae03151c708862 Use CONF_CC_OPTS - Needed to get arch-dependent options, eg, on Snow Leopard --- diff --git a/compiler/typecheck/TcBinds.lhs b/compiler/typecheck/TcBinds.lhs index 9bf8faf..a71da2e 100644 --- a/compiler/typecheck/TcBinds.lhs +++ b/compiler/typecheck/TcBinds.lhs @@ -805,7 +805,8 @@ unifyCtxts :: [TcSigInfo] -> TcM [Inst] -- Post-condition: the returned Insts are full zonked unifyCtxts [] = panic "unifyCtxts []" unifyCtxts (sig1 : sigs) -- Argument is always non-empty - = do { mapM_ unify_ctxt sigs + = do { traceTc $ text "unifyCtxts" <+> ppr (sig1 : sigs) + ; mapM_ unify_ctxt sigs ; theta <- zonkTcThetaType (sig_theta sig1) ; newDictBndrs (sig_loc sig1) theta } where diff --git a/libffi/ghc.mk b/libffi/ghc.mk index ae41881..d3e57be 100644 --- a/libffi/ghc.mk +++ b/libffi/ghc.mk @@ -122,8 +122,8 @@ $(libffi_STAMP_CONFIGURE): export PATH; \ cd build && \ CC=$(WhatGccIsCalled) \ - CFLAGS="$(SRC_CC_OPTS) -w" \ - LDFLAGS="$(SRC_LD_OPTS) -w" \ + CFLAGS="$(SRC_CC_OPTS) $(CONF_CC_OPTS) -w" \ + LDFLAGS="$(SRC_LD_OPTS) $(CONF_LD_OPTS) -w" \ "$(SHELL)" configure \ --enable-static=yes \ --enable-shared=$(libffi_EnableShared) \ @@ -168,7 +168,7 @@ $(eval $(call all-target,libffi,libffi/libHSffi.a libffi/libHSffi_p.a)) libffi/HSffi.o: libffi/libHSffi.a cd libffi && \ touch empty.c; \ - "$(CC)" $(SRC_CC_OPTS) -c empty.c -o HSffi.o + "$(CC)" $(SRC_CC_OPTS) $(CONF_CC_OPTS) -c empty.c -o HSffi.o $(eval $(call all-target,libffi,libffi/HSffi.o)) diff --git a/mk/config.mk.in b/mk/config.mk.in index 93b5555..edcf625 100644 --- a/mk/config.mk.in +++ b/mk/config.mk.in @@ -551,7 +551,7 @@ ifeq "$(TARGETPLATFORM)" "ia64-unknown-linux" CONF_CC_OPTS += -G0 endif -SRC_HSC2HS_OPTS += $(addprefix --cflag=,$(filter-out -O,$(SRC_CC_OPTS))) +SRC_HSC2HS_OPTS += $(addprefix --cflag=,$(filter-out -O,$(SRC_CC_OPTS) $(CONF_CC_OPTS))) SRC_HSC2HS_OPTS += $(foreach d,$(GMP_INCLUDE_DIRS),-I$(d)) #----------------------------------------------------------------------------- diff --git a/rules/build-package-data.mk b/rules/build-package-data.mk index 4fe60f9..88e2c63 100644 --- a/rules/build-package-data.mk +++ b/rules/build-package-data.mk @@ -31,7 +31,7 @@ endif # We filter out -Werror from SRC_CC_OPTS, because when configure tests # for a feature it may not generate warning-free C code, and thus may # think that the feature doesn't exist if -Werror is on. -$1_$2_CONFIGURE_OPTS += --configure-option=CFLAGS="$$(filter-out -Werror,$$(SRC_CC_OPTS)) $$($1_CC_OPTS) $$($1_$2_CC_OPTS)" +$1_$2_CONFIGURE_OPTS += --configure-option=CFLAGS="$$(filter-out -Werror,$$(SRC_CC_OPTS)) $$(CONF_CC_OPTS) $$($1_CC_OPTS) $$($1_$2_CC_OPTS)" $1_$2_CONFIGURE_OPTS += --configure-option=LDFLAGS="$$(SRC_LD_OPTS) $$($1_LD_OPTS) $$($1_$2_LD_OPTS)" ifneq "$$(ICONV_INCLUDE_DIRS)" ""