[PATCH Precise SRU V2] UBUNTU: [Debian] Improve tools version message

Tim Gardner tim.gardner at canonical.com
Wed Dec 4 17:21:48 UTC 2013


BugLink: http://bugs.launchpad.net/bugs/1257715

Signed-off-by: Tim Gardner <tim.gardner at canonical.com>
---
 debian/tools/generic |   21 ++++++++++++++++++++-
 1 file changed, 20 insertions(+), 1 deletion(-)

diff --git a/debian/tools/generic b/debian/tools/generic
index 4aa5649..870e4cb 100644
--- a/debian/tools/generic
+++ b/debian/tools/generic
@@ -24,7 +24,26 @@ if [ -d "/usr/lib/linux-tools/$full_version" ]; then
 	exit 2
 fi
 
+case `uname -r` in
+	3.2.0-*) mpackage="linux-tools"
+		case `uname -a` in
+			*generic*) mflavour="-generic" ;;
+			*virtual*) mflavour="-virtual" ;;
+			*) echo "Unknown kernel flavour. Are you running an Ubuntu kernel ?" >&2
+				exit 2
+			;;
+		esac
+		;;
+	3.5.0-*) mpackage="linux-tools-lts-quantal" ;;
+	3.8.0-*) mpackage="linux-tools-lts-raring" ;;
+	3.11.0-*) mpackage="linux-tools-lts-saucy" ;;
+	3.13.0-*) mpackage="linux-tools-lts-trusty" ;;
+	*)	echo "This does not appear to be an Ubuntu kernel"  >&2
+		exit 2
+		;;
+esac
+		
 # Give them a hint as to what to install.
 echo "`basename $0` not found for kernel $version" >&2
-echo "You may need to install linux-tools-$version-$flavour" >&2
+echo "You may need to install $mpackage$mflavour" >&2
 exit 2
-- 
1.7.9.5





More information about the kernel-team mailing list