r9186 - /packages/trunk/doc-debian/doc/source-unpack.txt
Date: Sat Apr 14 10:17:25 2012
New Revision: 9186
Apply patch provided by Colin Watson to improve the document.
This patch documents all formats currently in use in the Debian archive.
This patch includes a pointer to dpkg-source manpage.
--- packages/trunk/doc-debian/doc/source-unpack.txt (original)
+++ packages/trunk/doc-debian/doc/source-unpack.txt Sat Apr 14 10:17:25 2012
@@ -1,33 +1,68 @@
HOW TO UNPACK A DEBIAN SOURCE PACKAGE
-There are two kinds of Debian source packages: old ones and new ones.
+If you have `dpkg-source', you can use it to unpack any Debian source
+package: put all the files in the same directory and type `dpkg-source
+-x <whatever>.dsc'. The remainder of this document explains how to
+unpack Debian source packages on non-Debian systems, or on Debian
+systems without the `dpkg-dev' package installed.
-A. Old ones look like this:
- You unpack them by untarring the .tar.gz. There is NO need to apply
- the diff.
+There are several kinds of Debian source packages, identified by the
+Format: field in the .dsc file. If there is no Format: field, treat
+it as "1.0".
-B. New ones look like this:
+"1.0" packages can be either native or non-native. Native packages
+(where the Debian source is the upstream source) look like this:
+To unpack this kind of package, just untar the .tar.gz file.
+Non-native "1.0" packages look like this:
- hello_1.3-11.orig.tar.gz - note the `.orig' part
- Here you MUST use dpkg-source or apply the diff manually - see below.
+ hello_1.3.orig.tar.gz - note the `.orig' part
- If you have `dpkg-source' you should put the files in the same
- directory and type `dpkg-source -x <whatever>.dsc'.
- If you do not you can extract the Debian source as follows:
1. untar P_V.orig.tar.gz.
2. rename the resulting P-V.orig directory to P-V. If some other
directory results, rename *it* to P-V.
3. mkdir P-V/debian.
4. apply the diff with patch -p0.
5. do `chmod +x P-V/debian/rules'
- (where P is the package name and V the version.)
+ (where P is the package name and V the upstream version - `hello' and
+ `1.3' respectively in this example.)
-C. There are some packages where the Debian source is the upstream
- source. In this case there will be no .diff.gz and you can just use
- the .tar.gz. If a .dsc is provided you can use `dpkg-source -x'.
+"3.0 (native)" packages are the same as native "1.0" packages, except
+that the source tarball may be compressed using methods other than
+"3.0 (quilt)" packages look like this:
+ (optional, for one or more values of COMPONENT)
+The compressed files may be compressed using methods other than gzip.
+To unpack this kind of package, you will need to install `quilt'
+ 1. untar P_V.orig.tar.gz.
+ 2. rename the resulting P-V.orig directory to P-V. If some other
+ directory results, rename *it* to P-V.
+ 3. if there are any orig-COMPONENT tarballs, untar each of them to
+ 4. remove P-V/debian if it exists.
+ 5. change to the P-V directory.
+ 6. untar P_V-R.debian.tar.gz; it will unpack to a `debian'
+ 7. run `QUILT_PATCHES=debian/patches quilt push -a'.
+ (where P is the package name, V the upstream version, and R the
+ Debian revision - `hello', `1.3', and `11' in this example.)
+See the dpkg-source(1) manual page for full details of all formats,
+including experimental ones.
-- Ian Jackson <firstname.lastname@example.org> Sat, 31 Aug 1996
+ -- Colin Watson <email@example.com> Sun, 17 Oct 2010