[Haskell-cafe] GLUT under Windows using ghc 7.8.2?

Dominick Samperi djsamperi at gmail.com
Thu Jul 3 00:29:07 UTC 2014


Answer: The Haskell Platform ships with a 32bit version of ghc, and this
explains why glut32 is used. I tried to use 64bit ghc-7.8.2 with the
same glut library, and got the message "Missing C library glut32".
There is no problem using 32bit ghc-7.8.2 (with the --extra-lib-dirs
option). The error message is misleading though...



On Wed, Jul 2, 2014 at 7:31 PM, Dominick Samperi <djsamperi at gmail.com> wrote:
> It appears that The Haskell Platform includes libglut32.a and other
> important libs, so it is self-contained, provided users can work with
> the version of ghc that is provided: currently 7.6.3 under Windows.
>
> In particular, 'cabal install glut' works fine with the default version
> of ghc. But if I try using ghc-7.8.2 I get:
> Configuring GLUT-2.5.1.1...
> cabal: Missing dependencies on a foreign library:
> * Missing C library: glut32
> ...
>
> All of the following do not change the result:
> 1. Adding --extra-lib-dirs=c:\glut-3.7.6-bin to the command line.
> 2. Using freeglut instead of glut
> 3. Copying libglut.a from The Haskell Package mingw/lib directory to
>     c:\ghc-3.8.2\mingw\lib (dangerous because I am mixing
>     architectures here).
>
> How does cabal decide that the C library glut32 is missing? Where
> is it looking? Why doesn't it look in the places I specify?
>
> Thanks,
> Dominick


More information about the Haskell-Cafe mailing list