summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMichal Marek <mmarek@suse.cz>2015-01-06 20:45:04 +0100
committerMichal Marek <mmarek@suse.cz>2015-01-06 20:45:04 +0100
commit5f73d9dcf65f623ca62ad7ff102409e1cf40b467 (patch)
tree3791fd0842e0bfd70785231a74e3b3cd1576300b /scripts
parent25417114d3fabfba7b4812758c3c73c5f1a1b570 (diff)
parentd9f711db8348233a2958cf91a19ca78677f677e0 (diff)
downloadlinux-next-5f73d9dcf65f623ca62ad7ff102409e1cf40b467.tar.gz
Merge branch 'kbuild/misc' into kbuild/for-next
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/package/builddeb13
1 files changed, 12 insertions, 1 deletions
diff --git a/scripts/package/builddeb b/scripts/package/builddeb
index 2c68c8bf6c76..88dbf23b6970 100755
--- a/scripts/package/builddeb
+++ b/scripts/package/builddeb
@@ -217,9 +217,20 @@ else
fi
maintainer="$name <$email>"
+# Try to determine distribution
+if [ -n "$KDEB_CHANGELOG_DIST" ]; then
+ distribution=$KDEB_CHANGELOG_DIST
+elif distribution=$(lsb_release -cs 2>/dev/null) && [ -n "$distribution" ]; then
+ : # nothing to do in this case
+else
+ distribution="unstable"
+ echo >&2 "Using default distribution of 'unstable' in the changelog"
+ echo >&2 "Install lsb-release or set \$KDEB_CHANGELOG_DIST explicitly"
+fi
+
# Generate a simple changelog template
cat <<EOF > debian/changelog
-linux-upstream ($packageversion) unstable; urgency=low
+linux-upstream ($packageversion) $distribution; urgency=low
* Custom built Linux kernel.