summaryrefslogtreecommitdiffstats
path: root/chrome/installer/linux
diff options
context:
space:
mode:
authorthestig@chromium.org <thestig@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-25 23:37:13 +0000
committerthestig@chromium.org <thestig@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-25 23:37:13 +0000
commitb830b3d7caaaf5040fb64625ee118ceb2ec9b1df (patch)
tree4e09366d650681d54c489e979da42d9b3ed95cc8 /chrome/installer/linux
parentc21ccb3ce8c7bfaa484a254db297bac3a215aa7c (diff)
downloadchromium_src-b830b3d7caaaf5040fb64625ee118ceb2ec9b1df.zip
chromium_src-b830b3d7caaaf5040fb64625ee118ceb2ec9b1df.tar.gz
chromium_src-b830b3d7caaaf5040fb64625ee118ceb2ec9b1df.tar.bz2
Linux: Check BuildSysroot command arguments in the Debian sysroot creator script.
NOTRY=true Review URL: https://codereview.chromium.org/211743004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@259398 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/installer/linux')
-rwxr-xr-xchrome/installer/linux/sysroot_scripts/sysroot-creator-debian.wheezy.sh20
1 files changed, 17 insertions, 3 deletions
diff --git a/chrome/installer/linux/sysroot_scripts/sysroot-creator-debian.wheezy.sh b/chrome/installer/linux/sysroot_scripts/sysroot-creator-debian.wheezy.sh
index 5732aac..7eabe61 100755
--- a/chrome/installer/linux/sysroot_scripts/sysroot-creator-debian.wheezy.sh
+++ b/chrome/installer/linux/sysroot_scripts/sysroot-creator-debian.wheezy.sh
@@ -31,7 +31,7 @@ readonly REQUIRED_TOOLS="wget"
# Package Config
######################################################################
-# this is where we get all the debian packages from
+# This is where we get all the debian packages from.
readonly DEBIAN_REPO=http://http.us.debian.org/debian
readonly REPO_BASEDIR="${DEBIAN_REPO}/dists/wheezy"
@@ -321,6 +321,18 @@ CreateTarBall() {
tar zcf ${tarball} -C ${INSTALL_ROOT} .
}
+CheckBuildSysrootArgs() {
+ if [ "$#" -ne "1" ]; then
+ echo "ERROR: BuildSysroot commands only take 1 argument"
+ exit 1
+ fi
+
+ if [ -z "$1" ]; then
+ echo "ERROR: tarball name required"
+ exit 1
+ fi
+}
+
######################################################################
#
######################################################################
@@ -439,11 +451,12 @@ CleanupJailSymlinks() {
#@
#@ Build everything and package it
BuildSysrootAmd64() {
+ CheckBuildSysrootArgs $@
ClearInstallDir
InstallIntoSysroot ${DEBIAN_DEP_FILES_AMD64}
CleanupJailSymlinks
HacksAndPatchesAmd64
- CreateTarBall $1
+ CreateTarBall "$1"
}
#@
@@ -451,11 +464,12 @@ BuildSysrootAmd64() {
#@
#@ Build everything and package it
BuildSysrootI386() {
+ CheckBuildSysrootArgs $@
ClearInstallDir
InstallIntoSysroot ${DEBIAN_DEP_FILES_I386}
CleanupJailSymlinks
HacksAndPatchesI386
- CreateTarBall $1
+ CreateTarBall "$1"
}
#