Debian Bug report logs - #21408
dpkg-dev: dpkg-shlibdeps parsing of ldd is overly picky, it could be more robust

version graph

Package: dpkg-dev; Maintainer for dpkg-dev is Dpkg Developers <debian-dpkg@lists.debian.org>; Source for dpkg-dev is src:dpkg (PTS, buildd, popcon).

Reported by: "Gregory S. Stark" <gsstark@mit.edu>

Date: Mon, 20 Apr 1998 01:03:01 UTC

Severity: normal

Merged with 27277

Found in version 1.4.0.22

Done: Adam Heath <adam@doogie.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Klee Dienes and Ian Jackson <dpkg-maint@chiark.greenend.org.uk>:
Bug#21408; Package dpkg-dev. (full text, mbox, link).


Acknowledgement sent to "Gregory S. Stark" <gsstark@mit.edu>:
New bug report received and forwarded. Copy sent to Klee Dienes and Ian Jackson <dpkg-maint@chiark.greenend.org.uk>. (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: "Gregory S. Stark" <gsstark@mit.edu>
To: submit@bugs.debian.org
Subject: dpkg-dev: dpkg-shlibdeps parsing of ldd is overly picky, it could be more robust
Date: Sun, 19 Apr 1998 21:01:29 +4400
Package: dpkg-dev
Version: 1.4.0.22

I had a hell of a time getting dpkg-shlibdeps to handle my package which
contains shared libraries. Because ldd never found the libraries installed
dpkg-shlibdeps reported errors. This despite the shlibs.local file which gave
it all the information it needed.

The following patch makes dpkg-shlibdeps much more robust in its handling of
ldd output. Rather than always expect a filename followed by a base address it
simply uses the filename if present, and otherwise continues without it. And in
any case it doesn't require the base address.

It works well for me.

--- dpkg-shlibdeps.orig	Mon Apr  6 23:37:09 1998
+++ dpkg-shlibdeps.hacked	Mon Apr  6 23:37:17 1998
@@ -99,10 +99,10 @@
 	    $nthisldd++;
 	} elsif (m,\s+statically linked(\s+\(ELF\))?$,) {
 	    $nthisldd++;
-	} elsif (m,^\s+(\S+)\.so\.(\S+)\s+=>\s+(/\S+)(\s+\(0x.+\))?$,) {
+	} elsif (m,^\s+(\S+)\.so\.(\S+)\s+=>\s+(/\S+)?,) {
 	    push(@libname,$1); push(@libsoname,$2); push(@libpath,$3);
 	    push(@libf,$execf[$i]);
-	    push(@libpaths,$3) if !$libpathadded{$3}++;
+	    push(@libpaths,$3) if defined($3) && !$libpathadded{$3}++;
 	    $nthisldd++;
 	} else {
 	    &warn("unknown output from ldd on \`$exec[$i]': \`$_'");


-- System Information
Debian Release: 2.0 (frozen)
Kernel Version: Linux portE19.Generation.NET 2.0.33 #2 Mon Jan 12 11:08:08 EST 1998 i586 unknown



Information forwarded to debian-bugs-dist@lists.debian.org, Ian Jackson and others <dpkg-maint@chiark.greenend.org.uk>:
Bug#21408; Package dpkg-dev. (full text, mbox, link).


Acknowledgement sent to gsstark@mit.edu (Gregory S. Stark):
Extra info received and forwarded to list. Copy sent to Ian Jackson and others <dpkg-maint@chiark.greenend.org.uk>. (full text, mbox, link).


Message #10 received at 21408@bugs.debian.org (full text, mbox, reply):

From: gsstark@mit.edu (Gregory S. Stark)
To: debian-devel@lists.debian.org, 21408@bugs.debian.org
Subject: Is there any cance this bug will be addressed?
Date: 25 Nov 1998 15:51:06 -0500
Is there any chance bug 21408 on dpkg-dev about dpkg-shlibdeps will be
addressed sometime? I can't see how any package which includes binaries linked
against shared libraries in the same source package could possibly be properly
handled by dpkg-shlibdeps without this one-line patch.

greg



Information forwarded to debian-bugs-dist@lists.debian.org, Ian Jackson and others <dpkg-maint@chiark.greenend.org.uk>:
Bug#21408; Package dpkg-dev. (full text, mbox, link).


Acknowledgement sent to gsstark@mit.edu (Gregory S. Stark):
Extra info received and forwarded to list. Copy sent to Ian Jackson and others <dpkg-maint@chiark.greenend.org.uk>. (full text, mbox, link).


Message #15 received at 21408@bugs.debian.org (full text, mbox, reply):

From: gsstark@mit.edu (Gregory S. Stark)
To: 27277@bugs.debian.org, 21408@bugs.debian.org, bap@cs.unm.edu
Subject: This is actually a dpkg-shlibdeps bug
Date: 25 Nov 1998 16:41:45 -0500
This is actually caused by the alpha build engines not having a fixed version
of dpkg-shlibdeps. The patch is below, I reported this bug 213 days ago,
according to the BTS.

I'll merge this bug into the dpkg-shlibdeps bug.

--- dpkg-shlibdeps.orig Mon Apr  6 23:37:09 1998
+++ dpkg-shlibdeps.hacked       Mon Apr  6 23:37:17 1998
@@ -99,10 +99,10 @@
            $nthisldd++;
        } elsif (m,\s+statically linked(\s+\(ELF\))?$,) {
            $nthisldd++;
-       } elsif (m,^\s+(\S+)\.so\.(\S+)\s+=>\s+(/\S+)(\s+\(0x.+\))?$,) {
+       } elsif (m,^\s+(\S+)\.so\.(\S+)\s+=>\s+(/\S+)?,) {
            push(@libname,$1); push(@libsoname,$2); push(@libpath,$3);
            push(@libf,$execf[$i]);
-           push(@libpaths,$3) if !$libpathadded{$3}++;
+           push(@libpaths,$3) if defined($3) && !$libpathadded{$3}++;
            $nthisldd++;
        } else {
            &warn("unknown output from ldd on \`$exec[$i]': \`$_'");





Merged 21408 27277. Request was from gsstark@mit.edu (Gregory S. Stark) to control@bugs.debian.org. (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Ian Jackson and others <dpkg-maint@chiark.greenend.org.uk>:
Bug#21408; Package dpkg-dev. (full text, mbox, link).


Acknowledgement sent to Martin Schulze <joey@infodrom.north.de>:
Extra info received and forwarded to list. Copy sent to Ian Jackson and others <dpkg-maint@chiark.greenend.org.uk>. (full text, mbox, link).


Message #22 received at 21408@bugs.debian.org (full text, mbox, reply):

From: Martin Schulze <joey@finlandia.Infodrom.North.DE>
To: "Gregory S. Stark" <gsstark@mit.edu>
Cc: debian-devel@lists.debian.org, 21408@bugs.debian.org
Subject: Re: Is there any cance this bug will be addressed?
Date: Fri, 4 Dec 1998 12:35:27 +0100
Gregory S. Stark wrote:
> 
> Is there any chance bug 21408 on dpkg-dev about dpkg-shlibdeps will be
> addressed sometime? I can't see how any package which includes binaries linked
> against shared libraries in the same source package could possibly be properly
> handled by dpkg-shlibdeps without this one-line patch.

Can you provide a proper patch?

Regards,

	Joey

-- 
Unable to locate coffee, operator halted.  -- Stefan Farsch


Reply sent to Adam Heath <adam@doogie.org>:
You have taken responsibility. (full text, mbox, link).


Notification sent to "Gregory S. Stark" <gsstark@mit.edu>:
Bug acknowledged by developer. (full text, mbox, link).


Message #27 received at 21408-done@bugs.debian.org (full text, mbox, reply):

From: Adam Heath <adam@doogie.org>
To: 21408-done@bugs.debian.org
Subject: Re: 21408: dpkg-dev: dpkg-shlibdeps parsing of ldd is overly picky, it could be more robust
Date: Sat, 23 Dec 2000 01:42:56 -0600 (CST)
This was fixed in 1.7.0, when dpkg-shlibdeps was switched to objdump.

----BEGIN GEEK CODE BLOCK----
Version: 3.12
GCS d- s: a-- c+++ UL++++ P+ L++++ !E W+ M o+ K- W--- !O M- !V PS--
PE++ Y+ PGP++ t* 5++ X+ tv b+ D++ G e h*! !r z?
-----END GEEK CODE BLOCK-----
----BEGIN PGP INFO----
Adam Heath <doogie@debian.org>        Finger Print | KeyID
67 01 42 93 CA 37 FB 1E    63 C9 80 1D 08 CF 84 0A | DE656B05 PGP
AD46 C888 F587 F8A3 A6DA  3261 8A2C 7DC2 8BD4 A489 | 8BD4A489 GPG
-----END PGP INFO-----




Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Thu Apr 25 07:57:33 2024; Machine Name: buxtehude

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.