On Wed, Nov 19, 2008 at 01:18:39PM +0000, Simon Marlow wrote:
> >My only idea how to fix this it to add -pthread to cc-options and
> >ld-options of unix.buildinfo if SplitObjs=NO, but this sounds like
> >a crude hack to me.
> >
> >If anyone has a better solution, please let me know.
>
> SplitObjs is a red herring: it only hides the real problem, which is that
> the unix package depends on the pthread library on OpenBSD, and doesn't
> express this dependency in its .cabal file. The fix is surely to add
> -lpthread to extra-libraries in unix.cabal. Right?
Yeah, or better add -pthread to ld-options and cc-options, at least
in theory; on OpenBSD, -pthread affects both the preprocessor (at
compile time) as well as the linker. On the other hand, the Semaphore
stuff are more or less wrappers, to -lpthread may do as well.
I'll make a diff, and if it works (i.e. no regressions), I'll send
it here in a few days (my machine is too slow, and i'm short of
time).
However, what about Linux? Doesn't it show the same problem? IIRC,
sem_wait(3) and friends are in libpthread on Linux, too.
Ciao,
Kili
_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc