Przeglądaj źródła

dpkg (1.3.12) unstable; urgency=medium

  * dpkg prints old version number when upgrading.
  * dpkg-deb tries to detect and flag corruption by ASCII download.

  * dpkg-genchanges and dpkg-buildpackage say what source is included.

  * dpkg-buildpackage passes +clearsig=on to PGP (or pgpcommand).

  * dpkg-source prints better error for cpio not honouring -0t.
  * control file Suggests cpio >= 2.4.2, rather than just cpio.

 -- Ian Jackson <ian@chiark.chu.cam.ac.uk>  Fri, 30 Aug 1996 15:31:51 +0100
Ian Jackson 30 lat temu
rodzic
commit
0ddabc1c51

+ 14 - 0
debian/changelog

@@ -1,3 +1,17 @@
+dpkg (1.3.12) unstable; urgency=medium
+
+  * dpkg prints old version number when upgrading.
+  * dpkg-deb tries to detect and flag corruption by ASCII download.
+
+  * dpkg-genchanges and dpkg-buildpackage say what source is included.
+
+  * dpkg-buildpackage passes +clearsig=on to PGP (or pgpcommand).
+
+  * dpkg-source prints better error for cpio not honouring -0t.
+  * control file Suggests cpio >= 2.4.2, rather than just cpio.
+
+ -- Ian Jackson <ian@chiark.chu.cam.ac.uk>  Fri, 30 Aug 1996 15:31:51 +0100
+
 dpkg (1.3.11) unstable; urgency=low
 
   * EBUSY when dpkg removes a directory is only a warning.

+ 1 - 1
debian/control

@@ -8,7 +8,7 @@ Package: dpkg
 Architecture: any
 Essential: yes
 Pre-Depends: ${shlibs:Pre-Depends}
-Suggests: cpio, patch
+Suggests: cpio (>= 2.4.2-2), patch
 Conflicts: dpkgname
 Replaces: dpkgname
 Description: Package maintenance system for Debian Linux

+ 1 - 1
doc/manuals-version

@@ -1,2 +1,2 @@
 <!entity manuals-version "2.0.0.0">
-<!entity dpkg-version "1.3.10">
+<!entity dpkg-version "1.3.12">

+ 9 - 0
dpkg-deb/extract.c

@@ -197,7 +197,16 @@ void extracthalf(const char *debar, const char *directory,
       readfail(ar,debar,"ctrlarea");
 
   } else {
+    
+    if (!strncmp(versionbuf,"!<arch>",7)) {
+      if (fprintf(stderr, BACKEND
+                  ": file looks like it might be an archive which has been\n"
+                  BACKEND ":    corrupted by being downloaded in ASCII mode\n")
+          == EOF) werr("stderr");
+    }
+
     ohshit("`%.255s' is not a debian format archive",debar);
+
   }
 
   fflush(ar);

+ 4 - 1
main/processarc.c

@@ -282,7 +282,10 @@ void process_archive(const char *filename) {
   filesdbinit();
   
   if (pkg->status != stat_notinstalled && pkg->status != stat_configfiles)
-    printf("Preparing to replace %s (using %s) ...\n",pkg->name,pfilename);
+    printf("Preparing to replace %s %s (using %s) ...\n",
+           pkg->name,
+           versiondescribe(&pkg->installed.version,vdew_nonambig),
+           pfilename);
   else
     printf("Unpacking %s (from %s) ...\n",pkg->name,pfilename);
 

+ 35 - 10
scripts/dpkg-buildpackage.sh

@@ -30,8 +30,8 @@ END
 
 rootcommand=''
 pgpcommand=pgp
-signsource=signfile
-signchanges=signfile
+signsource='withecho signfile'
+signchanges='withecho signfile'
 binarytarget=binary
 sourcestyle=''
 version=''
@@ -80,23 +80,48 @@ pv="${package}_${version}"
 pva="${package}_${version}_${arch}"
 
 signfile () {
-	$pgpcommand -fast <"../$1" >"../$1.asc"
+	$pgpcommand +clearsig=on -fast <"../$1" >"../$1.asc"
+	echo
 	mv -- "../$1.asc" "../$1"
 }
 
+withecho () {
+        echo " $@" >&2
+	"$@"
+}
+
 set -- $binaryonly
 if [ -n "$maint"	]; then set -- "$@" "-m$maint"		; fi
 if [ -n "$version"	]; then set -- "$@" "-v$version"	; fi
 if [ -n "$desc"		]; then set -- "$@" "-C$desc"		; fi
 
-set -x
-
-$rootcommand debian/rules clean
+withecho $rootcommand debian/rules clean
 if [ x$binaryonly = x ]; then
-	cd ..; dpkg-source -b "$dirn"; cd "$dirn"
+	cd ..; withecho dpkg-source -b "$dirn"; cd "$dirn"
 fi
-debian/rules build
-$rootcommand debian/rules $binarytarget
+withecho debian/rules build
+withecho $rootcommand debian/rules $binarytarget
 $signsource "$pv.dsc"
-dpkg-genchanges $binaryonly $sourcestyle >../"$pva.changes"
+chg=../"$pva.changes"
+withecho dpkg-genchanges $binaryonly $sourcestyle >"$chg"
+
+fileomitted () {
+	set +e
+	test -z "`sed -n '/^Files:/,/^[^ ]/ s/'$1'$//p' <$chg`"
+	fir=$?
+	set -e
+	return $fir
+}	
+
+if fileomitted '\.dsc'; then
+	srcmsg='no source included in upload'
+elif fileomitted '\.diff\.gz'; then
+	srcmsg='Debian-specific package; upload is full source'
+elif fileomitted '\.orig\.tar\.gz'; then
+	srcmsg='diff-only upload (original source NOT included)'
+else
+	srcmsg='full upload (original source is included)'
+fi
+
 $signchanges "$pva.changes"
+echo "dpkg-buildpackage: $srcmsg"

+ 12 - 0
scripts/dpkg-genchanges.pl

@@ -9,6 +9,7 @@ $fileslistfile= 'debian/files';
 $varlistfile= 'debian/substvars';
 $uploadfilesdir= '..';
 $sourcestyle= 'i';
+$quiet= 0;
 
 use POSIX;
 use POSIX qw(:errno_h :signal_h);
@@ -35,6 +36,7 @@ Options:  -b or -B (identical)   binary-only build - no source files
           -si (default)          src includes orig for debian-revision 0 or 1
           -sa                    source includes orig src
           -sd                    source is diff and .dsc only
+          -q                     quiet - no informational messages on stderr
           -F<changelogformat>    force change log format
           -V<name>=<value>       set a substitution variable
           -T<varlistfile>        read variables here, not debian/substvars
@@ -54,6 +56,8 @@ while (@ARGV) {
         $binaryonly= 1;
     } elsif (m/^-s([iad])$/) {
         $sourcestyle= $1;
+    } elsif (m/^-q$/) {
+        $quiet= 1;
     } elsif (m/^-c/) {
         $controlfile= $';
     } elsif (m/^-l/) {
@@ -215,10 +219,18 @@ if (!$binaryonly) {
     if (($sourcestyle =~ m/i/ && $version !~ m/-[01]$/ ||
          $sourcestyle =~ m/d/) &&
         grep(m/\.diff\.gz$/,@sourcefiles)) {
+        $origsrcmsg= "not including original source code in upload";
         @sourcefiles= grep(!m/\.orig\.tar\.gz$/,@sourcefiles);
+    } else {
+        $origsrcmsg= "including full source code in upload";
     }
+} else {
+    $origsrcmsg= "binary-only upload - not including any source code";
 }
 
+print(STDERR "$progname: $origsrcmsg\n") ||
+    &syserr("write original source message") unless $quiet;
+
 $f{'Format'}= $substvar{'Format'};
 
 if (!length($f{'Date'})) {

+ 8 - 0
scripts/dpkg-source.1

@@ -473,6 +473,14 @@ needs to find these files so that it can include their sizes and
 checksums in the
 .B .changes
 file).
+.TP
+.B -q
+Usually
+.B dpkg-genchanges
+will produce informative messages on standard error, for example about
+how many of the package's source files are being uploaded.
+.B -q
+suppresses these messages.
 .SH DPKG-BUILDPACKAGE OPTIONS
 .B dpkg-buildpackage
 does not take any non-option arguments.

+ 10 - 3
scripts/dpkg-source.pl

@@ -666,9 +666,16 @@ sub checktarsane {
   file:
     while (defined($fn= <CPIO>)) {
         $fn =~ s/\0$//; $pname= $fn; $pname =~ y/ -~/?/c;
-        $fn =~ m/\n/ &&
-            &error("tarfile \`$tarfileread' contains object with".
-                   " newline in its name ($pname)");
+        if ($fn =~ m/\n/) {
+            if (!@filesinarchive) {
+                &error("first output from cpio -0t (from \`$tarfileread') ".
+                       "contains newline - you probably have an out of ".
+                       "date version of cpio.  2.4.2-2 is known to work");
+            } else {
+                &error("tarfile \`$tarfileread' contains object with".
+                       " newline in its name ($pname)");
+            }
+        }
         $slash= substr($fn,length($epfx),1);
         (($slash eq '/' || $slash eq '') &&
          substr($fn,0,length($epfx)) eq $epfx) ||

+ 1 - 1
version.h

@@ -1 +1 @@
-#define DPKG_VERSION "1.3.10" /* This line modified by Makefile */
+#define DPKG_VERSION "1.3.12" /* This line modified by Makefile */