00:45 < cow-orker> I'm quite a noob with chicken, can somebody explain what I'm doing wrong? 00:45 < cow-orker> csi -e "(use defstruct)" => ok, no output 00:46 < cow-orker> echo "(use defstruct)" >x.scm; csc x.scm; ./x => Error: (require) cannot load extension: defstruct 00:46 < cow-orker> Version 4.7.0 linux-unix-gnu-x86 [ manyargs dload ptables ] 00:46 -!- seangrove [~user@c-69-181-41-116.hsd1.ca.comcast.net] has joined #chicken 00:51 < mario-goulart> cow-orker: does "chicken-status defstruct" show something? 00:53 < mario-goulart> Hmmm. If you can use it in csi it should be installed. 00:56 < mario-goulart> cow-orker: try "ldd x" and check the path to libchicken.so. Then check if you have defstruct.so under /chicken/6 01:05 < cow-orker> defstruct ....................................................... version: 1.5 01:07 < cow-orker> libchicken.so => /usr/local/lib/libchicken.so (0x0011b000) 01:07 < cow-orker> -rwxr-xr-x 1 root root 49268 2011-06-21 21:09 /usr/local/lib/chicken/6/defstruct.import.so 01:07 < cow-orker> -rw-r--r-- 1 root root 154 2011-06-21 21:09 /usr/local/lib/chicken/6/defstruct.setup-info 01:07 < cow-orker> -rwxr-xr-x 1 root root 7304 2011-06-21 21:09 /usr/local/lib/chicken/6/defstruct.so 01:07 < cow-orker> hmm .... seems to be there? 01:08 < cow-orker> as stated above, it works with csi, but not when compiled with csc 01:09 < mario-goulart> weird 01:09 < mario-goulart> cow-orker: try running "./x -:d" 01:10 < cow-orker> tom@wintermute:~/src/dw$ ./x -:d 01:10 < cow-orker> [debug] application startup... 01:10 < cow-orker> [debug] heap resized to 500000 bytes 01:10 < cow-orker> [debug] stack bottom is 0xbfc4f920. 01:10 < cow-orker> [debug] entering toplevel toplevel... 01:10 < cow-orker> [debug] stack resized to 131072 bytes 01:10 < cow-orker> [debug] entering toplevel library_toplevel... 01:10 < cow-orker> [debug] entering toplevel eval_toplevel... 01:10 < cow-orker> [debug] entering toplevel expand_toplevel... 01:10 < cow-orker> Error: (require) cannot load extension: defstruct 01:10 < cow-orker> Call history: 01:10 < cow-orker> ##sys#require <-- 01:12 < mario-goulart> What about "CHICKEN_REPOSITORY=/usr/local/lib/chicken/6 ./x" ? 01:13 < cow-orker> well well.... that seems to do the trick! 01:13 < cow-orker> but why? 01:13 < mario-goulart> Maybe your installation is broken. 01:13 < mario-goulart> How did you compile chicken? 01:16 < cow-orker> the 4.7 version was compiled with an older version, can't remember exactly (4.4? 4.5? or...) but at the time the eggs were at "5". Still have some old eggs in chicken/5 just don't understand why this happens as both csi and csc is now 4.7 01:17 < cow-orker> and the "chicken" binary is 4.7 01:18 < mario-goulart> Did you build the release tarball or from git? 01:19 < cow-orker> from tarball. I didn't do anything special, just a make PLATFORM=linux as far as I can remember 01:20 < cow-orker> perhaps I should try building 4.7 with the 4.7 version? 01:20 < mario-goulart> Alright. This is weird. 01:21 < mario-goulart> Actually it wouldn't help. The release tarball doesn't require an installed chicken. 01:21 < mario-goulart> All you need is a C compiler and make. 01:22 < mario-goulart> what "which csc" shows? 01:22 < cow-orker> yes, that was my understanding as well. I can't quite understand. 01:23 < mario-goulart> It is possible that your environment is mixing different chicken versions. 01:23 < cow-orker> tom@wintermute:~/src/dw$ for x in csc csi chicken; do which $x; done 01:23 < cow-orker> /usr/local/bin/csc 01:23 < cow-orker> /usr/local/bin/csi 01:23 < cow-orker> /usr/local/bin/chicken 01:24 < mario-goulart> Do you have any chicken-related environment variable set? 01:24 < cow-orker> tom@wintermute:~/src/dw$ for x in csc csi chicken; do $x -version|grep Version; done 01:24 < cow-orker> Version 4.7.0 01:24 < cow-orker> Version 4.7.0 01:24 < cow-orker> Version 4.7.0 01:25 < cow-orker> tom@wintermute:~/src/dw$ env|grep -i CHICKEN 01:25 < cow-orker> tom@wintermute:~/src/dw$ 01:25 < cow-orker> none 01:25 < mario-goulart> Hmmm. 01:26 < mario-goulart> cow-orker: can run chicken-bug and take a look at the generated file? 01:29 < cow-orker> I can do that tomorrow, it's quite late here in norway and I think I need some sleep now :) Thank you very much for the help so far! 01:29 < mario-goulart> Alright! You're welcome. 01:30 < zbigniew> cow-orker: the tarball includes prebuilt sources. It isn't built from 4.4 or 4.5 01:35 < cow-orker> zbigniew: yes... a brainfart on my part :) I guess the problem can be solved by removing all traces of old and new chicken and installing 4.7 again. But I'd like to understand what is happening here... 01:37 < mario-goulart> cow-orker: the file generated by chicken-bug contains precious information (e.g., C_INSTALL_EGG_HOME, C_INSTALL_PREFIX). Take a look at it when you can.