From: sewardj Date: Tue, 3 Jul 2001 16:57:03 +0000 (+0000) Subject: [project @ 2001-07-03 16:57:03 by sewardj] X-Git-Tag: Approximately_9120_patches~1622 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=8146101659e5c24adee02c0a732b5096405f717d;p=ghc-hetmet.git [project @ 2001-07-03 16:57:03 by sewardj] Plumb top-level --with-gcc=... value around the place. --- diff --git a/configure.in b/configure.in index 3c6316a..b7ff483 100644 --- a/configure.in +++ b/configure.in @@ -386,7 +386,8 @@ AC_ARG_WITH(gcc, [ --with-gcc= Use a different command instead of 'gcc' for the GNU C compiler. ], -[WhatGccIsCalled="$withval"], +[WhatGccIsCalled="$withval" + CC="$withval"], [WhatGccIsCalled="gcc"] ) AC_SUBST(WhatGccIsCalled) diff --git a/ghc/rts/Makefile b/ghc/rts/Makefile index 5adfa21..27eeb21 100644 --- a/ghc/rts/Makefile +++ b/ghc/rts/Makefile @@ -1,5 +1,5 @@ #----------------------------------------------------------------------------- -# $Id: Makefile,v 1.50 2001/06/06 10:35:39 rrt Exp $ +# $Id: Makefile,v 1.51 2001/07/03 16:57:03 sewardj Exp $ # # This is the Makefile for the runtime-system stuff. # This stuff is written in C (and cannot be written in Haskell). @@ -158,7 +158,7 @@ else # Pass --target to configure of GMP, so that building for mingwin under # cygwin works properly (when the host is not the same as the target) boot :: - cd gmp && ./configure --enable-shared=no --target=$(HOSTPLATFORM) + cd gmp && CC=$(WhatGccIsCalled) ./configure --enable-shared=no --target=$(HOSTPLATFORM) endif # Slight cheatage here to pass host as target, but x-compilation isn't supported by ghc. diff --git a/ghc/utils/hsc2hs/KludgedSystem.hs b/ghc/utils/hsc2hs/KludgedSystem.hs index 4036df6..94a2441 100644 --- a/ghc/utils/hsc2hs/KludgedSystem.hs +++ b/ghc/utils/hsc2hs/KludgedSystem.hs @@ -1,6 +1,6 @@ {-# OPTIONS -cpp -fglasgow-exts #-} ----------------------------------------------------------------------------- --- $Id: KludgedSystem.hs,v 1.6 2001/04/02 16:10:05 rrt Exp $ +-- $Id: KludgedSystem.hs,v 1.7 2001/07/03 16:57:03 sewardj Exp $ -- system that works feasibly under Windows (i.e. passes the command line to sh, -- because system() under Windows doesn't look at SHELL, and always uses CMD.EXE) @@ -14,7 +14,7 @@ module KludgedSystem (system, defaultCompiler, progNameSuffix) where import System (system) defaultCompiler :: String -defaultCompiler = "gcc" +defaultCompiler = cGCC progNameSuffix = "" #else @@ -35,7 +35,7 @@ system cmd = do foreign import "_getpid" unsafe getProcessID :: IO Int defaultCompiler :: String -defaultCompiler = "gcc -mno-cygwin -mwin32" +defaultCompiler = cGCC ++ " -mno-cygwin" progNameSuffix = ".exe" #endif /* mingw32_TARGET_OS */ diff --git a/ghc/utils/hsc2hs/Makefile b/ghc/utils/hsc2hs/Makefile index 72526e5..7bc13c0 100644 --- a/ghc/utils/hsc2hs/Makefile +++ b/ghc/utils/hsc2hs/Makefile @@ -1,5 +1,5 @@ # ----------------------------------------------------------------------------- -# $Id: Makefile,v 1.16 2001/06/27 06:18:40 sof Exp $ +# $Id: Makefile,v 1.17 2001/07/03 16:57:03 sewardj Exp $ TOP=../.. include $(TOP)/mk/boilerplate.mk @@ -66,6 +66,7 @@ $(CONFIG_HS) : $(FPTOOLS_TOP)/mk/config.mk Makefile @echo -n "Creating $(CONFIG_HS) ... " @echo "module Config where" >>$(CONFIG_HS) @echo "cDEFAULT_TMPDIR = \"$(DEFAULT_TMPDIR)\"" >> $(CONFIG_HS) + @echo "cGCC = \"$(WhatGccIsCalled)\"" >> $(CONFIG_HS) @echo done. CLEAN_FILES += $(CONFIG_HS)