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

Unified Diff: src/scripts/make_local_repo.sh

Issue 507005: Add ARM cross-compiler to chroot. (Closed)
Patch Set: Created 11 years 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 | « src/scripts/make_chroot.sh ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scripts/make_local_repo.sh
diff --git a/src/scripts/make_local_repo.sh b/src/scripts/make_local_repo.sh
index 11e28bba3a04b87dd2a070c20147dc971da36eab..f0cbd76f21e0731d4c4d7934d61d7805a9ec1dd8 100755
--- a/src/scripts/make_local_repo.sh
+++ b/src/scripts/make_local_repo.sh
@@ -19,6 +19,7 @@ DEFAULT_IMG_PKGLIST="$SRC_ROOT/package_repo/repo_list_image.txt"
# Command line options
DEFINE_string suite "$DEFAULT_EXT_SUITE" "Ubuntu suite to pull packages from."
DEFINE_string mirror "$DEFAULT_EXT_MIRROR" "Ubuntu repository mirror to use."
+DEFINE_string mirror2 "" "Optional Chromium repository mirror to use."
DEFINE_string dest "$DEFAULT_DEST" "Destination directory for repository."
DEFINE_string devlist "$DEFAULT_DEV_PKGLIST" \
"File listing packages to use for development."
@@ -162,19 +163,22 @@ function update_suite {
# Add packages to the suite
echo "Downloading packages..."
- for DEB in `grep -v '^#' < $PKGLIST | awk '{print $1}'`
+ grep -v '^#' < $PKGLIST | while read DEB DEB_VER DEB_PRIO DEB_SECTION DEB_PATH
do
+ [ -z "$DEB" ] && continue
echo "Adding $DEB..."
- DEB_PRIO=`cat $PKGLIST | grep '^'$DEB' ' | awk '{print $3}'`
- DEB_SECTION=`cat $PKGLIST | grep '^'$DEB' ' | awk '{print $4}'`
- DEB_PATH=`cat $PKGLIST | grep '^'$DEB' ' | awk '{print $5}'`
- DEB_FILE="$DEB_CACHE_DIR/"`basename $DEB_PATH`
+ DEB_FILE=$DEB_CACHE_DIR/${DEB_PATH##*/}
# Download the package if necessary
- if [ ! -e "$CHROOT/$DEB_FILE" ]
+ if [ ! -s "$CHROOT/$DEB_FILE" ]
then
- in_chroot wget --no-verbose "$FLAGS_mirror/${DEB_PATH}" -O "$DEB_FILE"
+ if [ -n "FLAGS_mirror2" ]; then
+ in_chroot wget --no-verbose "$FLAGS_mirror/${DEB_PATH}" -O "$DEB_FILE" || \
+ in_chroot wget --no-verbose "$FLAGS_mirror2/${DEB_PATH}" -O "$DEB_FILE"
+ else
+ in_chroot wget --no-verbose "$FLAGS_mirror/${DEB_PATH}" -O "$DEB_FILE"
+ fi
fi
# Copy the file into the target suite with the correct priority
« no previous file with comments | « src/scripts/make_chroot.sh ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698