From 515a01d46a768ee63a4665c643cdd6889ffaebfc Mon Sep 17 00:00:00 2001 From: joey Date: Mon, 5 Mar 2001 00:36:29 +0000 Subject: [PATCH] r450: * Modified to use dpkg-architecture instead of dpkg --print-architecture. I hate this, and wish it wasn't necessary to make cross compiles for the hurd work. Closes: #88494 * Now depends on debconf-utils for debconf-mergetemplates. Closes: #87321 * Continues to depend on lynx for html changelog conversions. Yes, these and packages with translated debconf templates are rather rare, but it makes more sense for debhelper to consistently depend on all utilities it uses internally rather than force people to keep their dependancies up to date with debhelper internals. If I decide tomorrow that w3m is the better program to use to format html changelogs, I can make the change and packages don't need to update their build dependancies. Closes: #88464, #77743 * Test for init scripts before running them, since they are conffiles and the admin may have removed them for some reason, and policy wants us to deal with that gracefully. * dh_makeshlibs: now uses objdump, should be more accurate. Closes: #88426 * Wildcards have been supported for a while, Closes: #54197 * dh_installdocs and dh_link have been able to make doc-dir symlinks for a while, Closes: #51225 --- autoscripts/postinst-init | 6 ++++-- autoscripts/postinst-init-norestart | 9 ++++++++- autoscripts/prerm-init | 4 +++- autoscripts/prerm-init-norestart | 2 +- debian/changelog | 25 +++++++++++++++++++++++++ debian/control | 6 +++--- dh_installdebconf | 2 -- dh_makeshlibs | 28 ++++++++-------------------- 8 files changed, 52 insertions(+), 30 deletions(-) diff --git a/autoscripts/postinst-init b/autoscripts/postinst-init index 976c6b3..5ef99c7 100644 --- a/autoscripts/postinst-init +++ b/autoscripts/postinst-init @@ -1,2 +1,4 @@ -update-rc.d #SCRIPT# #INITPARMS# >/dev/null -/etc/init.d/#SCRIPT# start +if [ -e "#SCRIPT#" ]; then + update-rc.d #SCRIPT# #INITPARMS# >/dev/null + /etc/init.d/#SCRIPT# start +fi diff --git a/autoscripts/postinst-init-norestart b/autoscripts/postinst-init-norestart index 05357d0..d57bfc0 100644 --- a/autoscripts/postinst-init-norestart +++ b/autoscripts/postinst-init-norestart @@ -1 +1,8 @@ -update-rc.d #SCRIPT# #INITPARMS# >/dev/null +if [ -e "#SCRIPT#" ]; then + update-rc.d #SCRIPT# #INITPARMS# >/dev/null + if [ "$1" = "configure" ]; then + if [ -z "$2" -o "$2" = "" ]; then + /etc/init.d/#SCRIPT# start + fi + fi +fi diff --git a/autoscripts/prerm-init b/autoscripts/prerm-init index 64975a3..260d69d 100644 --- a/autoscripts/prerm-init +++ b/autoscripts/prerm-init @@ -1 +1,3 @@ -/etc/init.d/#SCRIPT# stop +if [ -e "#SCRIPT#" ]; then + /etc/init.d/#SCRIPT# stop +fi diff --git a/autoscripts/prerm-init-norestart b/autoscripts/prerm-init-norestart index ec9820f..e04ec25 100644 --- a/autoscripts/prerm-init-norestart +++ b/autoscripts/prerm-init-norestart @@ -1,3 +1,3 @@ -if [ "$1" = remove ]; then +if [ -e "#SCRIPT#" -a "$1" = remove ]; then /etc/init.d/#SCRIPT# stop fi diff --git a/debian/changelog b/debian/changelog index 15109a6..4468a46 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,28 @@ +debhelper (3.0.9) unstable; urgency=low + + * Modified to use dpkg-architecture instead of dpkg --print-architecture. + I hate this, and wish it wasn't necessary to make cross compiles for + the hurd work. Closes: #88494 + * Now depends on debconf-utils for debconf-mergetemplates. Closes: #87321 + * Continues to depend on lynx for html changelog conversions. Yes, these + and packages with translated debconf templates are rather rare, but + it makes more sense for debhelper to consistently depend on all utilities + it uses internally rather than force people to keep their dependancies + up to date with debhelper internals. If I decide tomorrow that w3m is + the better program to use to format html changelogs, I can make the + change and packages don't need to update their build dependancies. + Closes: #88464, #77743 + * Test for init scripts before running them, since they are conffiles and + the admin may have removed them for some reason, and policy wants + us to deal with that gracefully. + * dh_makeshlibs: now uses objdump, should be more accurate. Closes: + #88426 + * Wildcards have been supported for a while, Closes: #54197 + * dh_installdocs and dh_link have been able to make doc-dir symlinks for + a while, Closes: #51225 + + -- Joey Hess Sun, 4 Mar 2001 15:48:45 -0800 + debhelper (3.0.8) unstable; urgency=low * dh_perl update diff --git a/debian/control b/debian/control index 48ad49b..084fbb8 100644 --- a/debian/control +++ b/debian/control @@ -2,13 +2,13 @@ Source: debhelper Section: devel Priority: optional Maintainer: Joey Hess -Build-Depends-Indep: perl-5.6, fileutils (>= 4.0-2.1), file (>= 3.23-1) +Build-Depends-Indep: perl-5.6, fileutils (>= 4.0-2.1), file (>= 3.23-1), debconf-utils Standards-Version: 3.5.2.0 Package: debhelper Architecture: all -Depends: ${perl:Depends}, fileutils (>= 4.0-2.1), file (>= 3.23-1), dpkg-dev (>= 1.7.0), lynx -Suggests: dh-make, debconf-utils +Depends: ${perl:Depends}, fileutils (>= 4.0-2.1), file (>= 3.23-1), dpkg-dev (>= 1.7.0), lynx, debconf-utils, binutils +Suggests: dh-make Description: helper programs for debian/rules A collection of programs that can be used in a debian/rules file to automate common tasks related to building binary debian packages. Programs diff --git a/dh_installdebconf b/dh_installdebconf index f6a73ba..b6348ba 100755 --- a/dh_installdebconf +++ b/dh_installdebconf @@ -42,8 +42,6 @@ dot and a locale name repended. For example, if you have a German translation, debian/package.templates.de is merged with debian/package.templates. -If you use this feature, your package should build-depend on debconf-utils. - =head1 OPTIONS =over 4 diff --git a/dh_makeshlibs b/dh_makeshlibs index 1888ee2..fe31f5f 100755 --- a/dh_makeshlibs +++ b/dh_makeshlibs @@ -27,8 +27,10 @@ DH_COMPAT=3 mode and above only). =item B<-m>I, B<--major=>I -Instead of trying to guess the major number of the library from the -filename of the library, use the major number specified after the -m parameter. +Instead of trying to guess the major number of the library with objdump, +use the major number specified after the -m parameter. This is much less +useful than it used to be, back in the bad old days when this program +looked at library filenames rather than using objdump. =item B<-V>, B<-V>I @@ -68,14 +70,6 @@ file that looks something like: Generates a shlibs file that looks something like: libfoobar 1 libfoobar1 (>= 1.0) -=head1 NOTES - -There is no guarantee that the program will get the shlibs file right. For -example, it may not correctly guess the major number of your package. In -cases like these (and perhaps in general, just to be safe), it is better to -create a debian/shlibs file by hand, or force it to use the correct major -number by specifying the -m parameter. - =cut init(); @@ -90,19 +84,13 @@ foreach my $package (@{$dh{DOPACKAGES}}) { open (FIND, "find $tmp -xtype f -name '*.so*' |"); while () { - my $library; - my $major; - - chomp; - # The second evil regexp is for db3, whose author should - # be shot. - if (m#.*/([^/]*)\.so\.(\d*)\.?# || m#.*/([^/]*)-([^\s/]+)\.so$#) { - $library = $1; - $major = $2; - } + my ($library, $major) = + `objdump -p $_` =~ m/\s+SONAME\s+(.+)\.so\.(.+)/; + if (defined($dh{M_PARAMS}) && $dh{M_PARAMS} ne '') { $major=$dh{M_PARAMS}; } + if (! -d "$tmp/DEBIAN") { doit("install","-d","$tmp/DEBIAN"); } -- 2.39.2