[racket-dev] mzscheme executable broken when using --enable-shared

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Sun Apr 17 20:39:22 EDT 2011

Was `strip' or a similar tool run on the `mzscheme' executable?

Except for `racket', `gracket', and executables created as shell
scripts, Racket executables are generated by cloning `starter' and
appending extra data to the end of the executable file. Simply
appending data to the end of the file is a hack; it doesn't create a
well-formed ELF binary. Using `strip' or similar tools on the broken
binary tends to just throw away the data, which would lead to an error
like the one you reported.

I've pushed changes that add to `starter' in a proper ELF section. Even
if you didn't run `strip', having a valid ELF binary may fix the
problem you're seeing.


At Fri, 15 Apr 2011 18:32:39 +0200, Marijn wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 04/15/11 18:07, Matthew Flatt wrote:
> > I tried a build with `--enable-shared' and the generated `mzscheme'
> > executable worked for me, so it's not just `--enable-shared' that
> > causes the problem.
> > 
> > If you run the `starter' executable in the Racket "lib" directory, do
> > you get an error like this?
> > 
> >   lib/starter: this is an unconfigured starter
> 
> Yes, I do.
> 
> Marijn
> 
> > The `mzscheme' and `mred' executables are created by cloning and
> > configuring `starter', so something could be going wrong either in the
> > creation of `starter' or in copying and configuring it.
> > 
> > Thanks,
> > Matthew
> > 
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.17 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> 
> iEYEARECAAYFAk2ocycACgkQp/VmCx0OL2zbOgCeLxB1f7HMfISArJEZ83ade4kn
> JHkAnAhd8zyCM6uHbLbX7lU0uggJnitg
> =fc+i
> -----END PGP SIGNATURE-----



Posted on the dev mailing list.