image build and composition scripts for Flatcar Container Linux
Go to file
Gabe Black 83d8b824a3 Add some functions which will help transition to a single firmware directory.
This is the first in three stages of changes to transition from separate
"u-boot" and "coreboot" output directories to a single "firmware"
directory. This change/stage will give scripts a facility to easily be
compatible with both schemes. The second stage will transition all the
scripts to use the mechanism, and then finally the third stage will
switch the directories over. Some additional work may be needed if there
are file name clashes, although those sorts of problems would likely
already be present. These new functions could also optionally be taken back
out after the transition.

This change adds find_fw_component, find_u_boot_component, and
find_coreboot_component functions to common.sh. The first function provides
the bulk of the functionality, while the second and third wrap the first and
pass it parameters appropriate for u-boot or coreboot. The first function
accepts an override which it returns if set, and if not it checks for a file
in each of the directories it's passed in the second parameter one by one and
returns the first one it finds. If it doesn't find any it defaults to the last
one.

BUG=chromium-os:18107
TEST=Modified some u-boot related ebuilds to put some files in the firmware
directory. Ran the ebuilds and verified the files showed up where expected.
Modified the cros_write_firmware.sh script to use these new functions.  Ran
cros_write_firmware and saw it find the files in their new location.
Also verified that the firmware on the target was updated as expected.

Change-Id: Ic664e0e1c4a5b27efc9fb892ff5bd91cf1b5be56
Signed-off-by: Gabe Black <gabeblack@google.com>
Reviewed-on: http://gerrit.chromium.org/gerrit/5170
Tested-by: Gabe Black <gabeblack@chromium.org>
Reviewed-by: Doug Anderson <dianders@chromium.org>
2011-08-02 19:54:17 -07:00
bin Skip filling in kernel partition until cros_make_image_bootable 2011-08-01 16:09:00 -07:00
build_library Skip filling in kernel partition until cros_make_image_bootable 2011-08-01 16:09:00 -07:00
chroot_version_hooks.d Remove mobile-broadband-provider-info package, which has been replaced 2011-07-12 15:37:19 -07:00
lib Close fds in RunCommand to prevent children from inheriting file handles. 2011-07-25 13:31:30 -07:00
mod_for_factory_scripts mod_for_factory: remove 500populateQualDbs 2011-06-30 19:04:38 -07:00
mod_for_test_scripts [crosutils] Fix 710enableAuthTesting so it correctly creates a passwordless NSSDB 2011-07-06 15:56:40 -07:00
.gitignore ignore: tmp files and .pyc files 2010-09-09 14:25:33 -07:00
archive_build.sh Don't rm $OUTDIR during archive_build.sh. 2011-07-29 09:41:46 -07:00
archive_hwqual Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
bash_completion cros_workon: fix comments/messages to be consistent with new location 2011-02-05 11:42:19 -08:00
build_image Skip filling in kernel partition until cros_make_image_bootable 2011-08-01 16:09:00 -07:00
build_kernel_image.sh Obsolete --crosbug12352_arm_kernel_signing flag 2011-07-26 21:40:13 -07:00
build_packages Add symlinks to new build scripts. This obviates the need to run setup_source_tree.sh. 2010-02-19 14:54:50 -08:00
call_autoserv.py Added HWQual utility script - call_script.py 2011-01-27 16:19:55 -08:00
check_control_files.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
chromeos-common.sh Switch to GPT-format disk images. 2010-03-30 14:17:34 -07:00
clean_loopback_devices Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
common.sh Add some functions which will help transition to a single firmware directory. 2011-08-02 19:54:17 -07:00
cros_deps_diff add cros_deps_diff tool that creates dependency graph diffs 2010-07-08 14:52:37 -07:00
cros_download_latest_image Update cros_download_latest_image to work again. 2011-07-29 15:23:49 -07:00
cros_generate_breakpad_symbols Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
cros_generate_deps_graphs Refactor the dot graph generation out of cros_generate_deps_graphs 2010-07-01 13:41:25 -07:00
cros_run_unit_tests Remove testing utilities and fix symlinks. 2011-03-24 16:06:59 -07:00
cros_show_stacks Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
dot_helper.py Refactor the dot graph generation out of cros_generate_deps_graphs 2010-07-01 13:41:25 -07:00
enable_localaccount.sh This starts to fix the scripts so that they load from /usr/lib/crosutils 2011-02-01 22:04:49 -08:00
enter_chroot.sh chromium-os:17680 : Establish Syncer PID file invariants 2011-07-28 13:46:52 -07:00
fixup_image_for_qemu.py Use 1280x1024 resolution when running ChromeOS under qemu. 2011-03-29 06:58:17 -07:00
generate_test_report Remove testing utilities and fix symlinks. 2011-03-24 16:06:59 -07:00
get_latest_image.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
get_package_list Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
image_to_live.sh Move some dev scripts into dev/host. 2011-03-23 14:34:53 -07:00
image_to_usb.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
image_to_vm.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
make_chroot Add symlinks to new build scripts. This obviates the need to run setup_source_tree.sh. 2010-02-19 14:54:50 -08:00
make_developer_script_runner.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
make_factory_package.sh make_factory_package: support --firmware in RMA (--usbimg) mode 2011-07-31 19:28:52 -07:00
make_netboot.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
make_universal_factory_shim.sh make_universal_factory_shim: support "-m" to assign master (base) image 2011-07-14 19:03:34 -07:00
mk_memento_images.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
mod_image_for_recovery.sh Obsolete --crosbug12352_arm_kernel_signing flag 2011-07-26 21:40:13 -07:00
mod_image_for_test.sh Obsolete --crosbug12352_arm_kernel_signing flag 2011-07-26 21:40:13 -07:00
mod_test_image_for_pyauto.sh Add a new script to add pyauto to test images 2011-07-28 11:48:55 -07:00
mount_gpt_image.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
remote_access.sh remote_access.sh: fix learn_arch to return x86 instead of i686 2011-05-31 14:31:49 -07:00
run_chroot_version_hooks Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
run_remote_tests.sh Remove testing utilities and fix symlinks. 2011-03-24 16:06:59 -07:00
serve_factory_packages.py Run devserver with --factory_config. Add --start_devserver flag. 2010-11-04 12:56:02 -07:00
set_shared_user_password.sh Cleanup set_shared_user_password related transitional code. 2011-04-29 10:24:26 -07:00
setup_board Add symlinks to new build scripts. This obviates the need to run setup_source_tree.sh. 2010-02-19 14:54:50 -08:00
ssh_test.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
start_devserver Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
sysroot_wrapper Add symlinks to new build scripts. This obviates the need to run setup_source_tree.sh. 2010-02-19 14:54:50 -08:00
update_bootloaders.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
update_chroot Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
update_kernel.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
upload_symbols Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00
verify_rootfs_chksum.sh Fix/standardize exiting if common.sh can't be found 2011-07-22 12:06:59 -07:00