grub2: enable EFI for armvirt
[openwrt/openwrt.git] / config / Config-images.in
1 # SPDX-License-Identifier: GPL-2.0-only
2 #
3 # Copyright (C) 2006-2013 OpenWrt.org
4
5 menu "Target Images"
6
7 menuconfig TARGET_ROOTFS_INITRAMFS
8 bool "ramdisk"
9 default y if USES_INITRAMFS
10 help
11 Embed the root filesystem into the kernel (initramfs).
12
13 choice
14 prompt "Compression"
15 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_apm821xx
16 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_ath79_mikrotik
17 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_lantiq
18 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_mpc85xx
19 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_ramips
20 default TARGET_INITRAMFS_COMPRESSION_ZSTD if TARGET_ipq807x
21 default TARGET_INITRAMFS_COMPRESSION_XZ if USES_SEPARATE_INITRAMFS
22 default TARGET_INITRAMFS_COMPRESSION_NONE
23 depends on TARGET_ROOTFS_INITRAMFS
24 help
25 Select ramdisk compression.
26
27 config TARGET_INITRAMFS_COMPRESSION_NONE
28 bool "none"
29
30 config TARGET_INITRAMFS_COMPRESSION_GZIP
31 bool "gzip"
32
33 config TARGET_INITRAMFS_COMPRESSION_BZIP2
34 bool "bzip2"
35
36 config TARGET_INITRAMFS_COMPRESSION_LZMA
37 bool "lzma"
38
39 config TARGET_INITRAMFS_COMPRESSION_LZO
40 bool "lzo"
41
42 config TARGET_INITRAMFS_COMPRESSION_LZ4
43 bool "lz4"
44
45 config TARGET_INITRAMFS_COMPRESSION_XZ
46 bool "xz"
47
48 config TARGET_INITRAMFS_COMPRESSION_ZSTD
49 bool "zstd"
50 endchoice
51
52 config EXTERNAL_CPIO
53 string
54 prompt "Use external cpio" if TARGET_ROOTFS_INITRAMFS
55 default ""
56 help
57 Kernel uses specified external cpio as INITRAMFS_SOURCE.
58
59 config TARGET_INITRAMFS_FORCE
60 bool "Force"
61 depends on TARGET_ROOTFS_INITRAMFS
62 help
63 Ignore the initramfs passed by the bootloader.
64
65 config TARGET_ROOTFS_INITRAMFS_SEPARATE
66 bool "separate ramdisk"
67 depends on USES_SEPARATE_INITRAMFS && TARGET_ROOTFS_INITRAMFS && !TARGET_INITRAMFS_FORCE
68 default y if USES_SEPARATE_INITRAMFS
69 help
70 Generate separate initrd.cpio instead of embedding it.
71 This is useful for generating images with a dedicated
72 ramdisk e.g. in U-Boot's uImage and uImage.FIT formats.
73
74 comment "Root filesystem archives"
75
76 config TARGET_ROOTFS_CPIOGZ
77 bool "cpio.gz"
78 default y if USES_CPIOGZ
79 help
80 Build a compressed cpio archive of the root filesystem.
81
82 config TARGET_ROOTFS_TARGZ
83 bool "tar.gz"
84 default y if USES_TARGZ
85 help
86 Build a compressed tar archive of the root filesystem.
87
88 comment "Root filesystem images"
89
90 menuconfig TARGET_ROOTFS_EXT4FS
91 bool "ext4"
92 default y if USES_EXT4
93 help
94 Build an ext4 root filesystem.
95
96 config TARGET_EXT4_RESERVED_PCT
97 int "Percentage of reserved blocks in root filesystem"
98 depends on TARGET_ROOTFS_EXT4FS
99 default 0
100 help
101 Select the percentage of reserved blocks in the root filesystem.
102
103 choice
104 prompt "Root filesystem block size"
105 default TARGET_EXT4_BLOCKSIZE_4K
106 depends on TARGET_ROOTFS_EXT4FS
107 help
108 Select the block size of the root filesystem.
109
110 config TARGET_EXT4_BLOCKSIZE_4K
111 bool "4k"
112
113 config TARGET_EXT4_BLOCKSIZE_2K
114 bool "2k"
115
116 config TARGET_EXT4_BLOCKSIZE_1K
117 bool "1k"
118 endchoice
119
120 config TARGET_EXT4_BLOCKSIZE
121 int
122 default 4096 if TARGET_EXT4_BLOCKSIZE_4K
123 default 2048 if TARGET_EXT4_BLOCKSIZE_2K
124 default 1024 if TARGET_EXT4_BLOCKSIZE_1K
125 depends on TARGET_ROOTFS_EXT4FS
126
127 config TARGET_EXT4_JOURNAL
128 bool "Create a journaling filesystem"
129 depends on TARGET_ROOTFS_EXT4FS
130 help
131 Create an ext4 filesystem with a journal.
132
133 config TARGET_ROOTFS_JFFS2
134 bool "jffs2"
135 depends on USES_JFFS2
136 help
137 Build a JFFS2 root filesystem.
138
139 config TARGET_ROOTFS_JFFS2_NAND
140 bool "jffs2 for NAND"
141 default y if USES_JFFS2_NAND
142 depends on USES_JFFS2_NAND
143 help
144 Build a JFFS2 root filesystem for NAND flash.
145
146 menuconfig TARGET_ROOTFS_SQUASHFS
147 bool "squashfs"
148 default y if USES_SQUASHFS
149 help
150 Build a squashfs root filesystem.
151
152 config TARGET_SQUASHFS_BLOCK_SIZE
153 int "Block size (in KiB)"
154 depends on TARGET_ROOTFS_SQUASHFS
155 default 64 if LOW_MEMORY_FOOTPRINT
156 default 1024 if (SMALL_FLASH && !LOW_MEMORY_FOOTPRINT)
157 default 256
158 help
159 Select squashfs block size, must be one of:
160 4, 8, 16, 32, 64, 128, 256, 512, 1024
161
162 menuconfig TARGET_ROOTFS_UBIFS
163 bool "ubifs"
164 default y if USES_UBIFS
165 depends on USES_UBIFS
166 help
167 Build a UBIFS root filesystem.
168
169 choice
170 prompt "compression"
171 default TARGET_UBIFS_COMPRESSION_ZLIB
172 depends on TARGET_ROOTFS_UBIFS
173 help
174 Select compression type
175
176 config TARGET_UBIFS_COMPRESSION_NONE
177 bool "none"
178
179 config TARGET_UBIFS_COMPRESSION_LZO
180 bool "lzo"
181
182 config TARGET_UBIFS_COMPRESSION_ZLIB
183 bool "zlib"
184 endchoice
185
186 config TARGET_UBIFS_FREE_SPACE_FIXUP
187 bool "free space fixup" if TARGET_ROOTFS_UBIFS
188 default y
189 help
190 The filesystem free space has to be fixed up on first mount.
191
192 config TARGET_UBIFS_JOURNAL_SIZE
193 string
194 prompt "journal size" if TARGET_ROOTFS_UBIFS
195 default ""
196
197 config GRUB_IMAGES
198 bool "Build GRUB images (Linux x86 or x86_64 host only)"
199 depends on TARGET_x86
200 depends on TARGET_ROOTFS_EXT4FS || TARGET_ROOTFS_JFFS2 || TARGET_ROOTFS_SQUASHFS
201 select PACKAGE_grub2
202 select PACKAGE_grub2-bios-setup
203 default y
204
205 config GRUB_EFI_IMAGES
206 bool "Build GRUB EFI images (Linux x86 or x86_64 host only)"
207 depends on TARGET_x86 || TARGET_armvirt
208 depends on TARGET_ROOTFS_EXT4FS || TARGET_ROOTFS_JFFS2 || TARGET_ROOTFS_SQUASHFS
209 select PACKAGE_grub2 if TARGET_x86
210 select PACKAGE_grub2-efi if TARGET_x86
211 select PACKAGE_grub2-bios-setup if TARGET_x86
212 select PACKAGE_grub2-efi-arm if TARGET_armvirt
213 select PACKAGE_kmod-fs-vfat
214 default y
215
216 config GRUB_CONSOLE
217 bool "Use Console Terminal (in addition to Serial)"
218 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
219 default y
220
221 config GRUB_SERIAL
222 string "Serial port device"
223 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
224 default "ttyS0"
225
226 config GRUB_BAUDRATE
227 int "Serial port baud rate"
228 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
229 default 38400 if TARGET_x86_generic
230 default 115200
231
232 config GRUB_FLOWCONTROL
233 bool "Use RTE/CTS on serial console"
234 depends on GRUB_SERIAL != ""
235
236 config GRUB_BOOTOPTS
237 string "Extra kernel boot options"
238 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
239 help
240 If you don't know, just leave it blank.
241
242 config GRUB_TIMEOUT
243 string "Seconds to wait before booting the default entry"
244 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
245 default "5"
246 help
247 If you don't know, 5 seconds is a reasonable default.
248
249 config GRUB_TITLE
250 string "Title for the menu entry in GRUB"
251 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
252 default "OpenWrt"
253 help
254 This is the title of the GRUB menu entry.
255 If unspecified, it defaults to OpenWrt.
256
257 config ISO_IMAGES
258 bool "Build LiveCD image (ISO)"
259 depends on TARGET_x86
260 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
261
262 config VDI_IMAGES
263 bool "Build VirtualBox image files (VDI)"
264 depends on TARGET_x86
265 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
266 select PACKAGE_kmod-e1000
267
268 config VMDK_IMAGES
269 bool "Build VMware image files (VMDK)"
270 depends on TARGET_x86
271 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
272 select PACKAGE_kmod-e1000
273
274 config VHDX_IMAGES
275 bool "Build Hyper-V image files (VHDX)"
276 depends on TARGET_x86
277 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
278 select PACKAGE_kmod-e1000
279
280 config TARGET_IMAGES_GZIP
281 bool "GZip images"
282 depends on TARGET_ROOTFS_EXT4FS || TARGET_x86 || TARGET_armvirt || TARGET_malta
283 default y
284
285 comment "Image Options"
286
287 source "target/linux/*/image/Config.in"
288 source "target/linux/*/*/image/Config.in"
289
290 config TARGET_KERNEL_PARTSIZE
291 int "Kernel partition size (in MiB)"
292 depends on USES_BOOT_PART
293 default 8 if TARGET_apm821xx_sata
294 default 64 if TARGET_bcm27xx
295 default 16
296
297 config TARGET_ROOTFS_PARTSIZE
298 int "Root filesystem partition size (in MiB)"
299 depends on USES_ROOTFS_PART || TARGET_ROOTFS_EXT4FS
300 default 104
301 help
302 Select the root filesystem partition size.
303
304 config TARGET_ROOTFS_PARTNAME
305 string "Root partition on target device"
306 depends on GRUB_IMAGES || GRUB_EFI_IMAGES
307 help
308 Override the root partition on the final device. If left empty,
309 it will be mounted by PARTUUID which makes the kernel find the
310 appropriate disk automatically.
311
312 config TARGET_ROOTFS_PERSIST_VAR
313 bool "Make /var persistent"
314 help
315 Do not symlink /var to /tmp, so that its content will persist
316 across reboots. When enabled, /var/run will still be linked
317 to /tmp/run.
318
319 endmenu