summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjoeyh <joeyh>2006-01-28 17:55:32 +0000
committerjoeyh <joeyh>2006-01-28 17:55:32 +0000
commit62a94850bb899dfd239354150e5475c654ac448c (patch)
tree28f553f1eaf0d961ab04a4ae4d8113a146cc1f9b
parentb6da226d6eb94409547d04baeb76de3a2a27111d (diff)
r1871: * dh_makeshlibs: add support for adding udeb: lines to shlibs file
via --add-udeb parameter. Closes: #345471
-rw-r--r--Debian/Debhelper/Dh_Getopt.pm2
-rw-r--r--debian/changelog7
-rwxr-xr-xdh_makeshlibs17
-rw-r--r--doc/PROGRAMMING1
4 files changed, 27 insertions, 0 deletions
diff --git a/Debian/Debhelper/Dh_Getopt.pm b/Debian/Debhelper/Dh_Getopt.pm
index 5e3ffacf..aecac14d 100644
--- a/Debian/Debhelper/Dh_Getopt.pm
+++ b/Debian/Debhelper/Dh_Getopt.pm
@@ -166,6 +166,8 @@ sub parseopts {
"error-handler=s" => \$options{ERROR_HANDLER},
+ "add-udeb=s" => \$options{SHLIBS_UDEB},
+
"language=s" => \$options{LANGUAGE},
"<>" => \&NonOption,
diff --git a/debian/changelog b/debian/changelog
index 04c22653..46db5d08 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+debhelper (5.0.22) UNRELEASED; urgency=low
+
+ * dh_makeshlibs: add support for adding udeb: lines to shlibs file
+ via --add-udeb parameter. Closes: #345471
+
+ -- Joey Hess <joeyh@debian.org> Sat, 28 Jan 2006 12:53:00 -0500
+
debhelper (5.0.21) unstable; urgency=low
* dh_installman: correct mistake that broke translated man page installation
diff --git a/dh_makeshlibs b/dh_makeshlibs
index c530b4ce..1a1ddcc5 100755
--- a/dh_makeshlibs
+++ b/dh_makeshlibs
@@ -64,6 +64,11 @@ Do not modify postinst/postrm scripts.
Exclude files that contain "item" anywhere in their filename or directory
from being treated as shared libraries.
+=item B<--add-udeb=>I<udeb>
+
+Create an additional line for udebs in the shlibs file and use "udeb" as the
+package name for udebs to depend on instead of the regular library package.
+
=back
=head1 EXAMPLES
@@ -111,6 +116,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
# because only if we can get a library name and a major number from
# objdump is anything actually added.
my $exclude='';
+ my @udeb_lines;
if (defined($dh{EXCLUDE_FIND}) && $dh{EXCLUDE_FIND} ne '') {
$exclude="! \\( $dh{EXCLUDE_FIND} \\) ";
}
@@ -163,11 +169,22 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
if (! $seen{$line}) {
$seen{$line}=1;
complex_doit("echo '$line' >>$tmp/DEBIAN/shlibs");
+ if (defined($dh{SHLIBS_UDEB}) && $dh{SHLIBS_UDEB} ne '') {
+ my $udeb_deps = $deps;
+ $udeb_deps =~ s/$package/$dh{SHLIBS_UDEB}/e;
+ $line="udeb: "."$library $major $udeb_deps";
+ push @udeb_lines, $line;
+ }
}
}
}
close FIND;
+ # Write udeb: lines last.
+ foreach (@udeb_lines) {
+ complex_doit("echo '$_' >>$tmp/DEBIAN/shlibs");
+ }
+
# New as of dh_v3.
if (! compat(2) && ! $dh{NOSCRIPTS} && $need_ldconfig) {
autoscript($package,"postinst","postinst-makeshlibs");
diff --git a/doc/PROGRAMMING b/doc/PROGRAMMING
index bcdaef0c..45456787 100644
--- a/doc/PROGRAMMING
+++ b/doc/PROGRAMMING
@@ -145,6 +145,7 @@ switch variable description
the package name
--error-handler ERROR_HANDLER a function to call on error
--language LANGUAGE specify what language a file is in
+--add-udeb SHLIBS_UDEB used by dh_makeshlibs
Any additional command line parameters that do not start with "-" will be
ignored, and you can access them later just as you normally would.