Ticket #4843 (closed bug: worksforme)

Opened 2 years ago

Last modified 2 years ago

"include" directory missing in the ghc 7.0.1 windows installer

Reported by: nsch Owned by:
Priority: highest Milestone: 7.0.2
Component: Package system Version: 7.0.1
Keywords: Cc:
Operating System: Windows Architecture: Unknown/Multiple
Type of failure: Compile-time crash Difficulty:
Test Case: Blocked By:
Blocking: Related Tickets:

Description

The current windows installer from http://www.haskell.org/ghc/download_ghc_7_0_1#windows is missing the "include" directory in its root directory.

For example this build fails because it cannot find HsFFI.h, which is located in C:\Haskell\ghc-7.0.1\lib\include and not in C:\\Haskell\\ghc-7.0.1/include, where GHC is looking for it:

configure: creating ./config.status
config.status: creating include/HsDirectoryConfig.h
config.status: include/HsDirectoryConfig.h is unchanged
("C:\\Haskell\\ghc-7.0.1\\mingw\\bin\\gcc.exe",["C:\\Users\\Nils\\AppData\\Local\\Temp\\3048.c","-o","C:\\Users\\Nils\\AppData\\Local\\Temp\
\3048","-D__GLASGOW_HASKELL__=700","-Iinclude","-I.","-IC:\\Haskell\\ghc-7.0.1\\old-time-1.0.0.6\\include","-IC:\\Haskell\\ghc-7.0.1\\Win32-
2.2.0.1\\include","-IC:\\Haskell\\ghc-7.0.1\\bytestring-0.9.1.8\\include","-IC:\\Haskell\\ghc-7.0.1\\base-4.3.0.0\\include","-IC:\\Haskell\\
ghc-7.0.1/include","-IC:\\Haskell\\ghc-7.0.1/include","-LC:\\Haskell\\ghc-7.0.1\\old-time-1.0.0.6","-LC:\\Haskell\\ghc-7.0.1\\old-locale-1.0
.0.2","-LC:\\Haskell\\ghc-7.0.1\\filepath-1.2.0.0","-LC:\\Haskell\\ghc-7.0.1\\Win32-2.2.0.1","-LC:\\Haskell\\ghc-7.0.1\\bytestring-0.9.1.8",
"-LC:\\Haskell\\ghc-7.0.1\\base-4.3.0.0","-LC:\\Haskell\\ghc-7.0.1\\integer-gmp-0.2.0.2","-LC:\\Haskell\\ghc-7.0.1\\ghc-prim-0.2.0.0","-LC:\
\Haskell\\ghc-7.0.1","-LC:\\Haskell\\ghc-7.0.1"])
C:\Haskell\ghc-7.0.1\mingw\bin\gcc.exe returned ExitFailure 1 with error
message:
In file included from C:\Users\Nils\AppData\Local\Temp\3048.c:1:0:
include/HsDirectory.h:19:19: fatal error: HsFFI.h: No such file or directory
compilation terminated.

You have to pass --extra-include-dirs=C:/Haskell/ghc-7.0.1/lib/include to get it to compile.

Change History

Changed 2 years ago by simonmar

  • priority changed from normal to highest
  • milestone set to 7.0.2

Thanks, we'll take a look.

Changed 2 years ago by igloo

  • status changed from new to closed
  • resolution set to worksforme

I can't reproduce this.

ghc --make -v q.hs -fforce-recomp -XCPP

says:

[...]
C:\ghc\ghc-7.0.1\lib\..\mingw\bin\gcc -E -undef -traditional -v -I C:\ghc\ghc-7.0.1\lib\base-4.3.0.0\include -I C:\ghc\ghc-7.0.1\lib/include -D__GLASGOW_HASKELL__=700 -Dmingw32_BUILD_OS=1 -Di386_BUILD_ARCH=1 -Dmingw32_HOST_OS=1 -Di386_HOST_ARCH=1 -x c q.hs -o C:\cygwin\tmp\ghc2960_0\ghc2960_0.hscpp

which looks fine to me.

Compiling and running the directory package's Setup.hs also looks fine:

[...]
("C:\\ghc\\ghc-7.0.1\\mingw\\bin\\gcc.exe",["C:\\cygwin\\tmp\\2888.c","-o","C:\\cygwin\\tmp\\2888","-E","-D__GLASGOW_HASKELL__=700","-Idist\\build\\autogen","-Iinclude","-I.","-IC:\\ghc\\ghc-7.0.1\\lib\\old-time-1.0.0.6\\include","-IC:\\ghc\\ghc-7.0.1\\lib\\Win32-2.2.0.1\\include","-IC:\\ghc\\ghc-7.0.1\\lib\\bytestring-0.9.1.8\\include","-IC:\\ghc\\ghc-7.0.1\\lib\\base-4.3.0.0\\include","-IC:\\ghc\\ghc-7.0.1\\lib/include","-IC:\\ghc\\ghc-7.0.1\\lib/include"])
[...]
Note: See TracTickets for help on using tickets.