Package: libghc6-glut-dev
Version: 2.0-2
Severity: normal

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Ian,

Someone at #haskell noticed that a simple program using GLUT failed to
compile and spewed the following error: 

 $ ghc -package GLUT tut.hs
 /usr/lib/GLUT-2.0/ghc-6.6/libHSGLUT-2.0.a(Begin__4.o): In function 
`GLUTzm2zi0_GraphicsziUIziGLUTziBegin_mainLoop_info':
 (.text+0x4f): undefined reference to `glutMainLoop'
 /usr/lib/GLUT-2.0/ghc-6.6/libHSGLUT-2.0.a(Initialization__74.o): In function 
`sgTB_info':
 (.text+0x335): undefined reference to `glutInit'
 /usr/lib/GLUT-2.0/ghc-6.6/libHSGLUT-2.0.a(.o::Window(void)): In function 
`GLUTzm2zi0_GraphicsziUIziGLUTziWindow_zdLr6fKzdwccall_info':
 (.text+0x14): undefined reference to `glutCreateWindow'
 collect2: ld returned 1 exit status

When compiled with ghc -package GLUT -lglut tut.hs it works fine. When
the ghc is called with -package GLUT it should imply -lglut. This can
be done by adding glut to the extra-libraries entry in the package
config file used to register GLUT like this:
 ...
 hs-libraries: HSGLUT-2.0
 extra-libraries: glut
 extra-ghci-libraries:
 include-dirs: /usr/lib/GLUT-2.0/ghc-6.6/include
 ....

The example program used on #haskell is:

> import Graphics.Rendering.OpenGL
> import Graphics.UI.GLUT
> 
> main = do
>   (progname, _) <- getArgsAndInitialize
>  createWindow "Hello World"
>  mainLoop

Greetings Arjan

- -- System Information:
Debian Release: 4.0
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable'), (101, 'experimental')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/dash
Kernel: Linux 2.6.18-4-nebula
Locale: LANG=nl_NL.UTF-8, LC_CTYPE=nl_NL.UTF-8 (charmap=UTF-8)

Versions of packages libghc6-glut-dev depends on:
ii  freeglut3-dev                 2.4.0-5    OpenGL Utility Toolkit development
ii  ghc6 [libghc6-base-dev]       6.6-3      GHC - the Glasgow Haskell Compilat
ii  ghc6-prof [libghc6-base-prof] 6.6-3      Profiling libraries for the Glasgo
ii  libghc6-opengl-dev [libghc6-o 2.1-2      Haskell OpenGL binding for GHC

libghc6-glut-dev recommends no packages.

- -- no debconf information

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFFjX4NUALvsZYuOJARAvDgAJsGm9GyxRI6PA0ik6rWlWeTkjG1qwCgjyHk
cm1pmH7HsxaOTuReXqhLM+c=
=W7rd
-----END PGP SIGNATURE-----



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to