]> git.donarmstrong.com Git - debhelper.git/commitdiff
r273: * dh_installdocs.1: clarified how the doc-id is determined. Closes: #44864
authorjoey <joey>
Sat, 11 Sep 1999 20:26:37 +0000 (20:26 +0000)
committerjoey <joey>
Sat, 11 Sep 1999 20:26:37 +0000 (20:26 +0000)
   * dh_makeshlibs: will now overwrite existing debian/tmp/DEBIAN/shlibs
     files, instead of erroring out. (Closes: #44828)

debian/changelog
dh_installdocs.1
dh_makeshlibs
dh_makeshlibs.1

index a770e735dbc01f994260d6d8072f61661a2c1551..c0e2b18f67bb1953506e11bdab469517054d84b5 100644 (file)
@@ -1,3 +1,11 @@
+debhelper (2.0.45) unstable; urgency=low
+
+  * dh_installdocs.1: clarified how the doc-id is determined. Closes: #44864
+  * dh_makeshlibs: will now overwrite existing debian/tmp/DEBIAN/shlibs
+    files, instead of erroring out. (Closes: #44828)
+
+ -- Joey Hess <joeyh@master.debian.org>  Sat, 11 Sep 1999 13:15:33 -0700
+
 debhelper (2.0.44) unstable; urgency=low
 
   * dh_compress: fixed #ARGV bug (again) Closes: #44853
 debhelper (2.0.44) unstable; urgency=low
 
   * dh_compress: fixed #ARGV bug (again) Closes: #44853
index 54d1a136b4e19e7955ce3c64d55b55a8b9ebcb40..01e4feb82820fc1e19b0b8b234ab428f06ef2c21 100644 (file)
@@ -42,8 +42,8 @@ a doc-base control file, and will make this program automatically generate the
 postinst and prerm commands needed to interface with the doc-base package. See
 .BR dh_installdeb (1)
 for an explanation of how this works.
 postinst and prerm commands needed to interface with the doc-base package. See
 .BR dh_installdeb (1)
 for an explanation of how this works.
-Note that the doc-id will be determined from the doc-base control file 
-in question.
+Note that the doc-id will be determined from the "Document:" entry in the
+doc-base control file in question.
 .PP
 If your package needs to register more
 than one document, you need multiple files. To accomplish this, you can use
 .PP
 If your package needs to register more
 than one document, you need multiple files. To accomplish this, you can use
index a09e26f69f2dcb9c414e5092e0b9152c6409071f..c3742267eeaf78a5ecdb22bfd3ff4d74f7ec7ba9 100755 (executable)
@@ -1,30 +1,47 @@
-#!/bin/sh -e
+#!/usr/bin/perl -w
 #
 # Automatically generate shlibs files.
 
 #
 # Automatically generate shlibs files.
 
-PATH=debian:$PATH:/usr/lib/debhelper
-. dh_lib
+BEGIN { push @INC, "debian", "/usr/share/debhelper" }
+use Dh_Lib;
+init();
 
 
-for PACKAGE in $DH_DOPACKAGES; do
-       TMP=`tmpdir $PACKAGE`
+foreach $PACKAGE (@{$dh{DOPACKAGES}}) {
+       $TMP=tmpdir($PACKAGE);
 
 
-       if [ -e "debian/$TMP/DEBIAN/shlibs" ]; then
-               error "debian/$TMP/DEBIAN/shlibs already exists."
-       fi
+       doit("rm", "-f", "$TMP/DEBIAN/shlibs");
 
 
-       for file in `find debian/$TMP -type f -name "*.so*" | tr "\n" " "` ; do
-               LIBRARY=`expr $file : ".*/\(.*\)\.so\..*"` || true
-               VERSION=`expr $file : ".*/.*\.so\.\(.*\)"` || true
-               MAJOR=`expr $VERSION : "\([0-9]*\)\."` || true
-               LIBSTUB=`expr $file : "\(.*\/.*\.so\)\..*"` || true
-               if [ ! -d "debian/$TMP/DEBIAN" ] ; then
-                       doit "install -d debian/$TMP/DEBIAN"
-               fi
-               verbose_echo "echo \"$LIBRARY $MAJOR $PACKAGE\" >>debian/$TMP/DEBIAN/shlibs"
-               echo "$LIBRARY $MAJOR $PACKAGE" >>debian/$TMP/DEBIAN/shlibs
-       done
+       open (FIND, "find $TMP -type f -name '*.so.*' |");
+       while (<FIND>) {
+               chomp;
+               ($library, $major)=m#.*/(.*)\.so\.(\d*)\.?#;
+               if (defined($dh{M_PARAMS}) && $dh{M_PARAMS} ne '') {
+                       $major=$dh{M_PARAMS};
+               }
+               if (! -d "$TMP/DEBIAN") {
+                       doit("install","-d","$TMP/DEBIAN");
+               }
+               $deps=$PACKAGE;
+               if ($dh{V_FLAG_SET}) {
+                       if ($dh{V_FLAG} ne '') {
+                               $deps=$dh{V_FLAG};
+                       }       
+                       else {
+                               # Call isnative becuase it sets $dh{VERSION}
+                               # as a side effect.
+                               isnative($PACKAGE);
+                               $deps="$PACKAGE (>= $dh{VERSION})";
+                       }
+               }
+               if (defined($library) && defined($major) && defined($deps) && 
+                   $library ne '' && $major ne '' && $deps ne '') {
+                       complex_doit("echo '$library $major $deps' >>$TMP/DEBIAN/shlibs");
+               }
+       }
+       close FIND;
 
 
-       if [ -e "debian/$TMP/DEBIAN/shlibs" ]; then
-               doit "chown root.root debian/$TMP/DEBIAN/shlibs"
-       fi
-done
+       if (-e "$TMP/DEBIAN/shlibs") {
+               doit("chmod",644,"$TMP/DEBIAN/shlibs");
+               doit("chown","root.root","$TMP/DEBIAN/shlibs");
+       }
+}
index 51ba8feeed2b9a12d13640f71d773383781b7328..443cc0cbbbcc925112c8212348d2e81ec008051a 100644 (file)
@@ -1,47 +1,60 @@
-.TH DH_MAKESHLIBS 1
+.TH DH_MAKESHLIBS 1 "" "Debhelper Commands" "Debhelper Commands"
 .SH NAME
 dh_makeshlibs \- automatically create shlibs file
 .SH SYNOPSIS
 .B dh_makeshlibs
 .SH NAME
 dh_makeshlibs \- automatically create shlibs file
 .SH SYNOPSIS
 .B dh_makeshlibs
-.I "[-v] [-a] [-i] [-ppackage]"
+.I "[debhelper options] [-mmajor] [-V[dependancies]]"
 .SH "DESCRIPTION"
 dh_makeshlibs is a debhelper program that automatically scans for shared
 libraries, and generates a shlibs file for the libraries it finds.
 .SH "DESCRIPTION"
 dh_makeshlibs is a debhelper program that automatically scans for shared
 libraries, and generates a shlibs file for the libraries it finds.
-.P
-For this program to work, you cannot have already installed a DEBIAN/shlibs
-file. If such a file exits, the program will exit with an error.
 .SH OPTIONS
 .TP
 .SH OPTIONS
 .TP
-.B \-v
-Verbose mode; show all commands that modify the package build directory.
+.B debhelper options
+See
+.BR debhelper (1)
+for a list of options common to all debhelper commands.
 .TP
 .TP
-.B \-a
-Generate shlibs files for all architecture dependent packages.
+.B \-mmajor, \--major=major
+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.
 .TP
 .TP
-.B \-i
-Generate shlibs files for all architecture independent packages.
+.B \-V[dependancies], \--version-info, \--version-info=dependancies
+By default, the shlibs file generated by this program does not make packages
+depend on any particular version of the package containing the shared
+library. It may be necessary for you to add some version dependancy
+information to the shlibs file. If -V is specified with no dependancy
+information, the current version of the package is plugged into a dependancy
+that looks like "packagename (>= packageversion)". If -V is specified with
+parameters, the parameters can be used to specify the exact dependancy
+information needed (be sure to include the package name).
+.SH EXAMPLES
 .TP
 .TP
-.B \-ppackage
-Generate shlibs file for the package named "package".
-.SH NOTES
-The
-.B \-a
-.B \-i
-and
-.B \-p
-arguments are cumulative. If none are specified, then all packages listed in
-the control file will be effected.
-.SH ENVIRONMENT
+.B dh_makeshlibs
+Assuming this is a package named libfoobar1, generates a shlibs file that
+looks something like:
+  libfoobar 1 libfoobar1
 .TP
 .TP
-.I DH_VERBOSE
-Enables verbose mode
+.B dh_makeshlibs \-V
+Assuming the current version of the package is 1.0-3, generates a shlibs
+file that looks something like:
+  libfoobar 1 libfoobar1 (>= 1.0-3)
+.TP
+.B dh_makeshlibs \-V "'libfoobar1 (>= 1.0)'"
+Generates a shlibs file that looks something like:
+  libfoobar 1 libfoobar1 (>= 1.0)
+.SH ENVIRONMENT
+See
+.BR debhelper (1)
+for a list of environment variables that affect all debhelper commands.
 .SH "SEE ALSO"
 .SH "SEE ALSO"
-.BR /usr/doc/debhelper/README
+.BR debhelper (1)
 .SH BUGS
 .SH BUGS
-There is no guarentee that the program will get the shlibs file right. For
+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
 example, it may not correctly guess the major number of your package. In
-casews like these (and perhaps in general, just to be safe), it is better to
-create a debian/shlibs file by hand.
+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.
+.P
 This is a "do what I Mean" type program - you have been warned!
 .SH AUTHOR
 Joey Hess <joeyh@master.debian.org>
 This is a "do what I Mean" type program - you have been warned!
 .SH AUTHOR
 Joey Hess <joeyh@master.debian.org>