From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.bugs,gmane.comp.gnu.libtool.bugs Subject: Re: documentation / behavior discrepancy with lt_dlopenext Date: Fri, 01 Jul 2011 17:03:03 +0200 Message-ID: <87iprm6o2g.fsf@pobox.com> References: 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 1309535008 6817 80.91.229.12 (1 Jul 2011 15:43:28 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 1 Jul 2011 15:43:28 +0000 (UTC) Cc: bug-guile@gnu.org To: bug-libtool@gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Fri Jul 01 17:43:22 2011 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QcfsG-0006a8-Jo for guile-bugs@m.gmane.org; Fri, 01 Jul 2011 17:43:20 +0200 Original-Received: from localhost ([::1]:51853 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QcfsE-0003Vz-Uc for guile-bugs@m.gmane.org; Fri, 01 Jul 2011 11:43:19 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:46257) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QcfFR-0001LF-FY for bug-guile@gnu.org; Fri, 01 Jul 2011 11:03:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QcfFP-0008IE-4g for bug-guile@gnu.org; Fri, 01 Jul 2011 11:03:12 -0400 Original-Received: from a-pb-sasl-sd.pobox.com ([64.74.157.62]:48319 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QcfFN-0008Ha-Rn; Fri, 01 Jul 2011 11:03:10 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 5FE615D06; Fri, 1 Jul 2011 11:05:23 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; s=sasl; bh=UMKBtQOYoY+p A9F7SAMBIoHjSdY=; b=Ugj5COR+l4Mjvk7JwDNN8rmhDdHI5KNZB1Nf0xZHapSS e5l5DyBXfR3ZG0oVW6AeBJczPyyhQIdHAzrcV/7mAbRuErcbYiOe9sVPN+Zbtbsv O0T/bN/51ikOJvYIinDvz5VE1TOo9fNIbHAZWgFWvP9fFfGnsVLVTsG0rBUWsKA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; q=dns; s=sasl; b=lKFq78 oUs7/tn6dFVrLQyS41E8f+K4l/uzWof188gtK7TxKeE5V3qV+1gUl8tjLgZlzBWH Nc0T65Ny+wwuCMgKqaSdV4K1tie1WbvCf/1BJ71+RHfixIAZcgF04Z9/2Zj30sOE cQtgrfbdykjvpvQBE01uj0izdDlYuaKKAOrd4= Original-Received: from a-pb-sasl-sd.pobox.com (unknown [127.0.0.1]) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTP id 208D05D05; Fri, 1 Jul 2011 11:05:23 -0400 (EDT) Original-Received: from badger (unknown [95.21.56.70]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-pb-sasl-sd.pobox.com (Postfix) with ESMTPSA id 29CEF5D04; Fri, 1 Jul 2011 11:05:22 -0400 (EDT) In-Reply-To: (Andy Wingo's message of "Wed, 30 Mar 2011 19:19:18 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-Pobox-Relay-ID: 8ADBD630-A3F3-11E0-A387-5875C023C68D-02397024!a-pb-sasl-sd.pobox.com X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 64.74.157.62 X-BeenThere: bug-guile@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.bugs:5702 gmane.comp.gnu.libtool.bugs:7803 Archived-At: Hi list, Re-sending this report, now that you have debbugs. On Wed 30 Mar 2011 19:19, Andy Wingo writes: > The ltdl docs say: > > =E2=80=94 Function: lt_dlhandle lt_dlopenext (const char *filename) > > The same as lt_dlopen, except that it tries to append different f= ile > name extensions to the file name. If the file with the file name > FILENAME cannot be found libltdl tries to append the following > extensions: [...] > > However, there are cases in which lt_dlopenext does not look for a bare > filename. Specifically the code does: > > if (!filename > || !advise > || !advise->try_ext > || has_library_ext (filename)) > try the bare file > else if (filename && *filename) > try extensions... > > So, we see that if has_library_ext is FALSE, we don't try the bare > file. But that check fails for full paths, like > "/usr/lib64/libSDL-1.2.so.0.11.3". > > $ strace guile -c '(dynamic-link "/usr/lib64/libSDL-1.2.so.0.11.3")' > [...] > open("/usr/lib64/libSDL-1.2.so.0.11.3.la", O_RDONLY) =3D -1 ENOENT (N= o such file or directory) > open("/usr/lib64/libSDL-1.2.so.0.11.3.so", O_RDONLY) =3D -1 ENOENT (N= o such file or directory) > [...] > > The documentation and the code do not agree. I propose that we fix the > code, to add another `stat' (I know) -- of the bare file name, before > trying to add extensions, in the dlopenext case. > > What do you think? The original discussion was here: http://thread.gmane.org/gmane.lisp.guile.bugs/5387 Any ideas? :-) Andy --=20 http://wingolog.org/