[MLton-user] SVN r6941 MLton/MinGW32 and FFI

Dan DuVarney duvarney at reactive-systems.com
Mon Nov 10 16:43:50 PST 2008


Greetings:

Has anyone else had problems with using the C FFI with SVN r6941 MLton
under MinGW32? I have been unsuccessful in getting any program
containing FFI calls to work. It looks as if a step which generates
a dll wrapper is being skipped.

For example, in /doc/examples/ffi I am observing the following behavior:

bash-3.1$ make test_quot
mlton -default-ann 'allowFFI true' test_quot.sml c_quot.o
C:\DOCUME~1\Dan\LOCALS~1\Temp\fileT2zfil.o:fake:(.text+0x2fbe):
undefined reference to `__imp__c_quot'
C:\DOCUME~1\Dan\LOCALS~1\Temp\fileT2zfil.o:fake:(.text+0x35f0):
undefined reference to `__imp__call_sml_quot'
collect2: ld returned 1 exit status
call to system failed with signal 1:
gcc -o test_quot C:\DOCUME~1\Dan\LOCALS~1\Temp\filekfJCQj.o
C:\DOCUME~1\Dan\LOCALS~1\Temp\fileT2zfil.o c_quot.o -Lc:\program
files\mlton\lib\mlton\self -lmlton -lgdtoa -lm -lgmp -lws2_32 -lkernel32
-lpsapi -lnetapi32 -lwinmm -Wl,--enable-stdcall-fixup


-- 
Dan DuVarney
Senior Software Engineer         Reactive Systems Inc.
duvarney at reactive-systems.com    +1 (919) 324-3507 ext. 103
OpenPGP (GnuPG) public key file:
http://www.reactive-systems.com/~duvarney/pgp_public_key.txt




More information about the MLton-user mailing list