Add HWID bundle into buildbot output

Add bundle to factory_shim/hwid

BUG=chromium-os:16734
TEST=archive_build, with and without hwid present

Change-Id: I70eeca5ce9cd99d229081a92af5bc0c3c997dce7
Reviewed-on: http://gerrit.chromium.org/gerrit/5189
Reviewed-by: Rong Chang <rongchang@chromium.org>
Tested-by: Nick Sanders <nsanders@chromium.org>
This commit is contained in:
Nick Sanders 2011-08-02 03:42:04 -07:00
parent 83d8b824a3
commit daebdee972
2 changed files with 19 additions and 4 deletions

View File

@ -236,7 +236,7 @@ fi
# Zip the build # Zip the build
echo "Compressing and archiving build..." echo "Compressing and archiving build..."
cd "$FLAGS_from" cd "$FLAGS_from"
MANIFEST=`ls | grep -v factory | grep -v netboot` MANIFEST=`ls | grep -v factory | grep -v netboot | grep -v hwid`
rm -f "${ZIPFILE}" rm -f "${ZIPFILE}"
zip -r "${ZIPFILE}" ${MANIFEST} zip -r "${ZIPFILE}" ${MANIFEST}
@ -256,8 +256,8 @@ if [ $FLAGS_factory_test_mod -eq $FLAGS_TRUE ] || \
# throughout the build scripts rather than explicitly specifying an image. # throughout the build scripts rather than explicitly specifying an image.
touch "${IMG_DIR}" touch "${IMG_DIR}"
[ -n "${IMG_DIR}" ] && rm -f latest && ln -s "${IMG_DIR}" latest [ -n "${IMG_DIR}" ] && rm -f latest && ln -s "${IMG_DIR}" latest
FACTORY_MANIFEST=`find factory_shim factory_test -follow \ FACTORY_MANIFEST=$(find factory_shim factory_test -follow -type f |
-type f | grep -E "(factory_image|factory_install|partition|netboot)"` grep -E "(factory_image|factory_install|partition|netboot|hwid)")
rm -f "${FACTORY_ZIPFILE}" rm -f "${FACTORY_ZIPFILE}"
zip "${FACTORY_ZIPFILE}" ${FACTORY_MANIFEST} zip "${FACTORY_ZIPFILE}" ${FACTORY_MANIFEST}
echo "Zipped" echo "Zipped"

View File

@ -80,9 +80,24 @@ if [ -r "${SYSROOT}/u-boot/legacy_image.bin" ]; then
cp "${SYSROOT}/u-boot/legacy_image.bin" "netboot" cp "${SYSROOT}/u-boot/legacy_image.bin" "netboot"
cp "${GCLIENT_ROOT}/chroot/usr/bin/update_firmware_vars.py" "netboot" cp "${GCLIENT_ROOT}/chroot/usr/bin/update_firmware_vars.py" "netboot"
else else
echo "Skipping: ${SYSROOT}/u-boot/legacy_image.bin firmware not present?" echo "Skipping legacy fw: ${SYSROOT}/u-boot/legacy_image.bin not present?"
fi fi
# Get HWID bundle if available.
hwid_dir="usr/share/chromeos-hwid"
sudo rm -rf hwid
mkdir -p hwid
if updater_files=$(ls "${SYSROOT}/${hwid_dir}/" | grep updater_); then
echo "Copying HWID bundles: $updater_files"
for file in $updater_files; do
cp "${SYSROOT}/${hwid_dir}/${file}" "hwid/"
done
else
echo "Skipping HWID: ${SYSROOT}/${hwid_dir}/" \
"does not contain updater"
fi
# Prepare to mount rootfs. # Prepare to mount rootfs.
umount_loop() { umount_loop() {
sudo umount r || true sudo umount r || true