Re: [racket-dev] mzscheme executable broken when using --enable-shared
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 > On Fri, Apr 15, 2011 at 10:51, Marijn wrote: >> -BEGIN PGP SIGNED MESSAGE- >> Hash: SHA1 >> >> On 04/13/11 14:15, Marijn wrote: >>> Hi, >>> >>> racket currently still installs a mzscheme executable that (on my >>> system) does this: >>> >>> $ mzscheme >>> read failed to read all 31 bytes from file /usr/bin/mzscheme >>> Aborted >>> >>> Marijn >> >> Does anyone know what this broken file is about or am I the only one >> seeing this? On 04/15/11 11:05, Pierpaolo Bernardi wrote: > See: > http://docs.racket-lang.org/scheme/compat-exe.html?q=mzscheme#(idx._(gentag._0._(lib._scribblings/scheme/scheme..scrbl))) > > Or search "mzscheme" in the Help Desk. In windows, it works as advertised. > > Cheers > P. Okay, I see there that it is supposed to be equivalent to "racket -I scheme/init", but that command works fine. On 04/15/11 11:08, Eli Barzilay wrote: > Random guess -- maybe it's a result of using shared libraries? (Our > linux builds are not using that configuration.) Yes, I am building with --enable-shared. Both mzscheme and mred are broken with the same error, drscheme works fine. Marijn -BEGIN PGP SIGNATURE- Version: GnuPG v2.0.17 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk2oD9AACgkQp/VmCx0OL2z8KQCguXZd4LyPlG8DwTLEgq2sHuDX tkEAoIFpOFIrrSpE8+moBkShQW92rQso =jiZR -END PGP SIGNATURE- _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
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 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 At Fri, 15 Apr 2011 11:28:51 +0200, Marijn wrote: > > On Fri, Apr 15, 2011 at 10:51, Marijn wrote: > >> On 04/13/11 14:15, Marijn wrote: > >>> Hi, > >>> > >>> racket currently still installs a mzscheme executable that (on my > >>> system) does this: > >>> > >>> $ mzscheme > >>> read failed to read all 31 bytes from file /usr/bin/mzscheme > >>> Aborted > >>> > >>> Marijn > >> > >> Does anyone know what this broken file is about or am I the only one > >> seeing this? > > On 04/15/11 11:05, Pierpaolo Bernardi wrote: > > See: > http://docs.racket-lang.org/scheme/compat-exe.html?q=mzscheme#(idx._(gentag._0._ > (lib._scribblings/scheme/scheme..scrbl))) > > > > Or search "mzscheme" in the Help Desk. In windows, it works as advertised. > > > > Cheers > > P. > > Okay, I see there that it is supposed to be equivalent to "racket -I > scheme/init", but that command works fine. > > On 04/15/11 11:08, Eli Barzilay wrote: > > Random guess -- maybe it's a result of using shared libraries? (Our > > linux builds are not using that configuration.) > > Yes, I am building with --enable-shared. Both mzscheme and mred are > broken with the same error, drscheme works fine. > > Marijn _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
-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- _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
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- _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
Ah, that would explain it (Marijn is packaging racket for gentoo, as part of the gentoo-lisp group). Binaries are stripped by default pre-installation by the emerge packager. -- Regards, Imran Rafique On 18 April 2011 00:39, Matthew Flatt wrote: > 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- > > _ > For list-related administrative tasks: > http://lists.racket-lang.org/listinfo/dev _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi Matthew, On 04/18/11 04:00, Imran Rafique wrote: > Ah, that would explain it (Marijn is packaging racket for gentoo, as > part of the gentoo-lisp group). Binaries are stripped by default > pre-installation by the emerge packager. Imran is correct. > On 18 April 2011 00:39, Matthew Flatt wrote: >> 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. I tried to test your changes, but ran into an (unrelated I think) compile failure: x86_64-pc-linux-gnu-gcc -I./.. -I./../include - -I/usr/lib64/libffi-3.0.10rc8/include -DMZ_DONT_USE_JIT - -DMZ_USES_SHARED_LIB -c ./module.c -fPIC -DPIC -o .libs/module.o /var/tmp/portage/dev-scheme/racket-999/work/racket-999/src/lt/libtool - --mode=compile --tag=CC x86_64-pc-linux-gnu-gcc -I./.. -I./../include -I/usr/lib64/libffi-3.0.10rc8/include -DMZ_DONT_USE_JIT - -DMZ_USES_SHARED_LIB -c ./mzrt.c -o mzrt.lo ./module.c: In function 'do_module_execute': ./module.c:5278: error: 'scheme_module_code_cache' undeclared (first use in this function) ./module.c:5278: error: (Each undeclared identifier is reported only once ./module.c:5278: error: for each function it appears in.) make[6]: *** [module.lo] Error 1 Marijn -BEGIN PGP SIGNATURE- Version: GnuPG v2.0.17 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk2r8i0ACgkQp/VmCx0OL2w6pwCgyPsC25mIOgur+YpA/nMpLPPX QIYAn3LHhcfdf6Xdv29z7qVDefv8SPVf =dsGD -END PGP SIGNATURE- _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
At Mon, 18 Apr 2011 10:11:25 +0200, Marijn wrote: > I tried to test your changes, but ran into an (unrelated I think) > compile failure: Fix pushed. (Previous changes broke the non-futures, non-places build.) _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev
Re: [racket-dev] mzscheme executable broken when using --enable-shared
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 04/18/11 14:35, Matthew Flatt wrote: > At Mon, 18 Apr 2011 10:11:25 +0200, Marijn wrote: >> I tried to test your changes, but ran into an (unrelated I think) >> compile failure: > > Fix pushed. (Previous changes broke the non-futures, non-places build.) > Thanks Matthew, mzscheme and mred are now both working. Marijn -BEGIN PGP SIGNATURE- Version: GnuPG v2.0.17 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk2tQG8ACgkQp/VmCx0OL2w8OACgiEh9XWcJoRkP3xnrRvZAsGA3 LfAAn1hyrgyKRUxRUiL1nFo1sc13YjWQ =L6mi -END PGP SIGNATURE- _ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev