From b2f24a8d8237ef3973c9139b9c129e0947959c2d Mon Sep 17 00:00:00 2001 From: Chris Sosa Date: Thu, 11 Feb 2010 13:40:18 -0800 Subject: [PATCH] Adds ebuild support to build_autotest Review URL: http://codereview.chromium.org/604013 --- build_autotest.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/build_autotest.sh b/build_autotest.sh index 374a31c371..b16fb58e72 100755 --- a/build_autotest.sh +++ b/build_autotest.sh @@ -23,6 +23,8 @@ DEFAULT_CONTROL=client/site_tests/setup/control DEFINE_string control "${DEFAULT_CONTROL}" \ "Setup control file -- path relative to the destination autotest directory" c +DEFINE_string board "" \ + "Board name for the target you are building if using portage build system" DEFINE_string board "" \ "The board for which you are building autotest" @@ -39,6 +41,13 @@ AUTOTEST_SRC="${GCLIENT_ROOT}/src/third_party/autotest/files" # Destination in chroot to install autotest. AUTOTEST_DEST="/usr/local/autotest/${FLAGS_board}" +# If new build system flag passed, use ebuild and exit +if [ -n "${FLAGS_board}" ]; then + sudo GCLIENT_ROOT="${GCLIENT_ROOT}" FLAGS_control=${FLAGS_control} \ + "emerge-${FLAGS_board}" -a chromeos-base/autotest + exit 0 +fi + # Copy a local "installation" of autotest into the chroot, to avoid # polluting the src dir with tmp files, results, etc. update_chroot_autotest "${CHROOT_TRUNK_DIR}/src/third_party/autotest/files" \