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

Side by Side Diff: src/scripts/make_chroot.sh

Issue 542079: build: Add gnupg and x11-utils to prod package list. (Closed)
Patch Set: make package-installing scripts support end-of-line comments Created 10 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 unified diff | Download patch
« no previous file with comments | « src/scripts/install_packages.sh ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 2
3 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. 3 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 # This script sets up an Ubuntu chroot environment. The ideas come 7 # This script sets up an Ubuntu chroot environment. The ideas come
8 # from https://wiki.ubuntu.com/DebootstrapChroot and conversations with 8 # from https://wiki.ubuntu.com/DebootstrapChroot and conversations with
9 # tedbo. The script is passed the path to an empty folder, which will be 9 # tedbo. The script is passed the path to an empty folder, which will be
10 # populated with the files to form an Ubuntu Jaunty system with the packages 10 # populated with the files to form an Ubuntu Jaunty system with the packages
(...skipping 27 matching lines...) Expand all
38 38
39 # Parse command line flags 39 # Parse command line flags
40 FLAGS "$@" || exit 1 40 FLAGS "$@" || exit 1
41 eval set -- "${FLAGS_ARGV}" 41 eval set -- "${FLAGS_ARGV}"
42 42
43 # Only now can we die on error. shflags functions leak non-zero error codes, 43 # Only now can we die on error. shflags functions leak non-zero error codes,
44 # so will die prematurely if 'set -e' is specified before now. 44 # so will die prematurely if 'set -e' is specified before now.
45 # TODO: replace shflags with something less error-prone, or contribute a fix. 45 # TODO: replace shflags with something less error-prone, or contribute a fix.
46 set -e 46 set -e
47 47
48 COMPONENTS=`cat $FLAGS_pkglist | grep -v ' *#' | grep -v '^ *$' | tr '\n' ' '` 48 COMPONENTS=`cat $FLAGS_pkglist | sed -e 's/#.*//' | grep -v '^ *$' | tr '\n' ' ' `
49 FULLNAME="Chrome OS dev user" 49 FULLNAME="Chrome OS dev user"
50 DEFGROUPS="eng,admin,adm,dialout,cdrom,floppy,audio,dip,video" 50 DEFGROUPS="eng,admin,adm,dialout,cdrom,floppy,audio,dip,video"
51 PASSWORD=chronos 51 PASSWORD=chronos
52 CRYPTED_PASSWD=$(perl -e 'print crypt($ARGV[0], "foo")', $PASSWORD) 52 CRYPTED_PASSWD=$(perl -e 'print crypt($ARGV[0], "foo")', $PASSWORD)
53 53
54 function in_chroot { 54 function in_chroot {
55 sudo chroot "$FLAGS_chroot" "$@" 55 sudo chroot "$FLAGS_chroot" "$@"
56 } 56 }
57 57
58 function bash_chroot { 58 function bash_chroot {
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 CHROOT_EXAMPLE_OPT="--chroot=$FLAGS_chroot" 206 CHROOT_EXAMPLE_OPT="--chroot=$FLAGS_chroot"
207 fi 207 fi
208 208
209 echo "All set up. To enter the chroot, run:" 209 echo "All set up. To enter the chroot, run:"
210 echo " $SCRIPTS_DIR/enter_chroot.sh $CHROOT_EXAMPLE_OPT" 210 echo " $SCRIPTS_DIR/enter_chroot.sh $CHROOT_EXAMPLE_OPT"
211 echo "" 211 echo ""
212 echo "CAUTION: Do *NOT* rm -rf the chroot directory; if there are stale bind" 212 echo "CAUTION: Do *NOT* rm -rf the chroot directory; if there are stale bind"
213 echo "mounts you may end up deleting your source tree too. To unmount and" 213 echo "mounts you may end up deleting your source tree too. To unmount and"
214 echo "delete the chroot cleanly, use:" 214 echo "delete the chroot cleanly, use:"
215 echo " $0 --delete $CHROOT_EXAMPLE_OPT" 215 echo " $0 --delete $CHROOT_EXAMPLE_OPT"
OLDNEW
« no previous file with comments | « src/scripts/install_packages.sh ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698