You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original bug ID: 4589 Reporter: gerd Status: acknowledged (set by @damiendoligez on 2008-09-23T17:48:15Z) Resolution: open Priority: normal Severity: feature Version: 3.10.2 Category: otherlibs Monitored by:@alainfrisch
Bug description
I'm often writing extensions to the Unix module using the FFI. Currently, this is a bit awkward, because there is no API, and one has to rely on undocumented features. What would be helpful (at minimum):
C functions for accessing and creating file descriptors
C functions for accessing and creating inet_addr
C function to turn an OS error into a Unix.error
This API would hide the differences between Unix and Win32.
For Win32 there is additionally a linking problem. Currently, functions like uerror cannot be called from a custom DLL because these functions aren't exported. Furthermore, there is no import lib for dllunix.dll.
Additional information
For ocamlnet I'm currently working around by
calling undocumented functions like uerror
for Win32, by even including a copy of unixsupport.c
Note that on the current CVS trunk, the semantics of dynamic libraries is similar to the Unix one on Win32: you are able to access symbols defined in dllunix.dll even though there is no import library and symbols are not exported explicitly.
This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc.
Original bug ID: 4589
Reporter: gerd
Status: acknowledged (set by @damiendoligez on 2008-09-23T17:48:15Z)
Resolution: open
Priority: normal
Severity: feature
Version: 3.10.2
Category: otherlibs
Monitored by: @alainfrisch
Bug description
I'm often writing extensions to the Unix module using the FFI. Currently, this is a bit awkward, because there is no API, and one has to rely on undocumented features. What would be helpful (at minimum):
This API would hide the differences between Unix and Win32.
For Win32 there is additionally a linking problem. Currently, functions like uerror cannot be called from a custom DLL because these functions aren't exported. Furthermore, there is no import lib for dllunix.dll.
Additional information
For ocamlnet I'm currently working around by
See here for code: https://godirepo.camlcity.org/svn/lib-ocamlnet2/trunk/code/src/netsys/
The text was updated successfully, but these errors were encountered: