[Haskell-cafe] Unable to build a mingw cross compiler.
Hamish Mackenzie
hamish.k.mackenzie at gmail.com
Sun Oct 5 14:33:30 UTC 2014
Did you find a solution to this?
On 23 Aug 2014, at 10:38, Sven Bartscher <sven.bartscher at weltraumschlangen.de> wrote:
> Greetings,
>
> I'm trying to build GHC to cross compile to windows.
> GCC and friends are in /usr/bin/x86_64-w64-mingw32-*, libraries and
> headers are in /usr/x86_64-w64-mingw32/{include,lib}.
>
> I configured with:
> ./configure --target=x86_64-w64-mingw32 \
> --with-gcc=/usr/bin/x86_64-w64-mingw32-gcc # Needed because
> # otherwise /usr/bin/gcc
> # would be used
>
> Building fails with the following error:
> utils/hsc2hs/dist/build/Main.o: In function `s2nI_info':
> (.text+0x5c5): undefined reference to `GetModuleFileNameW'
> collect2: error: ld returned 1 exit status
>
> (The GHC invocation line is included in the attached file)
>
> So it seems that GHC either uses the wrong linker or invokes it with
> the wrong search path.
> However, the configure script detects the right linker
> (/usr/bin/x86_64-w64-mingw32).
>
> Is this a bug, or a feature?
>
> System data:
> OS: Debian jessie Linux/GNU i386
> Installed GHC (for bootstrapping): version 7.6.3
> GHC I'm trying to build: version 7.8.3
>
> Regards
> Sven
> <error.txt>_______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
More information about the Haskell-Cafe
mailing list