cvs
commit:fptools/ghc/rtsRtsStartup.cfptools/libraries/base/include
HsBase.h fptools/libraries/base/System/Posix Internals.hs
Sven Panne
Sven.Panne at informatik.uni-muenchen.de
Thu Sep 25 15:30:32 EDT 2003
I wrote:
> Just a note: This commit breaks Hugs. Probabaly nothing really serious
> (provide a saved_termios), but I currently don't have the time to fix it.
Now I've tried to fix this, but I ran into trouble: When I define an
externally visible variable saved_termios in Hugs' machdep.c like
RtsStartup.c does, the dlopen used in Hugs is unhappy with
System/Posix/Internals.so (which contains a reference to saved_termios):
undefined symbol: saved_termios
When I change Internals.hs to use a getter/setter like
foreign import ccall unsafe "HsBase.h __hscore_get_saved_termios"
get_saved_termios :: Int -> IO (Ptr CTermios)
foreign import ccall unsafe "HsBase.h __hscore_set_saved_termios"
set_saved_termios :: Int -> (Ptr CTermios) -> IO ()
instead and define these as externally visible functions in Hugs,
everything is fine!? Strange... Can somebody explain this?
Cheers,
S.
More information about the Cvs-libraries
mailing list