[MLton-devel] NetBSD porting and problems
Matthew Fluet
fluet@cs.cornell.edu
Tue, 5 Aug 2003 11:07:20 -0400 (EDT)
> Furthermore, we cannot bootstrap MLton without MLton itself. We need
> mllex and mlyacc in the MLton version. That can be handled by the pretty
> Linux-emulation NetBSD has, so we run the linux version of MLton through
> the emulation layer (on a suse-linux base-system in fact), and we hope
> this does not break anything again
I'm not sure that is a valid assumption; Stephen has a lot more experience
porting.
> We also need to teach the SML part of MLton about a new citizen:
In addition to the /lib/mlton-stubs files, you will also need to modify
/basis-library/misc/primitive.sml and /basis-library/mlton/platform.sig.
In one sense, this is the source of the error message you were seeing.
You'll notice that /mlton/control/control.{sig,sml} make reference to
MLton.Platform.os. So, things work out in the SML/NJ world, because
you've modified the /lib/mlton-stubs files. However, when running version
of MLton that was passed through the emulation layer, it's basis-library
implementation doesn't have NetBSD in the MLton.Platform.os datatype.
Hence, in any code like:
> @@ -95,6 +95,7 @@
> case !Control.hostOS of
> Control.Cygwin => true
> | Control.FreeBSD => false
> + | Control.NetBSD => false
> | Control.Linux => false
> | _ => Error.bug "x86 can't handle hostType"
Control.NetBSD is not constructor in the Control structure; hence, the
"longid in var pat" error.
-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
_______________________________________________
MLton-devel mailing list
MLton-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlton-devel