[plt-scheme] Standalone MysterX application

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Thu Feb 15 21:23:07 EST 2007

At Thu, 15 Feb 2007 14:22:55 +0000 (GMT), Sverrir Valgeirsson wrote:
> I'm trying to make a very simple MysterX application work as a standalone 
> program using DrScheme v360.
> My program works nicely when running from within DrScheme, but when running 
> standalone it exits with error:
> "mxmain.ss: you seem to be missing mxmain.dll; you need to build MysterX in 
> plt\src\mysterx\"
> I have tryed to copy the mxmain.dll file into the directory where the 
> application is started from, to WINNT/system32 and to plt/src/mysterx 
> (relative from where the .exe file resides). None of these have had any 
> effect. 
> Any suggestions on how to get the application to find the .dll? 

It's going wrong much earlier. The stand-alone executable includes a
dummy version of the `mxmain' module, so it's not even looking for
"mxmain.dll" at run time.

The dummy module is


Enclosed is a replacement that can work around the problem, but you
have to follow these steps (and the last one is particularly weird):

 * Replace "mxmain.ss" with the enclosed version.

 * Run 
    "Setup PLT" -lc mysterx
   to clear out .zo and .dep references to "mxmain.dll"

 * Run
    "Setup PLT" -l mysterx
   to build using the new "mxmain.ss"

 * Copy 
   and put it next to the (so-called) standalone executable.

 * Edit the copy of "mxmain.dll". Search for the string "dLl
   dIRECTORy:" --- but it's in UTF-16, so there will be NUL byte in
   between each ASCII letter. After that string, there will be a ".";
   change it to "<". (This step prevents "mxmain.dll" from trying to
   find "libmzsch.dll" relative to itself.)

If you create a distribution archive, then you'll need to copy the
(edited) "mxmain.dll" into the "lib" subdirectory for the archive.

Obviously, we'll try to get this straightened out for the next release.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: mxmain.ss
URL: <http://lists.racket-lang.org/users/archive/attachments/20070216/ffde1310/attachment.ksh>

Posted on the users mailing list.