[project @ 2001-03-27 16:33:17 by rrt]
authorrrt <unknown>
Tue, 27 Mar 2001 16:33:17 +0000 (16:33 +0000)
committerrrt <unknown>
Tue, 27 Mar 2001 16:33:17 +0000 (16:33 +0000)
Make it work on Windows with recent GCCs.

ghc/utils/hsc2hs/KludgedSystem.hs
ghc/utils/hsc2hs/Makefile

index 0b5bcd4..6f160d7 100644 (file)
@@ -1,6 +1,6 @@
 {-# OPTIONS -cpp -fglasgow-exts #-}
 -----------------------------------------------------------------------------
--- $Id: KludgedSystem.hs,v 1.4 2001/03/14 12:13:02 rrt Exp $
+-- $Id: KludgedSystem.hs,v 1.5 2001/03/27 16:33:17 rrt 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)
@@ -34,6 +34,6 @@ system cmd = do
 foreign import "_getpid" unsafe getProcessID :: IO Int
 
 defaultCompiler :: String
-defaultCompiler = "gcc -mno-cygwin"
+defaultCompiler = "gcc -mno-cygwin -mwin32"
 
 #endif /* mingw32_TARGET_OS */
index 64ef719..23a475e 100644 (file)
@@ -1,5 +1,5 @@
 # -----------------------------------------------------------------------------
-# $Id: Makefile,v 1.13 2001/03/23 16:36:22 simonmar Exp $
+# $Id: Makefile,v 1.14 2001/03/27 16:33:17 rrt Exp $
 
 TOP=../..
 include $(TOP)/mk/boilerplate.mk
@@ -36,7 +36,7 @@ HSC2HS_DIR=$(FPTOOLS_TOP_ABS)/$(CURRENT_DIR)
 ifneq "$(TARGETPLATFORM)" "i386-unknown-mingw32"
 HSC2HS_EXTRA="--cc=$(CC) --cflag=-D__GLASGOW_HASKELL__=$(ProjectVersionInt) -I$(FPTOOLS_TOP_ABS)/$(INCLUDE_DIR)"
 else
-HSC2HS_EXTRA="--cc=$(CC) --cflag=-mno-cygwin --cflag=-D__GLASGOW_HASKELL__=$(ProjectVersionInt) -I$(FPTOOLS_TOP_ABS)/$(INCLUDE_DIR)"
+HSC2HS_EXTRA="--cc=$(CC) --cflag=-mno-cygwin --cflag=-mwin32 --cflag=-D__GLASGOW_HASKELL__=$(ProjectVersionInt) -I$(FPTOOLS_TOP_ABS)/$(INCLUDE_DIR)"
 endif
 endif