scheme / scsh

A Unix shell embedded in scheme
Other
386 stars 36 forks source link

Build fails #37

Closed noelhunt closed 7 years ago

noelhunt commented 7 years ago

There are scheme48 routines referenced in several of the files in './c' and they are not resolved:

/home/noel/bin/scheme48 -h 0 -a batch <<EOF ,translate =scshexternal/ /home/noel/src6/scsh/c/ ,config ,load ./scheme/scsh-read.scm ,config ,open scsh-reader ,config ,set-reader scsh-read ,config ,load ./rx/interfaces.scm ./rx/packages.scm ./scheme/scsh-interfaces.scm ./scheme/scsh-package.scm ./scheme/lib/ccp-pack.scm ./scheme/lib/char-package.scm ,user-package-is scsh-user ,user ,open scsh-reader ,set-reader scsh-read (dump-scsh "scsh.image") EOF

error: /home/noel/src6/scsh/c/tty-control-chars-info.so: undefined symbol: s48_enter_fixnum [shared_object_dlopen]

{byte-vector 47 104 111 109 101 47 ---}

make: *** [scsh.image] Error 1

roderyc commented 7 years ago

You might not have the correct version of scheme48 installed; can you confirm that it's version 1.9.2 you're using?

noelhunt commented 7 years ago

No, seems to be the right version:

% scheme48 Welcome to Scheme 48 1.9.2 (made by noel on 2017-10-03) See http://s48.org/ for more information. Please report bugs to scheme-48-bugs@s48.org. Get more information at http://www.s48.org/. Type ,? (comma question-mark) for help.

On Wed, Oct 4, 2017 at 2:38 PM, Roderic Morris notifications@github.com wrote:

You might not have the correct version of scheme48 installed; can you confirm that it's version 1.9.2 you're using?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/scheme/scsh/issues/37#issuecomment-334041635, or mute the thread https://github.com/notifications/unsubscribe-auth/Ae9-jJkDAX_k8t3LK-iHUjhO6gN4fVdFks5sov2vgaJpZM4PrfGm .

roderyc commented 7 years ago

I notice that your scheme48 is installed in /home/noel/bin/scheme48. You may need to adjust the prefix used by configure in order for the build to find libraries / includes from scheme48 there. Also, do you have another version of scheme48 installed simultaneously in /usr or /usr/local?

noelhunt commented 7 years ago

Hmm, I thought configure was picking up everything properly; I have just re-run a configure and make and I've attached the script session.

I have been building with the SunPRO compiler from Oracle on Oracles RHEL7, but this time I took the default, gcc.

On Wed, Oct 4, 2017 at 3:06 PM, Roderic Morris notifications@github.com wrote:

I notice that your scheme48 is installed in /home/noel/bin/scheme48. You may need to adjust the prefix used by configure in order for the build to find libraries / includes from scheme48 there. Also, do you have another version of scheme48 installed simultaneously in /usr or /usr/local?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/scheme/scsh/issues/37#issuecomment-334044622, or mute the thread https://github.com/notifications/unsubscribe-auth/Ae9-jJTbJw75InXHaSeOTkutFGEQuJ8jks5sowRYgaJpZM4PrfGm .

noelhunt commented 7 years ago

I recompiled scheme48 with gcc, and scsh builds properly now. There is some magic option which gcc passes to ld which makes the unresolved symbols available somehow. I'll find out what this is so I can rebuild with SunPRO cc.

On Wed, Oct 4, 2017 at 3:06 PM, Roderic Morris notifications@github.com wrote:

I notice that your scheme48 is installed in /home/noel/bin/scheme48. You may need to adjust the prefix used by configure in order for the build to find libraries / includes from scheme48 there. Also, do you have another version of scheme48 installed simultaneously in /usr or /usr/local?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/scheme/scsh/issues/37#issuecomment-334044622, or mute the thread https://github.com/notifications/unsubscribe-auth/Ae9-jJTbJw75InXHaSeOTkutFGEQuJ8jks5sowRYgaJpZM4PrfGm .

noelhunt commented 7 years ago

Also, note a few compiler warnings (gcc won't give them to you):

cc -c -DHAVE_CONFIG_H -DCOMPILING_SCHEME48_ITSELF -DS48_HOST_ARCHITECTURE=\"x86_64-unknown-linux-gnu\" -I ./c -I./c -I./c/net -I./c/bibop -g -mt -o c/scheme48vm-64.o c/scheme48vm-64.c c/scheme48vm-64.c:1445 Warning: Likely uninitialized read (variable v_228X): current_code_vector c/scheme48vm-64.c:5376 Warning: Likely null pointer dereference ((((long )0))): check_stack c/scheme48vm-64.c:5468 Warning: Likely null pointer dereference ((((long )0))): check_stack c/scheme48vm-64.c:5480 Warning: Likely null pointer dereference ((((long )0))): check_stack

On Wed, Oct 4, 2017 at 3:06 PM, Roderic Morris notifications@github.com wrote:

I notice that your scheme48 is installed in /home/noel/bin/scheme48. You may need to adjust the prefix used by configure in order for the build to find libraries / includes from scheme48 there. Also, do you have another version of scheme48 installed simultaneously in /usr or /usr/local?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/scheme/scsh/issues/37#issuecomment-334044622, or mute the thread https://github.com/notifications/unsubscribe-auth/Ae9-jJTbJw75InXHaSeOTkutFGEQuJ8jks5sowRYgaJpZM4PrfGm .

noelhunt commented 7 years ago

When using the SunPRO compiler, scheme48vm needs to be linked with '-Wl,--export-dynamic' (LDFLAGS_VM in Makefile). This would seem to have the same function as '-rdynamic' when using gcc. After this, scsh builds fine.

On Thu, Oct 5, 2017 at 8:34 AM, Noel Hunt noel.hunt@gmail.com wrote:

Also, note a few compiler warnings (gcc won't give them to you):

cc -c -DHAVE_CONFIG_H -DCOMPILING_SCHEME48_ITSELF -DS48_HOST_ARCHITECTURE=\"x86_64-unknown-linux-gnu\" -I ./c -I./c -I./c/net -I./c/bibop -g -mt -o c/scheme48vm-64.o c/scheme48vm-64.c c/scheme48vm-64.c:1445 Warning: Likely uninitialized read (variable v_228X): current_code_vector c/scheme48vm-64.c:5376 Warning: Likely null pointer dereference ((((long )0))): check_stack c/scheme48vm-64.c:5468 Warning: Likely null pointer dereference ((((long )0))): check_stack c/scheme48vm-64.c:5480 Warning: Likely null pointer dereference ((((long )0))): check_stack

On Wed, Oct 4, 2017 at 3:06 PM, Roderic Morris notifications@github.com wrote:

I notice that your scheme48 is installed in /home/noel/bin/scheme48. You may need to adjust the prefix used by configure in order for the build to find libraries / includes from scheme48 there. Also, do you have another version of scheme48 installed simultaneously in /usr or /usr/local?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/scheme/scsh/issues/37#issuecomment-334044622, or mute the thread https://github.com/notifications/unsubscribe-auth/Ae9-jJTbJw75InXHaSeOTkutFGEQuJ8jks5sowRYgaJpZM4PrfGm .

roderyc commented 7 years ago

I'm closing this since you've found your issue and that compiler is not a platform we're looking to maintain for.