[MLton-commit] r6984
    Wesley Terpstra 
    wesley at mlton.org
       
    Tue Nov 11 12:55:55 PST 2008
    
    
  
As the ffi examples should demonstrate best practice, compile C files with
gcc. Compiling C files with MLton provides access to headers that should not
be available to user C code. Also, with gcc one gets compiler warnings as
opposed to MLton which disables them all.
----------------------------------------------------------------------
U   mlton/trunk/doc/examples/ffi/Makefile
----------------------------------------------------------------------
Modified: mlton/trunk/doc/examples/ffi/Makefile
===================================================================
--- mlton/trunk/doc/examples/ffi/Makefile	2008-11-11 20:43:14 UTC (rev 6983)
+++ mlton/trunk/doc/examples/ffi/Makefile	2008-11-11 20:55:54 UTC (rev 6984)
@@ -34,7 +34,7 @@
 		iimport.sml
 
 %.o:	%.c
-	$(mlton) -stop o $<
+	gcc -Wall -c -o $@ $<
 %.h:	%.sml
 	$(mlton) -export-header $@ -stop tc $<
 %:
    
    
More information about the MLton-commit
mailing list