[MLton-devel] Re: [MLton-user] Installation of MLton under Cygwin

Stephen Weeks MLton@mlton.org
Thu, 25 Apr 2002 10:40:16 -0700


> After a lot of system administration, including reinstallation of Cygwin
> and MLton, I have new data, including a normal path, with Cygwin
> installed in the Win 2K root directory:
> >% /usr/local/lib/mlton/mlton-compile @MLton load-world 
> >/usr/local/lib/mlton/world.mlton --
> >This will tell us if the basis library is being loaded OK. The
> >expected output is "mlton: incorrect args from shell script".  But, in
> >your case, this will probably fail.  If you are able to get an strace,
> >that would be helpful.
> 
> I have no name! /usr/local/lib/mlton

I think that this error is unrelated to MLton and indicates a
problem with your Cygwin setup.  There are lots of messages on the
Cygwin mailing list about the "I have no name" problem.  Here are a
couple.

	http://www.cygwin.com/ml/cygwin/2001-04/msg01587.html
	http://www.cygwin.com/ml/cygwin/2000-12/msg01236.html

> $ mount
> D:\\bin on /usr/bin type user (textmode)
> D:\\lib on /usr/lib type user (textmode)
> D: on / type user (textmode)
> c: on /cygdrive/c type user (textmode,noumount)
> e: on /cygdrive/e type user (textmode,noumount)
> f: on /cygdrive/f type user (textmode,noumount)
> g: on /cygdrive/g type user (textmode,noumount)
> h: on /cygdrive/h type user (textmode,noumount)

Aha.  I believe that this explains the sread problem.  MLton was
opening a binary file (world.mlton) in the default mode, which on my
machine happens to be binary (binmode) and on yours happens to be text
textmode.  I have patched MLton to always use binary mode and the fix
will go out in the next release.  In the meantime you can add binmode
to your CYGWIN environment variable with the following line in your
cygwin.bat file.

set CYGWIN=binmode

Hopefully with the combination of this fix, and your fixing the "I
have no name" problem based on the above links, MLton will run
successfully.  Let us know how it turns out.

_______________________________________________
MLton-devel mailing list
MLton-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlton-devel