diff options
author | joey <joey> | 1999-08-17 05:16:26 +0000 |
---|---|---|
committer | joey <joey> | 1999-08-17 05:16:26 +0000 |
commit | 84c6650150baff1dddc4205443995d75e1c0ec08 (patch) | |
tree | 53b2be795641112aeafbdb6719b2608a4bccce86 | |
parent | db2831b1ccd9f2ecf064194724486367efcef4be (diff) | |
download | debhelper-84c6650150baff1dddc4205443995d75e1c0ec08.tar.gz |
r224: Initial Import
-rw-r--r-- | Dh_Lib.pm | 17 | ||||
-rw-r--r-- | debhelper.1 | 8 | ||||
-rw-r--r-- | debian/changelog | 10 | ||||
-rw-r--r-- | doc/PROGRAMMING | 4 | ||||
-rw-r--r-- | doc/README | 7 | ||||
-rwxr-xr-x | examples/rules | 3 | ||||
-rwxr-xr-x | examples/rules.multi | 3 |
7 files changed, 50 insertions, 2 deletions
@@ -187,14 +187,27 @@ sub dirname { my $fn=shift; return $fn; } +# Pass in a number, will return true iff the current compatability level +# is equal to that number. +sub compat { + my $num=shift; + + my $c=1; + if (defined $ENV{DH_COMPAT}) { + $c=$ENV{DH_COMPAT}; + } + + return ($c == $num); +} + # Pass it a name of a binary package, it returns the name of the tmp dir to # use, for that package. -# This is for back-compatability with the debian/tmp tradition. sub tmpdir { my $package=shift; if ($dh{TMPDIR}) { return $dh{TMPDIR}; } - elsif ($package eq $dh{MAINPACKAGE}) { + elsif (compat(1) && $package eq $dh{MAINPACKAGE}) { + # This is for back-compatability with the debian/tmp tradition. return "debian/tmp"; } else { diff --git a/debhelper.1 b/debhelper.1 index 1562b2bf..6834594a 100644 --- a/debhelper.1 +++ b/debhelper.1 @@ -120,6 +120,14 @@ Here is the complete list of available debhelper commands. .I DH_VERBOSE Enables verbose mode. .TP +.I DH_COMPAT +Specifies what compatability level debhelper should run at. The default is 1, +which makes debhelper behave in a manner compatable with the 1.x series of +debhelper. If set to 2, debhelper's behavior will change to use the new +features of the 2.x series. Use this with caution, as the 2.x series makes +major changes that will break most packages. For documentation on these +changes, read /usr/doc/debhelper/v2 +.TP .I DH_NO_ACT Enables no-act mode. .TP diff --git a/debian/changelog b/debian/changelog index b4296a04..212c1ee5 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,13 @@ +debhelper (1.9.00) unstable; urgency=low + + * This is a release of debhelper in preparation for debhelper v2. + * doc/v2: added, documented status of v2 changes. + * README: mention doc/v2 + * debhelper.1: docuimented DH_COMPAT + * examples/*: added DH_COMAPT=1 to top of rules files + + -- Joey Hess <joeyh@master.debian.org> Thu, 1 Jul 1999 13:16:41 -0700 + debhelper (1.2.83) unstable; urgency=medium * dh_perl: fixed substvars typo. Urgency medium since a lot of people will diff --git a/doc/PROGRAMMING b/doc/PROGRAMMING index 4f071496..02b11a21 100644 --- a/doc/PROGRAMMING +++ b/doc/PROGRAMMING @@ -169,6 +169,10 @@ tmpdir() name of the tmp directory that will be used as this package's package build directory. Typically, this will be "debian/tmp" or "debian/package". +compat() + Pass this command a number, and if the current compatability level + equals that number, it will return true. Looks at DH_COMPAT to get + the compatability level. pkgfile() Pass this command the name of a binary package, and the base name of a file, and it will return the actual filename to use. This is used @@ -12,6 +12,13 @@ various debhelper scripts in (though other variations are possible). For a more gentle introduction, the maint-guide debian package contains a tutorial about making your first package using Debhelper. +Debhelper v2: +------------ + +Debhelper v2 is a major new version of Debhelper, still under development. +Debhelper will continue to work in v1 compatability mode for now, if you're +interested in trying the new versiln, read the file named "v2". + Starting a new package: ---------------------- diff --git a/examples/rules b/examples/rules index 806092ca..5e805edb 100755 --- a/examples/rules +++ b/examples/rules @@ -4,6 +4,9 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 +# This is the debhelper compatability version to use. +export DH_COMPAT=1 + build: build-stamp build-stamp: dh_testdir diff --git a/examples/rules.multi b/examples/rules.multi index 433c16fe..7a609e6c 100755 --- a/examples/rules.multi +++ b/examples/rules.multi @@ -7,6 +7,9 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 +# This is the debhelper compatability version to use. +export DH_COMPAT=1 + build: build-stamp build-stamp: dh_testdir |