Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(155)

Unified Diff: build/install-build-deps.sh

Issue 11863012: Add unsupported option to install-build-deps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix spelling Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/install-build-deps.sh
diff --git a/build/install-build-deps.sh b/build/install-build-deps.sh
index 4d104519083fcfdd18e80763898ef754c68163d0..c891f2709da576de67628f3796bb3e3a72d2873a 100755
--- a/build/install-build-deps.sh
+++ b/build/install-build-deps.sh
@@ -31,6 +31,7 @@ do
--no-prompt) do_default=1
do_quietly="-qq --assume-yes"
;;
+ --unsupported) do_unsupported=1;;
*) usage;;
esac
shift
@@ -38,16 +39,23 @@ done
ubuntu_versions="10\.04|10\.10|11\.04|11\.10|12\.04|12\.10"
ubuntu_codenames="lucid|maverick|natty|oneiric|precise|quantal"
+ubuntu_issue="Ubuntu ($ubuntu_versions|$ubuntu_codenames)"
+# GCEL is an Ubuntu-derived VM image used on Google Compute Engine; /etc/issue
+# doesn't contain a version number so just trust that the user knows what
+# they're doing.
+gcel_issue="^GCEL"
+
+if [ 0 -eq "${do_unsupported-0}" ] ; then
+ if ! egrep -q "($ubuntu_issue|$gcel_issue)" /etc/issue; then
+ echo "ERROR: Only Ubuntu 10.04 (lucid) through 12.10 (quantal) are"\
+ "currently supported" >&2
+ exit 1
+ fi
-if ! egrep -q "Ubuntu ($ubuntu_versions|$ubuntu_codenames)" /etc/issue; then
- echo "ERROR: Only Ubuntu 10.04 (lucid) through 12.10 (quantal) are currently"\
- "supported" >&2
- exit 1
-fi
-
-if ! uname -m | egrep -q "i686|x86_64"; then
- echo "Only x86 architectures are currently supported" >&2
- exit
+ if ! uname -m | egrep -q "i686|x86_64"; then
+ echo "Only x86 architectures are currently supported" >&2
+ exit
+ fi
fi
if [ "x$(id -u)" != x0 ]; then
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698