From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Fu-Gangqiang Newsgroups: gmane.lisp.guile.bugs Subject: Can not work with libguile-2.0 Date: Thu, 17 Feb 2011 20:02:38 +0800 (CST) Message-ID: <1e640654.925f.12e338022b5.Coremail.lispor@163.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1297944209 10870 80.91.229.12 (17 Feb 2011 12:03:29 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 17 Feb 2011 12:03:29 +0000 (UTC) To: "Guile bug" Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Thu Feb 17 13:03:25 2011 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Pq2Zw-0003jn-Oj for guile-bugs@m.gmane.org; Thu, 17 Feb 2011 13:03:24 +0100 Original-Received: from localhost ([127.0.0.1]:46341 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pq2Zv-0003aU-Rw for guile-bugs@m.gmane.org; Thu, 17 Feb 2011 07:03:23 -0500 Original-Received: from [140.186.70.92] (port=38774 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pq2Zf-0003Pc-Lc for bug-guile@gnu.org; Thu, 17 Feb 2011 07:03:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pq2Zd-00087d-Sj for bug-guile@gnu.org; Thu, 17 Feb 2011 07:03:07 -0500 Original-Received: from m13-173.163.com ([220.181.13.173]:53221) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pq2Zc-00082q-IC for bug-guile@gnu.org; Thu, 17 Feb 2011 07:03:05 -0500 Original-Received: from lispor ( [110.52.62.11] ) by ajax-webmail-wmsvr173 (Coremail) ; Thu, 17 Feb 2011 20:02:38 +0800 (CST) X-Originating-IP: [110.52.62.11] X-Priority: 3 X-Mailer: Coremail Webmail Server Version SP_ntes V3.5 build 110119(12730.3605.3605) Copyright (c) 2002-2011 www.mailtech.cn 163com X-CM-TRANSID: rcGowKD7B7lfDl1NVdYSAA--.4483W X-CM-SenderInfo: xolv10ru6rljoofrz/1tbiDwnop0iNaEJOqgAAsC X-Coremail-Antispam: 1U5529EdanIXcx71UUUUU7vcSsGvfC2KfnxnUU== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Received-From: 220.181.13.173 X-BeenThere: bug-guile@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.bugs:5166 Archived-At: Hi,all I learn guile from manual,and I can not work with libguile and find some ma= nual bugs. scheme@(guile-user)> (version) $1 =3D "2.0.0" $ build-aux/config.guess=20 i686-pc-linux-gnu $ uname -a Linux 2.6.32-28-generic #55-Ubuntu SMP i686 GNU/Linux $ ./config.status --config '--disable-deprecated' 'BDW_GC_CFLAGS=3D-L/usr/local/lib' 'BDW_GC_LIBS=3D-l= gc' In manual section 2.3(Linking Guile into Programs) I follow the example,run it and have something wrong: ---->cut here<---- $ gcc -o simple-guile simple-guile.c `pkg-config --cflags --libs guile-2.0= ` $ ./simple-guile=20 ./simple-guile: error while loading shared libraries: libguile-2.0.so.22: c= annot open shared object file: No such file or directory ---->cut here<---- but I have libguile-2.0.so.22 installed in /usr/local/lib directroy $ pkg-config --cflags --libs guile-2.0 -pthread -L/usr/local/lib -I/usr/local/include/guile/2.0 -L/usr/local/lib = -lguile-2.0 -lgc =20 $ ls /usr/local/lib | grep libguile libguile-2.0.a libguile-2.0.la libguile-2.0.so libguile-2.0.so.22 libguile-2.0.so.22.0.0 libguilereadline-v-18.a libguilereadline-v-18.la libguilereadline-v-18.so libguilereadline-v-18.so.18 libguilereadline-v-18.so.18.0.0 when I follow section 5.1.2(A Sample Guile Main Program) using Autoconf too= ls also have some problem: $ aclocal $ autoconf $ ./configure checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables...=20 checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed ./configure: line 2490: GUILE-FLAGS: command not found configure: creating ./config.status config.status: creating Makefile $ make gcc -c @GUILE_CFLAGS@ simple-guile.c gcc: @GUILE_CFLAGS@: No such file or directory simple-guile.c:1:22: error: libguile.h: No such file or directory make: *** [simple-guile.o] Error 1 And in section 2.4(Writing Guile Extensions) There are some deprecated functions in the example,also in the section 5.2.= 1(A Sample Guile Extension) I use scm_from_double,scm_to_double instead, I run the mannal cmd and also have something wrong: ---->cut here<---- $ gcc -shared -o libguile-bessel.so -fPIC t1.c=20 t1.c:2:22: error: libguile.h: No such file or directory t1.c:5: error: expected =E2=80=98=3D=E2=80=99, =E2=80=98,=E2=80=99, =E2=80= =98;=E2=80=99, =E2=80=98asm=E2=80=99 or =E2=80=98__attribute__=E2=80=99 bef= ore =E2=80=98j0_wrapper=E2=80=99 t1.c: In function =E2=80=98init_bessel=E2=80=99: t1.c:13: error: =E2=80=98j0_wrapper=E2=80=99 undeclared (first use in this = function) t1.c:13: error: (Each undeclared identifier is reported only once t1.c:13: error: for each function it appears in.) ---->cut here<---- But when I run cmd: gcc -shared -o libguile-bessel.so -fPIC t1.c `pkg-config --cflags --libs gu= ile-2.0` everything is OK!