| Index: src/scripts/common.sh
|
| diff --git a/src/scripts/common.sh b/src/scripts/common.sh
|
| index 25dee4a3ed6c634b6d287689e539a83ea97db76a..9e38538ca478495a555aeb5d5c160a079ec5dcf1 100644
|
| --- a/src/scripts/common.sh
|
| +++ b/src/scripts/common.sh
|
| @@ -31,7 +31,7 @@ then
|
| # Using bash, so we can find ourselves
|
| GCLIENT_ROOT="$(dirname "$BASH_SOURCE")/../.."
|
| else
|
| - # Using dash or sh, we don't know where we are. $0 refers to the calling
|
| + # Using dash or sh, we don't know where we are. $0 refers to the calling
|
| # script, not ourselves, so that doesn't help us.
|
| echo "Unable to determine location for common.sh. If you are sourcing"
|
| echo "common.sh from a script run via dash or sh, you must do it in the"
|
| @@ -45,9 +45,9 @@ fi
|
|
|
| # Canonicalize the directories for the root dir and the calling script.
|
| # readlink is part of coreutils and should be present even in a bare chroot.
|
| -# This is better than just using
|
| +# This is better than just using
|
| # FOO = "$(cd $FOO ; pwd)"
|
| -# since that leaves symbolic links intact.
|
| +# since that leaves symbolic links intact.
|
| # Note that 'realpath' is equivalent to 'readlink -f'.
|
| TOP_SCRIPT_DIR=`readlink -f $TOP_SCRIPT_DIR`
|
| GCLIENT_ROOT=`readlink -f $GCLIENT_ROOT`
|
| @@ -75,7 +75,11 @@ then
|
| fi
|
|
|
| # Load shflags
|
| -. "$SRC_ROOT/third_party/shflags/files/src/shflags"
|
| +if [ -f "${TOP_SCRIPT_DIR}/shflags" ]; then
|
| + . shflags
|
| +else
|
| + . "$SRC_ROOT/third_party/shflags/files/src/shflags"
|
| +fi
|
|
|
| # Mirrors and build suites come in 3 flavors
|
| # EXT - external source used to build local package repository
|
| @@ -120,7 +124,7 @@ function make_pkg_common {
|
| PKG_BASE=${1:?}
|
| shift
|
| set +e
|
| -
|
| +
|
| # All packages are built in the chroot
|
| assert_inside_chroot
|
|
|
|
|