]> git.donarmstrong.com Git - debhelper.git/commitdiff
r105: Initial Import
authorjoey <joey>
Tue, 17 Aug 1999 04:56:36 +0000 (04:56 +0000)
committerjoey <joey>
Tue, 17 Aug 1999 04:56:36 +0000 (04:56 +0000)
debian/changelog
dh_compress
dh_compress.1
dh_getopt.pl
dh_movefiles
doc/PROGRAMMING
doc/TODO

index 10b817989ebebbb69e6744c0ca402ac5c1257c8e..38ae77710d295e0ba627ba2f351945c5f1f501d0 100644 (file)
@@ -1,16 +1,18 @@
-debhelper (1.0.1) unstable; urgency=low
-
-  * Backported bug fixes from the 1.1 tree:
-  * dh_installdocs: used -m 655 for a TODO file. (minor, dh_fixperms cleans
-    up after it)
-  * dh_fixperms: had a problem with removing x bits on examples files
-  * dh_compress: since version 0.88 or so, dh_compress has bombed out if
-    a debian/compress file returned an error code. This was actually
-    unintentional - in fact, the debian/compress example in the man page
-    will fail this way if usr/info or usr/X11R6 is not present. Corrected
-    the program to not fail. (#26214)
-
- -- Joey Hess <joeyh@master.debian.org>  Sun, 30 Aug 1998 22:21:26 -0700
+debhelper (1.1.0) unstable; urgency=low
+
+  * New unstable branch of debhelper.
+  
+  * TODO: list all current bugs, in order I plan to tackle them.
+  * Added debhelper.1 man page, which groups all the debhelper options that
+    are common to all commands in once place so I can add new options w/o
+    updating 27 man pages.
+  * dh_*.1: updated all debheper man pages to refer to debhelper(1) where
+    appropriate. Also corrected a host of little errors.
+  * doc/README: moved a lot of this file into debhelper.1.
+  * dh_*: -N option now excludes a package from the list of packages the 
+    programs act on. (#25247)
+
+ -- Joey Hess <joeyh@master.debian.org>  Sat,  8 Aug 1998 17:49:56 -0700
 
 debhelper (1.0) stable unstable; urgency=low
 
index 1b58f70a19f85a7a6cbb268f634487d3cd4e6cc3..b94cfcfeec8ffe59292fed2279454c840ee76ba4 100755 (executable)
@@ -8,8 +8,16 @@ PATH=debian:$PATH:/usr/lib/debhelper
 
 # Returns a list of all the files that we want to compress,
 # (ignoring any files we were asked to exclude on the command
-# line). Assummes we are already in the temp directory.
+# line). Assumes we are already in the temp directory.
 filelist () {
+       # First of all, deal with any files specified right on the command line.
+        if [ \( "$PACKAGE" = "$DH_FIRSTPACKAGE" -o "$DH_PARAMS_ALL" \) \
+             -a "$*" ]; then
+               # Convert to having each file on its own line
+               # so grep will work.
+               echo "$*" | tr " " "\n"
+       fi
+
        if [ "$compress" ]; then
                # The config file is a sh script that outputs the files to be compressed
                # (typically using find).
@@ -28,7 +36,7 @@ filelist () {
 # Call only if DH_EXCLUDE_GREP is non-empty.
 filelist_excluded () {
        # Use grep -F so we don't have to worry about regexp's.
-       (filelist | grep -v -F \
+       (filelist "$*" | grep -v -F \
                "`echo "$DH_EXCLUDE_GREP" | tr "|" "\n"`") || true
 }
 
@@ -45,9 +53,9 @@ for PACKAGE in $DH_DOPACKAGES; do
 
        # Get the list of files to compress.
        if [ "$DH_EXCLUDE_GREP" ]; then
-               files=`filelist_excluded`
+               files=`filelist_excluded $*`
        else
-               files=`filelist`
+               files=`filelist $*`
        fi
 
        if [ "$files" ]; then
index ec0def529171ebd47daa24001876763566db227a..4e5ed9e82f2abb5933311890fcb9265036f5b608 100644 (file)
@@ -3,7 +3,7 @@
 dh_compress \- compress files and fix symlinks in package build directories
 .SH SYNOPSIS
 .B dh_compress
-.I "[debhelper options] [-Xitem]"
+.I "[debhelper options] [-Xitem] [-A] [file ...]"
 .SH "DESCRIPTION"
 dh_compress is a debhelper program that is responsible for compressing
 the files in package build directories, and makes sure that any symlinks
@@ -42,6 +42,13 @@ compressed. For example, -X=.jpeg will exclude jpeg's from compression.
 You may use this option multiple times to build up a list of things to
 exclude. You can accomplish the same thing by using a debian/compress file,
 but this is easier.
+.TP
+.B \-A, \--all
+Compress all files specified by command line parameters in ALL packages
+acted on.
+.TP
+.B file ...
+Add these files to the list of files to compress.
 .SH NOTES
 The debian/compress file applies to the first binary package listed in your
 control file. For the other packages, you can make files named
index f1aa7cecc9db7bed7bcb9c42fbea9f757d2eddf6..9b97089ed9162437dc5bb39ca3403927ba35a5b5 100755 (executable)
@@ -157,6 +157,8 @@ foreach (@exclude) {
 }
 $exclude_find=~s/ -or $//;
 
+$include=join ' ', @include;
+
 # Remove excluded packages from the list of packages to act on.
 undef @package_list;
 foreach $package (@packages) {
index a5669bfce5ddfb7855fcf4b27fc3ce4cc7afacc6..f44121c83689e6ff9f1a98d70c147120c6f5d8f2 100755 (executable)
@@ -40,16 +40,31 @@ for PACKAGE in $DH_DOPACKAGES; do
                #
                # (The echo is in here to expand wildcards. Note that 'ls'
                # won't work properly.)
-               # The filelist is used, so even very weird filenames can be
+               # The file list is used, so even very weird filenames can be
                # moved.
                doit "rm -f movelist"
                for i in `(cd debian/tmp; echo $tomove)`; do
-                       complex_doit "(cd debian/tmp ; find $i ! -type d -and ! -type l -print) >> movelist"
+                       if [ ! -e "debian/tmp/$i" ]; then
+                               fail=1
+                       fi
+                       complex_doit "(cd debian/tmp ; find $i ! -type d -and ! -type l -print || true) >> movelist"
                done
                for i in `(cd debian/tmp; echo $tomove)`; do
-                       complex_doit "(cd debian/tmp ; find $i ! -type d -and -type l -print) >> movelist"
+                       if [ ! -e "debian/tmp/$i" ]; then
+                               fail=1
+                       fi
+                       complex_doit "(cd debian/tmp ; find $i ! -type d -and -type l -print || true) >> movelist"
                done
                complex_doit "(cd debian/tmp;tar --create --remove-files --files-from=../../movelist --file -) | (cd $TMP;tar xpf -)"
                doit "rm -f movelist"
        fi
 done
+
+# If fail is set, we wern't actually able to find some 
+# files that were specified to be moved, and we should
+# exit with the code in fail. This program puts off 
+# exiting with an error until all files have been tried
+# to be moved, because this makes it easier for some 
+# packages that arn't always sure exactly which files need
+# to be moved.
+exit $fail
index 402d5e782387a32be6df7551a8bba3832bdb05f2..878c5a2e74ecb837df7e27e3ded1491765398e5f 100644 (file)
@@ -68,11 +68,11 @@ switch              variable        description
 -v             DH_VERBOSE      should the program verbosely output what it is
                                doing?
 --no-act       DH_NO_ACT       should the program not actually do anything?
--i,-a,-p       DH_DOPACKAGES   a space delimited list of the binary packages
+-i,-a,-p,-N    DH_DOPACKAGES   a space delimited list of the binary packages
                                to act on
--i,-p          DH_DOINDEP      a space delimited list of the binary independent
+-i,-p,-N       DH_DOINDEP      a space delimited list of the binary independent
                                packages to act on
--a,-p          DH_DOARCH       a space delimited list of the binary dependent
+-a,-p,-N       DH_DOARCH       a space delimited list of the binary dependent
                                packages to act on
 -n             DH_NOSCRIPTS    if set, do not make any modifications to the 
                                package's postinst, postrm, etc scripts.
index dbfc277198505836180e425b8b6c12b45ce08a01..0a2a5bdeed1a674e7425ed7192696b779cddc71b 100644 (file)
--- a/doc/TODO
+++ b/doc/TODO
@@ -3,8 +3,6 @@ list grows - I welcome patches to fix items on it!
 
 Bugs:
 
-* dh_movefiles bombs if the argument is a wildcard pattern that matches
-  nothing (reported by Drow).
 * dh_installdocs fails if debian/docs is empty except for a blank line.
   There are probably other instances of this. Debhelper should behave better
   (#24686).
@@ -13,8 +11,6 @@ Bugs:
 
 Wishlist items:
 
-* Add option to dh_compress to allow addition of files to compress besides
-  the default ones.
 * Add emacsen support to debhelper. (#21401)
 * Make dh_movefiles remove emptied directories after it's moved all the
   files out of them (#17111).