[project @ 2001-04-03 12:58:54 by rrt]
authorrrt <unknown>
Tue, 3 Apr 2001 12:58:54 +0000 (12:58 +0000)
committerrrt <unknown>
Tue, 3 Apr 2001 12:58:54 +0000 (12:58 +0000)
Make ghc-inplace work on Windows by adding FPTOOLS_TOP_ABS_UNIX to be always
the UNIX-style version of the path (for the Cygwin tools), and make CC_OPTS
be set even if there is no C_PROG, so that -mno-cygwin and -mwin32 are
always passed on Windows (and must be filtered out where not needed, e.g. in
lndir.c).

mk/config.mk.in
mk/target.mk

index 3bffb6a..84034a7 100644 (file)
@@ -402,6 +402,7 @@ endif
 # FPTOOLS_TOP: the top of the fptools hierarchy, absolute path.
 
 FPTOOLS_TOP_ABS                = @hardtop@
+FPTOOLS_TOP_ABS_UNIX    = @hardtop@
 ifeq "$(TARGETPLATFORM)" "i386-unknown-cygwin32"
 FPTOOLS_TOP_ABS                = $(subst \,/,$(shell cygpath -w @hardtop@))
 endif
index 6970096..e3d6c80 100644 (file)
@@ -311,13 +311,13 @@ endif
 #----------------------------------------
 #      C programs
 
-ifneq "$(C_PROG)" ""
-all :: $(C_PROG)
-
 ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32"
-CC_OPTS += -mno-cygwin
+CC_OPTS += -mno-cygwin -mwin32
 endif
 
+ifneq "$(C_PROG)" ""
+all :: $(C_PROG)
+
 $(C_PROG) :: $(C_OBJS)
        $(CC) -o $@ $(CC_OPTS) $(LD_OPTS) $(C_OBJS) $(LIBS)
 endif