From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Thien-Thi Nguyen Newsgroups: gmane.lisp.guile.user Subject: Re: 1.6.0 problems with libguilereadline-v-12 and fix Date: Fri, 20 Sep 2002 13:42:06 -0700 Sender: guile-user-admin@gnu.org Message-ID: References: <20020918203311.3C5FA3F28@fnord.ir.bbn.com> <87k7ljgfvd.fsf@zagadka.ping.de> <87d6radoa5.fsf@raven.i.defaultvalue.org> Reply-To: ttn@glug.org NNTP-Posting-Host: localhost.gmane.org X-Trace: main.gmane.org 1032555716 11160 127.0.0.1 (20 Sep 2002 21:01:56 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Fri, 20 Sep 2002 21:01:56 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 17sUuQ-0002ti-00 for ; Fri, 20 Sep 2002 23:01:54 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 17sUuo-0002cC-00; Fri, 20 Sep 2002 17:02:18 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 17sUjR-0007Z4-00 for guile-user@gnu.org; Fri, 20 Sep 2002 16:50:33 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 17sUjO-0007YM-00 for guile-user@gnu.org; Fri, 20 Sep 2002 16:50:32 -0400 Original-Received: from ca-crlsca-cuda3-c6a-b-211.crlsca.adelphia.net ([68.71.15.211] helo=giblet) by monty-python.gnu.org with esmtp (Exim 4.10) id 17sUjN-0007Y7-00 for guile-user@gnu.org; Fri, 20 Sep 2002 16:50:30 -0400 Original-Received: from ttn by giblet with local (Exim 3.35 #1 (Debian)) id 17sUbF-0007rQ-00 for ; Fri, 20 Sep 2002 13:42:05 -0700 Original-To: guile-user@gnu.org In-reply-to: (message from Greg Troxel on 20 Sep 2002 08:04:22 -0400) Errors-To: guile-user-admin@gnu.org X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.lisp.guile.user:1057 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.user:1057 From: Greg Troxel Date: 20 Sep 2002 08:04:22 -0400 Your point about apps needing to link with the srfi libs is one I had not considered. If they link at compile time, then one either has them in a default path, uses LD_LIBRARY_PATH, or uses -rpath/-R (or loses). This is exactly the situation for libguile today. another option is to provide "guile-config link-internal". e.g.: $ guile-config link -L/home/ttn/local/lib -lguile -lltdl -lm $ guile-config link-internal guileqthreads guilereadline guilesrfi_13_14 guilesrfi_4 $ guile-config link-internal guilesrfi_13_14 -L/home/ttn/local/lib/guile/1.4.1.89/modules -lguilesrfi_13_14 this way, the large majority of people who don't care about these internal libraries can remain blissfully unaware of them, but yet the necessary info is available to those who have the need. their makefiles would look like: LIBS = `guile-config link` `guile-config link-internal guilesrfi_13_14` problem solved, everybody's happy. in fact, i like this idea so much, see below for a diff against scripts/guile-config that implements this in cvs (will appear in 1.4.1.90). thi _________________________________________________ Index: guile-config =================================================================== RCS file: /home/ttn/cvs/guile-core/scripts/guile-config,v retrieving revision 1.4 diff -w -c -b -c -r1.4 guile-config *** guile-config 1 Sep 2002 10:18:26 -0000 1.4 --- guile-config 20 Sep 2002 20:33:07 -0000 *************** *** 56,61 **** --- 56,67 ---- ;; Print the linker command-line flags necessary to link against ;; libguile, and any other libraries it requires. ;; + ;; * Usage: guile-config link-internal [LIB ...] + ;; + ;; If LIB is given, print the linker command-line flags necessary + ;; to link against internal libraries LIB ..., otherwise, print a list + ;; of the internal libraries. + ;; ;; * Usage: guile-config compile ;; ;; Print C compiler flags for compiling code that uses Guile. *************** *** 99,105 **** (define *this-module* (current-module)) ! (define *commands* '(link compile info re-prefix-info scmconfig acsubst)) (define *me* "guile-config") --- 105,117 ---- (define *this-module* (current-module)) ! (define *commands* '(link ! link-internal ! compile ! info ! re-prefix-info ! scmconfig ! acsubst)) (define *me* "guile-config") *************** *** 183,188 **** --- 195,212 ---- (else (cons (car libs) (loop (cdr libs)))))))) (newline)) + + + ;;; the "link-internal" subcommand + + (define (COMMAND:link-internal args) + (let ((m (format #f "~A/~A/modules" (GBI 'pkglibdir) (GBI 'guileversion)))) + (if (null? args) + (system (format #f "cd ~A && ls *.la | sed 's/^lib//;s/.la$//'" m)) + (begin + (format #t "-L~A" m) + (for-each (lambda (lib) (format #t " -l~A" lib)) args) + (format #t "\n"))))) ;;; the "compile" subcommand _______________________________________________ Guile-user mailing list Guile-user@gnu.org http://mail.gnu.org/mailman/listinfo/guile-user