some general feedback re GHC and HOpenGL and apologies for the email i sent as ible_snover

hi andre,
i just noticed you did a make distclean which of course
already wipes the config.cache, so the suggestion i sent in
as ible_snover was a duddo. oops. sorry
i just had another idea... but doh! no, i just thought for a second
that you may have needed to remove some files in your
ghc directory, but no, config.status, config.log and ghc.spec
in your ghc build directory are probably removed by make distclean
and even if they arent, i just checked and they are certainly updated
anyway when you re-run configure. So i have no idea, sorry. The
problem you are having sounds really, really really weird. Good luck
with the newer cygwin.
So since i dont have any other suggestions re your problem
ill just give you ppl some feedback on how i found the
whole ghc/HOpenGl make and install process, before i
forget the minor problems which i did have.
1) the ghc 5.02.3 source distribution didnt come with happy,
so i went and got it via CVS, and that fixed that.
2) the HOpenGL distributed with the ghc 5.02.3 source would
not compile. After compiling and installing the ghc 5.02.3 compiler
(with the 4.08 compiler booted up from .hc files), i re-ran configure
to use the ghc 5.02.3 compiler and also added the --enable-opengl
and --with-glut-api=4 switches and tried to get HOpenGL
compiled. But it failed, spitting the dummy as follows:
---------------------
==fptools== make all -wr;
in /home/jss/stuff/src/haskell/ghc/builds/build5.02.3/hslibs/OpenGL
------------------------------------------------------------------------
rm -f GL/GL_Constants.o; if [ ! -d GL/GL_Constants ]; then mkdir
GL/GL_Constants; else /usr/bin/find GL/GL_Constants -name '*.o' | xargs rm -f
__rm_food; fi;
/usr/local/bin/ghc -ldl -recomp -fvia-C -Wall -fglasgow-exts '-#include

John Sincock wrote:
[ configure/cygwin trouble ]
Just a rule of thumb: Whenever your system setup changes (new GHC, new Cygwin, ...), you have to issue a "make distclean". But anyway, I don't have a clue what Andre's problem is.
[...] 1) the ghc 5.02.3 source distribution didnt come with happy, so i went and got it via CVS, and that fixed that.
Well, not exactly a HOpenGL problem... :-)
2) the HOpenGL distributed with the ghc 5.02.3 source would not compile.
The fptools/hslibs version of HOpenGL was an intermediate attempt to rewrite it more or less from scratch. But, as usual, GHC, the FFI, and the module hierarchy developed at a faster pace than I did, so I finally switched to the fptools/libraries hierarchy. There is a (small :-} hope that this will be *the* place for future Haskell libraries, so leaving the other versions as they are is the only choice I have with my limited resources. It could be the case that there will be a bug-fix release for 1.02, but the fptools/hslibs stuff is definitely dead and I should probably remove it from CVS. Sorry for the confusion.
3) no luck there, so i just downloaded the HOpenGL 1.2 source tarball, and the latest greencard tarball, compiled greencard and then had another go at compiling HOpenGL. And success ! all the examples compiled successfully too.
Congratulations! :-) The dependency on GreenCard is a big drawback in retrospect, it didn't become *the* way for interfacing with C as I hoped. Nevertheless, GreenCard paved the way for much cooler things like H/Direct and the current FFI. Thanks, Simon, Sigbjorn, and Thomas!
4) the only other thing that bothered me a bit was when i went to test the whole thing by compiling BezMesh.hs [...] I still dont know why the -package HOpenGL is necessary, but hey, its no big deal, i will probably work that out soon enough...
Have a look at: http://haskell.org/ghc/docs/latest/set/packages.html In a nutshell: A single "-package foo" can save you a plethora of GHC options, a simple but rather efficient and comfortable way to, well, 'package' them up... :-)
All in all the install on linux went relatively painlessly, considering what a huge and fearsome Beast the GHC is, and even HOpenGL aint exactly small either.
Things have definitely improved in the last 1-2 years: GHC finds its way to more and more platforms, and the "new" HOpenGL, using only the standard FFI, should be even less painful to install (or even *comes* with GHC, NHC98, Hugs, ... <= Hint ;-)
[...] ill shutup now
No need to, feedback is always welcome! Cheers, S.
participants (2)
-
John Sincock
-
Sven Panne