Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(522)

Side by Side Diff: create_legacy_bootloader_templates.sh

Issue 3043011: build_image, build_kernel_image, update_bootloaders: fix up rootfs_verification (Closed) Base URL: http://src.chromium.org/git/crosutils.git
Patch Set: quick comment fix Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « build_kernel_image.sh ('k') | update_bootloaders.sh » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 2
3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 3 # Copyright (c) 2010 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 # Helper script that generates the signed kernel image 7 # Helper script that generates the signed kernel image
8 8
9 . "$(dirname "$0")/common.sh" 9 . "$(dirname "$0")/common.sh"
10 10
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 92
93 # chromeos-hd.A / chromeos-vhd.A 93 # chromeos-hd.A / chromeos-vhd.A
94 include /syslinux/root.A.cfg 94 include /syslinux/root.A.cfg
95 95
96 # chromeos-hd.B / chromeos-vhd.B 96 # chromeos-hd.B / chromeos-vhd.B
97 include /syslinux/root.B.cfg 97 include /syslinux/root.B.cfg
98 EOF 98 EOF
99 info "Emitted ${SYSLINUX_DIR}/syslinux.cfg" 99 info "Emitted ${SYSLINUX_DIR}/syslinux.cfg"
100 100
101 if [[ ${FLAGS_enable_rootfs_verification} -eq ${FLAGS_TRUE} ]]; then 101 if [[ ${FLAGS_enable_rootfs_verification} -eq ${FLAGS_TRUE} ]]; then
102 # To change the active target, only this file needs to change. 102 # TODO(wad, tgao) enable usb vbooting with initramfs or device probing.
103 cat <<EOF | sudo dd of="${SYSLINUX_DIR}/default.cfg" 2>/dev/null 103 warn "USB booting will not use rootfs verification."
104 DEFAULT chromeos-vusb.A 104 fi
105 EOF 105 # To change the active target, only this file needs to change.
106 else 106 cat <<EOF | sudo dd of="${SYSLINUX_DIR}/default.cfg" 2>/dev/null
107 cat <<EOF | sudo dd of="${SYSLINUX_DIR}/default.cfg" 2>/dev/null
108 DEFAULT chromeos-usb.A 107 DEFAULT chromeos-usb.A
109 EOF 108 EOF
110 fi
111 info "Emitted ${SYSLINUX_DIR}/default.cfg" 109 info "Emitted ${SYSLINUX_DIR}/default.cfg"
112 110
113 cat <<EOF | sudo dd of="${SYSLINUX_DIR}/usb.A.cfg" 2>/dev/null 111 cat <<EOF | sudo dd of="${SYSLINUX_DIR}/usb.A.cfg" 2>/dev/null
114 label chromeos-usb.A 112 label chromeos-usb.A
115 menu label chromeos-usb.A 113 menu label chromeos-usb.A
116 kernel vmlinuz.A 114 kernel vmlinuz.A
117 append ${common_args} root=${FLAGS_usb_disk} i915.modeset=1 cros_legacy 115 append ${common_args} root=${FLAGS_usb_disk} i915.modeset=1 cros_legacy
118 116
119 label chromeos-vusb.A 117 label chromeos-vusb.A
120 menu label chromeos-vusb.A 118 menu label chromeos-vusb.A
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 EOF 193 EOF
196 if [[ ${FLAGS_enable_rootfs_verification} -eq ${FLAGS_TRUE} ]]; then 194 if [[ ${FLAGS_enable_rootfs_verification} -eq ${FLAGS_TRUE} ]]; then
197 sudo sed -i -e 's/^set default=.*/set default=2/' \ 195 sudo sed -i -e 's/^set default=.*/set default=2/' \
198 "${FLAGS_to}/efi/boot/grub.cfg" 196 "${FLAGS_to}/efi/boot/grub.cfg"
199 fi 197 fi
200 info "Emitted ${FLAGS_to}/efi/boot/grub.cfg" 198 info "Emitted ${FLAGS_to}/efi/boot/grub.cfg"
201 exit 0 199 exit 0
202 fi 200 fi
203 201
204 info "The target platform does not use bootloader templates." 202 info "The target platform does not use bootloader templates."
OLDNEW
« no previous file with comments | « build_kernel_image.sh ('k') | update_bootloaders.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698