NetBSD does not have support for symbol versioning, so updated systen
authorSimon Marlow <marlowsd@gmail.com>
Thu, 23 Jul 2009 07:57:25 +0000 (07:57 +0000)
committerSimon Marlow <marlowsd@gmail.com>
Thu, 23 Jul 2009 07:57:25 +0000 (07:57 +0000)
commit4eac1ce4a5624e6c21f426a9338d213667b84dde
tree90060d6562a71457546c284bc7b49777a5835e27
parent64adb7f67518eb1f0a07948aeed37b03a0a3a761
NetBSD does not have support for symbol versioning, so updated systen
functions need to be given a new name, and the header files contain
some __asm hackery in order to let the program call the correct function.

This mean that you need to use the header files in order to call the
correct system functions, which prevents things like "foreign import ccall" from working.

Ghc solves this with wrapper functions for some of the renamed functions,
but it has not been updated for newer versions of NetBSD that has recently
versioned some more functions.

The attached patches introduces wrapper functions for all currently
NetBSD-versioned functions used in libraries/unix.  Solves ~20 testsuite
failures.

Contributed by: Krister Walfridsson <krister.walfridsson@gmail.com>
System/Posix/Directory.hsc
System/Posix/Process.hsc
System/Posix/Time.hsc
System/Posix/Unistd.hsc
System/Posix/User.hsc
cbits/HsUnix.c
include/HsUnix.h