clean old chromeos-base/chromeos-bsp-null

We are converting virtual/chromeos-bsp to a new style virtual, but we
have to clean out the old one first as it has a PROVIDE= which messes
up the upgrade process.

BUG=chromium-os:38307
TEST=`./update_chroot` uninstalled this pkg for all generic boards
CQ-DEPEND=CL:42188

Change-Id: Ie23bf462a178bf1085a4700155b779e9651ad24d
Reviewed-on: https://gerrit.chromium.org/gerrit/42528
Reviewed-by: Anush Elangovan <anush@google.com>
Commit-Queue: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
This commit is contained in:
Mike Frysinger 2013-02-04 06:57:12 -05:00 committed by ChromeBot
parent b8bd594130
commit c1fd42203b

View File

@ -0,0 +1,33 @@
# Copyright (c) 2013 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# Upgrade people to the new style generic virtual/chromeos-bsp.
opkg="chromeos-base/chromeos-bsp-null"
export CLEAN_DELAY=0
update() {
local root=$1 board=$2 emerge
if [[ -z ${board} ]]; then
board="root"
emerge="sudo -E emerge"
else
emerge="emerge-${board}"
fi
if portageq has_version ${root} ${opkg}; then
${emerge} -Cq ${opkg}
fi
}
update / &
for board_root in /build/*; do
board=${board_root##*/}
update ${board_root} ${board} &
done
wait