On Sunday, June 1, 2003, at 07:36 PM, Wolfgang Thaller wrote:


Dear Wolfgang,

I maintain the Hugs port for the darwinports system (a cousin of fink and
perhaps the successor to the *bsd ports system). I'd like to add a port
for ghc-6.0. I tried to build it but ran into some problems.


1. configure doesn't pass the CPPFLAGS and LDFLAGS environment variables
to the haskell build. This means you can't have libreadline and libdl in
non-standard locations.

Grmpf... I know I don't like configure scripts. I prefer IDEs. Do you know how to fix it/have time to do it?
If not, would somebody else _PLEASE_ do that for us? (It wouldn't enjoy digging into the build system code to fix that; in fact, I would positively hate it).



I will take a look at the configuration issue for ghc-6.0 + Mac OS X. I was
able to hand edit the makefiles to pass the correct include and library paths;
it's not too big a job to pass the appropriate configuration variables.



This is a problem for darwinports and fink because of their automatic dependency
management.

2. Even if I put symlinks to the above libraries in the standard locations,
I still get a build failure. This is building 6.0 using 5.04.3. (5.04.3 was
built from source successfully using your 5.04.2 binary.) The build ends with
[...]

Ahem, yes. I didn't have a chance to test GHC 6 in the last five days before the release, and, of course, the last commit broke the Mac OS X build. I have meanwhile committed a fix to CVS, but that was a day after the official relase for 6.0. If you check out the newest stable branch from CVS (or ask me to send you diffs tomorrow), it should > work.
(That last commit made GHC quote all arguments it passes on to GHC; for Mac OS X, it passed "-framework HaskellSupport" instead of "-framework" "HaskellSupport". GCC doesn't report an error but it just ignores the former. Strange.)



I'll check it out from the CVS in the morning.



The "HaskellSupport" framework (which is not used if it's not detected at configure time; there should really be a configure switch for that) is just an aggregation of libgmp and libdl packaged as a framework. I figured that would be easier for end users of Haskell programs, as libgmp is required for all Haskell programs, and libdl is used by the Posix library (and how do you install a dylib using the Finder?). For something like darwinports, it might be better to just rely on the gmp and dl libraries installed with darwinports, but that makes programs compiled using ghc dependent on darwinports, too.


For darwinports, I'll probably just install gmp and dl as dependencies. There is
also provision to install frameworks in $prefix/Frameworks. I'll have to think about
which is more appropriate.


And you just reminded me that I still haven't uploaded the 10 line shell script for creating the HaskellSupport.framework anywhere, because I could never figure out the appropriate place in CVS:

#!/bin/sh
cd dlcompat-20020413
cp dlfcn.o ../
make
cd ../gmp-4.0.1
./configure
make
ld -r -d ./libs/libgmp.a -o ../libgmp.o
cd ..
ld -dylib -o HaskellSupport.framework/Versions/A/HaskellSupport libgmp.o dlfcn.o /usr/lib/dylib1.o -lSystem



OK, that's all for now...


Cheers,

Wolfgang



Thanks for the help!


Best Wishes,
Greg

_______________________________________________
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to