This is the mail archive of the guile@cygnus.com mailing list for the guile project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
>>>>> "Dirk" == Dirk Herrmann <dirk@ida.ing.tu-bs.de> writes: Dirk> I installed guile-hobbit.1.3.1. For some reason, the 'hob' Dirk> command was not created the way I would have expected: it Dirk> did not use the information of `guile-config link` correctly Dirk> (see my manual patch for 'hob' below). However, maybe I Dirk> messed something up here. Dirk> Since I use the latest libtool (1.2b) I had to add further Where did you find this beta version (should be called 1.3b), so I can make some experiments ? Dirk> patches to the 'hob' command: libtool does not accept an Dirk> '-o' option any more with mode=compile. Further, during Dirk> linking dynamic libraries have to be prefixed with 'lib' (at Dirk> least on our system, which is solaris). According to the Dirk> libtool webpage, the 'lib'-prefix issue is out since libtool Dirk> version 1.1, so maybe this part of the patch may be of Dirk> common interest. I noticed that some days ago, as I upgraded from 1.0 to 1.2... Dirk> diff hob~ hob 87,89c87,88 < (let* ((o-name (string-append Dirk> (root-name (pure-name main-name)) ".o")) < (lo-name Dirk> (string-append (root-name (pure-name main-name)) ".lo")) < Dirk> (la-name (string-append (root-name (pure-name main-name)) Dirk> ".la")) --- >> (let* ((lo-name (string-append (root-name (pure-name >> main-name)) ".lo")) (la-name (string-append "lib" (root-name >> (pure-name main-name)) ".la")) Dirk> 102c101 < CC " " CFLAGS " -o " o-name --- >> CC " " CFLAGS Dirk> 154c153 < CC " " CFLAGS " -o " wrapper-o --- >> CC " " CFLAGS Dirk> 162c161 < la-name " Dirk> -L/automatix/home/dirk/pub/guile-19981109/lib -lguile"))) Dirk> --- >> la-name " -L/automatix/home/dirk/pub/guile-19981109/lib -lguile >> -ldl -lreadline -ltermcap -lsocket -lnsl -lm"))) The last patch means that a call to guile-config link is needed. Dirk> With this patch applied, calling hob worked for the first Dirk> time. However, link.scm in the hobbit4d directory had to be Dirk> updated as well: The added lib prefix had to be taken care Dirk> of here as well: Dirk> diff link.scm~ link.scm 153c153,155 < (let ((dyninfo Dirk> (%search-load-path (string-append path ".la")))) --- >> (let* ((dir (dir-name path)) (base (pure-name path)) (dyninfo >> (%search-load-path (string-append dir "/lib" base ".la")))) Ok. Dirk> Finally, there appeared to be a problem with hobbit and Dirk> 'use-modules': hobbit does not know that it is a macro and Dirk> tries to handle it as a function call. The following patch Currently, you can ONLY compile R4RS compliant code + defmacros which are defined in the file you are compiling. So this behaviour is normal up to now. Until all the module system stabilize (I am waiting for this since 2 years...), I will not invest much in guile-specific stuff. Dirk> makes hobbit ignore calls to 'use-modules' during Dirk> translation, which means that the loading of the appropriate Dirk> modules has to be done by the user, prior to loading the Dirk> dynamic libraries at run time. A good example of how to use modules is hobbit itself... Have a look at how hobbit4d/libhob.scm is compiled as a module. The safe way to use modules with hobbit is to mimic this process. This may solve the problem you have with cdr. If not, could you post a short and COMPLETE exemple showing this problem ? Thanks for you patches, and I hope the above will help. Regards. -- B. Urban