From f60477e2f390146ca43bd82b2e70890ba037efca Mon Sep 17 00:00:00 2001 From: Raphael Hertzog Date: Sat, 24 Nov 2007 22:18:08 +0100 Subject: [PATCH] dpkg-gensymbols: Add new -I option to force usage of a particular symbols file --- ChangeLog | 6 ++++++ man/ChangeLog | 4 ++++ man/dpkg-gensymbols.1 | 4 ++++ scripts/dpkg-gensymbols.pl | 7 ++++++- 4 files changed, 20 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 053235c4..783dad8e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-11-24 Raphael Hertzog + + * scripts/dpkg-gensymbols.pl: Add a new -I option to force + the usage of a specific file as basis for the generated symbols + file. + 2007-11-24 Guillem Jover * configure.ac: Bump version to 1.14.12~. diff --git a/man/ChangeLog b/man/ChangeLog index deeaece9..a82f5ec7 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -1,3 +1,7 @@ +2007-11-24 Raphael Hertzog + + * dpkg-gensymbols.1: Document the new -I option. + 2007-11-22 Guillem Jover * dpkg-name.1: Document that the Package-Type field is now supported. diff --git a/man/dpkg-gensymbols.1 b/man/dpkg-gensymbols.1 index 8bd39979..ddae5899 100644 --- a/man/dpkg-gensymbols.1 +++ b/man/dpkg-gensymbols.1 @@ -117,6 +117,10 @@ libraries. You can use a regular expression in \fIlibrary-file\fR to match multiple libraries with a single argument (otherwise you need multiple \fB\-e\fR). .TP +.BI \-I filename +Use \fIfilename\fR as reference file to generate the symbols file +that is integrated in the package itself. +.TP .B \-O Print the generated symbols file to standard output, rather than being stored in the package build tree. diff --git a/scripts/dpkg-gensymbols.pl b/scripts/dpkg-gensymbols.pl index bab05c08..687e831c 100755 --- a/scripts/dpkg-gensymbols.pl +++ b/scripts/dpkg-gensymbols.pl @@ -27,6 +27,7 @@ my $sourceversion; my $stdout; my $oppackage; my $compare = 1; # Bail on missing symbols by default +my $input; my $output; my $debug = 0; my $host_arch = get_host_arch(); @@ -60,6 +61,8 @@ Options: (level goes from 0 for no check, to 4 for all checks). By default checks at level 1. + -I force usage of as reference symbols + file instead of the default file. -O write to , not .../DEBIAN/symbols. -O write to stdout, not .../DEBIAN/symbols. -d display debug information during work. @@ -93,6 +96,8 @@ while (@ARGV) { $packagebuilddir =~ s{/+$}{}; } elsif (m/^-O$/) { $stdout= 1; + } elsif (m/^-I(.+)$/) { + $input = $1; } elsif (m/^-O(.+)$/) { $output= $1; } elsif (m/^-(h|-help)$/) { @@ -121,7 +126,7 @@ if (not defined($oppackage)) { my $symfile = Dpkg::Shlibs::SymbolFile->new(); my $ref_symfile = Dpkg::Shlibs::SymbolFile->new(); # Load source-provided symbol information -foreach my $file ($output, "debian/$oppackage.symbols.$host_arch", +foreach my $file ($input, $output, "debian/$oppackage.symbols.$host_arch", "debian/symbols.$host_arch", "debian/$oppackage.symbols", "debian/symbols") { -- 2.39.5