OLD | NEW |
1 #!/bin/bash | 1 #!/bin/bash |
2 | 2 |
3 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 # Script to modify a keyfob-based chromeos system image for testability. | 7 # Script to modify a keyfob-based chromeos system image for testability. |
8 | 8 |
9 # --- BEGIN COMMON.SH BOILERPLATE --- | 9 # --- BEGIN COMMON.SH BOILERPLATE --- |
10 # Load common CrOS utilities. Inside the chroot this file is installed in | 10 # Load common CrOS utilities. Inside the chroot this file is installed in |
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 install_autotest | 228 install_autotest |
229 | 229 |
230 MOD_FACTORY_ROOT="${GCLIENT_ROOT}/src/scripts/mod_for_factory_scripts" | 230 MOD_FACTORY_ROOT="${GCLIENT_ROOT}/src/scripts/mod_for_factory_scripts" |
231 # Run factory setup script to modify the image | 231 # Run factory setup script to modify the image |
232 sudo GCLIENT_ROOT="${GCLIENT_ROOT}" ROOT_FS_DIR="${ROOT_FS_DIR}" \ | 232 sudo GCLIENT_ROOT="${GCLIENT_ROOT}" ROOT_FS_DIR="${ROOT_FS_DIR}" \ |
233 QUALDB="${FLAGS_qualdb}" BOARD=${FLAGS_board} \ | 233 QUALDB="${FLAGS_qualdb}" BOARD=${FLAGS_board} \ |
234 "${MOD_FACTORY_ROOT}/factory_setup.sh" | 234 "${MOD_FACTORY_ROOT}/factory_setup.sh" |
235 fi | 235 fi |
236 fi | 236 fi |
237 | 237 |
| 238 # Re-run ldconfig to fix /etc/ldconfig.so.cache. |
| 239 sudo /sbin/ldconfig -r "${ROOT_FS_DIR}" |
| 240 |
238 # Let's have a look at the image just in case.. | 241 # Let's have a look at the image just in case.. |
239 if [ "${VERIFY}" = "true" ]; then | 242 if [ "${VERIFY}" = "true" ]; then |
240 pushd "${ROOT_FS_DIR}" | 243 pushd "${ROOT_FS_DIR}" |
241 bash | 244 bash |
242 popd | 245 popd |
243 fi | 246 fi |
244 | 247 |
245 cleanup | 248 cleanup |
246 | 249 |
247 # Now make it bootable with the flags from build_image | 250 # Now make it bootable with the flags from build_image |
248 "${SCRIPTS_DIR}/bin/cros_make_image_bootable" "$(dirname "${FLAGS_image}")" \ | 251 "${SCRIPTS_DIR}/bin/cros_make_image_bootable" "$(dirname "${FLAGS_image}")" \ |
249 $(basename "${FLAGS_image}") | 252 $(basename "${FLAGS_image}") |
250 | 253 |
251 print_time_elapsed | 254 print_time_elapsed |
252 | 255 |
253 trap - EXIT | 256 trap - EXIT |
254 | 257 |
OLD | NEW |