kbuild, deb-pkg: allow to specify a custom revision for .deb packages
authorFrans Pop <elendil@planet.nl>
Wed, 22 Apr 2009 23:09:44 +0000 (01:09 +0200)
committerSam Ravnborg <sam@ravnborg.org>
Tue, 9 Jun 2009 20:37:37 +0000 (22:37 +0200)
Allow to specify a custom revision for the generated .deb by
exporting the environment variable KDEB_PKGVERSION.

Signed-off-by: Frans Pop <elendil@planet.nl>
Acked-by: maximilian attems <max@stro.at>
Cc: Andres Salomon <dilinger@debian.org>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
scripts/package/builddeb

index 5eecbbe5811458ca28390953d6eb5e4cff13a785..5868c0f2e613326fabae956ce6dbb4e84564d144 100644 (file)
@@ -26,6 +26,11 @@ create_package() {
 # Some variables and settings used throughout the script
 version=$KERNELRELEASE
 revision=$(cat .version)
+if [ -n "$KDEB_PKGVERSION" ]; then
+       packageversion=$KDEB_PKGVERSION
+else
+       packageversion=$version-$revision
+fi
 tmpdir="$objtree/debian/tmp"
 fwdir="$objtree/debian/fwtmp"
 packagename=linux-$version
@@ -87,7 +92,7 @@ done
 name="Kernel Compiler <$(id -nu)@$(hostname -f)>"
 # Generate a simple changelog template
 cat <<EOF > debian/changelog
-linux ($version-$revision) unstable; urgency=low
+linux ($packageversion) unstable; urgency=low
 
   * A standard release