This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "dpkg's main repository".
The branch, dpkg-shlibdeps-buxy has been updated
via 2d895b020241d192a73261dde800a2f16520296f (commit)
via a0880440c9b169ced9a4fc9af84d44fe0ad94876 (commit)
via 0a44fac4b6c1678949d967edb4dfbecf9775159f (commit)
from a0e24d52a9eaabfacf0a59664a1efe3aa9ecfdb0 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 2d895b020241d192a73261dde800a2f16520296f
Author: Raphael Hertzog <[EMAIL PROTECTED]>
Date: Fri Aug 3 17:31:09 2007 +0200
Small man page update.
commit a0880440c9b169ced9a4fc9af84d44fe0ad94876
Author: Raphael Hertzog <[EMAIL PROTECTED]>
Date: Fri Aug 3 16:57:49 2007 +0200
Avoid creating empty DEBIAN/symbols files during build.
Once invoked, dpkg-gensymbols used to always write out a file
even if the scan didn't find any symbol information. Now, unless
the output file has been manually specified, it won't do so
anymore. With this change, it's now possible to always add
a dpkg-gensymbols call in debian/rules and it will really be a
no-op if the package doesn't contain a library.
commit 0a44fac4b6c1678949d967edb4dfbecf9775159f
Author: Raphael Hertzog <[EMAIL PROTECTED]>
Date: Fri Aug 3 16:26:46 2007 +0200
Avoid failing on invalid symlinks looking like a library.
Do this by adding a check to restrict the scan to plain files only.
-----------------------------------------------------------------------
Summary of changes:
man/dpkg-gensymbols.1 | 6 +++---
scripts/Dpkg/Shlibs/SymbolFile.pm | 5 +++++
scripts/dpkg-gensymbols.pl | 18 ++++++++++++------
3 files changed, 20 insertions(+), 9 deletions(-)
diff --git a/man/dpkg-gensymbols.1 b/man/dpkg-gensymbols.1
index 7a190d6..7a76f1b 100644
--- a/man/dpkg-gensymbols.1
+++ b/man/dpkg-gensymbols.1
@@ -10,9 +10,9 @@ dpkg\-gensymbols \- generate symbols files (shared library
dependency informatio
.SH DESCRIPTION
.B dpkg\-gensymbols
scans a temporary build tree (debian/tmp by default) looking for libraries
-and generate a \fIsymbols\fR file describing them. This file is then
-installed in the DEBIAN subdirectory of the build tree so that it ends up
-included in the control information of the package.
+and generate a \fIsymbols\fR file describing them. This file, if
+non-empty, is then installed in the DEBIAN subdirectory of the build tree
+so that it ends up included in the control information of the package.
.P
When generating those files, it uses as input some symbols files
provided by the maintainer. It looks for the following files (and use the
diff --git a/scripts/Dpkg/Shlibs/SymbolFile.pm
b/scripts/Dpkg/Shlibs/SymbolFile.pm
index 5930c8d..b66c666 100644
--- a/scripts/Dpkg/Shlibs/SymbolFile.pm
+++ b/scripts/Dpkg/Shlibs/SymbolFile.pm
@@ -164,6 +164,11 @@ sub merge_symbols {
}
}
+sub is_empty {
+ my ($self) = @_;
+ return scalar(keys %{$self->{objects}}) ? 0 : 1;
+}
+
sub has_object {
my ($self, $soname) = @_;
return exists $self->{objects}{$soname};
diff --git a/scripts/dpkg-gensymbols.pl b/scripts/dpkg-gensymbols.pl
index 321def8..84ebd77 100755
--- a/scripts/dpkg-gensymbols.pl
+++ b/scripts/dpkg-gensymbols.pl
@@ -148,7 +148,7 @@ if (not scalar @files) {
opendir(DIR, "$libdir") ||
syserr(sprintf(_g("Can't read directory %s: %s"), $libdir, $!));
push @files, grep {
- /(\.so\.|\.so$)/ &&
+ /(\.so\.|\.so$)/ && -f $_ &&
Dpkg::Shlibs::Objdump::is_elf($_);
} map { "$libdir/$_" } readdir(DIR);
close(DIR);
@@ -160,7 +160,7 @@ my $od = Dpkg::Shlibs::Objdump->new();
foreach my $file (@files) {
print "Scanning $file for symbol information\n" if $debug;
my $objid = $od->parse($file);
- unless (defined($objid)) {
+ unless (defined($objid) && $objid) {
warning(sprintf(_g("Objdump couldn't parse %s\n"), $file));
next;
}
@@ -183,11 +183,17 @@ if ($stdout) {
$symfile->save("-");
} else {
unless (defined($output)) {
- $output = "$packagebuilddir/DEBIAN/symbols";
- mkdir("$packagebuilddir/DEBIAN") if not -e "$packagebuilddir/DEBIAN";
+ unless($symfile->is_empty()) {
+ $output = "$packagebuilddir/DEBIAN/symbols";
+ mkdir("$packagebuilddir/DEBIAN") if not -e
"$packagebuilddir/DEBIAN";
+ }
+ }
+ if (defined($output)) {
+ print "Storing symbols in $output.\n" if $debug;
+ $symfile->save($output);
+ } else {
+ print "No symbol information to store.\n" if $debug;
}
- print "Storing symbols in $output.\n" if $debug;
- $symfile->save($output);
}
# Check if generated files differs from reference file
hooks/post-receive
--
dpkg's main repository
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]