#-----------------------------------------------------------------------------
# Counting source code lines
#-----------------------------------------------------------------------------
# Counting source code lines
@echo "cBooterVersion = \"$(GhcVersion)\"" >> $(CONFIG_HS)
@echo "cStage = STAGE" >> $(CONFIG_HS)
@echo "cHscIfaceFileVersion = \"$(HscIfaceFileVersion)\"" >> $(CONFIG_HS)
@echo "cBooterVersion = \"$(GhcVersion)\"" >> $(CONFIG_HS)
@echo "cStage = STAGE" >> $(CONFIG_HS)
@echo "cHscIfaceFileVersion = \"$(HscIfaceFileVersion)\"" >> $(CONFIG_HS)
@echo "cGhcWithNativeCodeGen = \"$(GhcWithNativeCodeGen)\"" >> $(CONFIG_HS)
@echo "cGhcUnregisterised = \"$(GhcUnregisterised)\"" >> $(CONFIG_HS)
@echo "cGhcEnableTablesNextToCode = \"$(GhcEnableTablesNextToCode)\"" >> $(CONFIG_HS)
@echo "cGhcWithNativeCodeGen = \"$(GhcWithNativeCodeGen)\"" >> $(CONFIG_HS)
@echo "cGhcUnregisterised = \"$(GhcUnregisterised)\"" >> $(CONFIG_HS)
@echo "cGhcEnableTablesNextToCode = \"$(GhcEnableTablesNextToCode)\"" >> $(CONFIG_HS)
# will go wrong when we use it in a Haskell string below.
TOP_ABS=$(subst \\,/,$(FPTOOLS_TOP_ABS_PLATFORM))
# will go wrong when we use it in a Haskell string below.
TOP_ABS=$(subst \\,/,$(FPTOOLS_TOP_ABS_PLATFORM))
-GHC_PATH=$(TOP_ABS)/$(GHC_COMPILER_DIR_REL)/$(GHC_PROG)
+GHC_PATH=$(TOP_ABS)/$(GHC_COMPILER_DIR_REL)/$(GHC_PROG)$(exeext)
+
+ifeq "$(HOSTPLATFORM)" "i386-unknown-mingw32"
+INPLACE_EXTRA_FLAGS = -optc-DWINDOWS
+endif