X-Git-Url: http://git.cielonegro.org/gitweb.cgi?p=pkgsrc-ghc.git;a=blobdiff_plain;f=files%2Fcapi-wrappers-linux-x86_64.c;fp=files%2Fcapi-wrappers-linux-x86_64.c;h=0000000000000000000000000000000000000000;hp=0aef3790a82ca7e3d64ba135b8a4d30e4eb86493;hb=9533b2b09d98a0e7326dc0c58d8d34febe5d3175;hpb=96e61103d139f67648ba7729b614e2cedcbb1ad4 diff --git a/files/capi-wrappers-linux-x86_64.c b/files/capi-wrappers-linux-x86_64.c deleted file mode 100644 index 0aef379..0000000 --- a/files/capi-wrappers-linux-x86_64.c +++ /dev/null @@ -1,53 +0,0 @@ -#include "HsFFI.h" -#include -#include -#include -#include -#include -#include - -/* A quick and dirty hack to resurrect -fvia-C from bitrot. - * - * The newest CapiFFI extension doesn't play nice with -fvia-C, - * generating function wrappers without saving them into the .hc - * files. - */ - -int ghc_wrapper_d2kC_fcntl(int fd, int cmd); -int ghc_wrapper_d2kq_fcntl(int filedes, int cmd, long arg); -int ghc_wrapper_d2kb_fcntl(int filedes, int cmd, struct flock* arg); -int ghc_wrapper_d1lS_gettimeofday(struct timeval* tp, struct timezone* tzp); -int ghc_wrapper_d2ir_utime(const char *path, const struct utimbuf *times); -HsInt32 SystemziConsoleziTerminfoziBase_d2dS(StgStablePtr the_stableptr, HsInt32 a1); - -/* c_fcntl_read */ -int ghc_wrapper_d2kC_fcntl(int fd, int cmd) { - return fcntl(fd, cmd); -} - -/* c_fcntl_write */ -int ghc_wrapper_d2kq_fcntl(int fd, int cmd, long arg) { - return fcntl(fd, cmd, arg); -} - -/* c_fcntl_lock */ -int ghc_wrapper_d2kb_fcntl(int fd, int cmd, struct flock* arg) { - return fcntl(fd, cmd, arg); -} - -int ghc_wrapper_d1lS_gettimeofday(struct timeval* tp, struct timezone* tzp) { - return gettimeofday(tp, tzp); -} - -int ghc_wrapper_d2ir_utime(const char *path, const struct utimbuf *times) { - return utime(path, times); -} - -HsInt32 SystemziConsoleziTerminfoziBase_d2dS(StgStablePtr the_stableptr, HsInt32 a1) { - /* The recipe to create this function is somewhere in - * compiler/deSugar/DsForeign.lhs, but... I don't want to bother - * replicating that here. - */ - assert("DO NOT CALL THIS FUNCTION" == NULL); - return -1; -}