| OLD | NEW |
| 1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 # Common constants for build scripts | 5 # Common constants for build scripts |
| 6 # This must evaluate properly for both /bin/bash and /bin/sh | 6 # This must evaluate properly for both /bin/bash and /bin/sh |
| 7 | 7 |
| 8 # All scripts should die on error unless commands are specifically excepted | 8 # All scripts should die on error unless commands are specifically excepted |
| 9 # by prefixing with '!' or surrounded by 'set +e' / 'set -e'. | 9 # by prefixing with '!' or surrounded by 'set +e' / 'set -e'. |
| 10 # TODO: Re-enable this once shflags is less prone to dying. | 10 # TODO: Re-enable this once shflags is less prone to dying. |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 | 128 |
| 129 # Install make for portage ebuilds. Used by build_image and gmergefs. | 129 # Install make for portage ebuilds. Used by build_image and gmergefs. |
| 130 DEFAULT_INSTALL_MASK="/usr/include /usr/man /usr/share/man /usr/share/doc \ | 130 DEFAULT_INSTALL_MASK="/usr/include /usr/man /usr/share/man /usr/share/doc \ |
| 131 /usr/share/gtk-doc /usr/share/gtk-2.0 /usr/lib/gtk-2.0/include \ | 131 /usr/share/gtk-doc /usr/share/gtk-2.0 /usr/lib/gtk-2.0/include \ |
| 132 /usr/share/info /usr/share/aclocal /usr/lib/gcc /usr/lib/pkgconfig \ | 132 /usr/share/info /usr/share/aclocal /usr/lib/gcc /usr/lib/pkgconfig \ |
| 133 /usr/share/pkgconfig /usr/share/gettext /usr/share/readline /etc/runlevels \ | 133 /usr/share/pkgconfig /usr/share/gettext /usr/share/readline /etc/runlevels \ |
| 134 /usr/share/openrc /lib/rc *.a *.la /etc/init.d /usr/lib/debug | 134 /usr/share/openrc /lib/rc *.a *.la /etc/init.d /usr/lib/debug |
| 135 /usr/local/autotest /usr/local/autotest-chrome" | 135 /usr/local/autotest /usr/local/autotest-chrome" |
| 136 | 136 |
| 137 FACTORY_INSTALL_MASK="/opt/google/chrome /opt/google/o3d /opt/netscape \ | 137 FACTORY_INSTALL_MASK="/opt/google/chrome /opt/google/o3d /opt/netscape \ |
| 138 /usr/lib/dri /usr/lib/python2.6/test /usr/share/chewing /usr/share/fonts \ | 138 /opt/google/talkplugin /opt/Qualcomm /opt/Synaptics \ |
| 139 /usr/lib/dri /usr/lib/python2.6/test \ |
| 140 /usr/share/chewing /usr/share/fonts \ |
| 139 /usr/share/ibus-pinyin /usr/share/libhangul /usr/share/locale \ | 141 /usr/share/ibus-pinyin /usr/share/libhangul /usr/share/locale \ |
| 140 /usr/share/m17n /usr/share/mime /usr/share/sounds /usr/share/tts \ | 142 /usr/share/m17n /usr/share/mime /usr/share/sounds /usr/share/tts \ |
| 141 /usr/share/X11 /usr/share/zoneinfo /usr/lib/debug | 143 /usr/share/X11 /usr/share/zoneinfo /usr/lib/debug |
| 142 /usr/local/autotest /usr/local/autotest-chrome" | 144 /usr/local/autotest /usr/local/autotest-chrome" |
| 143 | 145 |
| 144 # Check to ensure not running old scripts | 146 # Check to ensure not running old scripts |
| 145 V_REVERSE='[7m' | 147 V_REVERSE='[7m' |
| 146 V_VIDOFF='[m' | 148 V_VIDOFF='[m' |
| 147 case "$(basename $0)" in | 149 case "$(basename $0)" in |
| 148 build_image.sh|build_platform_packages.sh|customize_rootfs.sh|make_chroot.sh) | 150 build_image.sh|build_platform_packages.sh|customize_rootfs.sh|make_chroot.sh) |
| (...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 451 start_time=$(date +%s) | 453 start_time=$(date +%s) |
| 452 | 454 |
| 453 # Print time elsapsed since start_time. | 455 # Print time elsapsed since start_time. |
| 454 print_time_elapsed() { | 456 print_time_elapsed() { |
| 455 end_time=$(date +%s) | 457 end_time=$(date +%s) |
| 456 elapsed_seconds="$(( $end_time - $start_time ))" | 458 elapsed_seconds="$(( $end_time - $start_time ))" |
| 457 minutes="$(( $elapsed_seconds / 60 ))" | 459 minutes="$(( $elapsed_seconds / 60 ))" |
| 458 seconds="$(( $elapsed_seconds % 60 ))" | 460 seconds="$(( $elapsed_seconds % 60 ))" |
| 459 echo "Elapsed time: ${minutes}m${seconds}s" | 461 echo "Elapsed time: ${minutes}m${seconds}s" |
| 460 } | 462 } |
| OLD | NEW |