Config.in 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. config BR2_TARGET_GRUB2_ARCH_SUPPORTS
  2. bool
  3. default y if BR2_i386
  4. default y if BR2_x86_64
  5. default y if BR2_arm
  6. default y if BR2_aarch64
  7. default y if BR2_RISCV_64
  8. default y if BR2_loongarch64
  9. depends on BR2_USE_MMU
  10. menuconfig BR2_TARGET_GRUB2
  11. bool "grub2"
  12. depends on BR2_TARGET_GRUB2_ARCH_SUPPORTS
  13. depends on BR2_USE_WCHAR
  14. select BR2_TARGET_GRUB2_I386_PC if \
  15. !BR2_TARGET_GRUB2_HAS_PTF && \
  16. (BR2_i386 || BR2_x86_64)
  17. select BR2_TARGET_GRUB2_ARM_UBOOT if \
  18. !BR2_TARGET_GRUB2_HAS_PTF && \
  19. BR2_arm
  20. select BR2_TARGET_GRUB2_ARM64_EFI if BR2_aarch64
  21. help
  22. GNU GRUB is a Multiboot boot loader. It was derived from
  23. GRUB, the GRand Unified Bootloader, which was originally
  24. designed and implemented by Erich Stefan Boleyn. GRUB 2 has
  25. replaced what was formerly known as GRUB (i.e. version
  26. 0.9x), which has, in turn, become GRUB Legacy.
  27. Amongst others, GRUB2 offers EFI support, which GRUB Legacy
  28. doesn't provide.
  29. The file boot/grub2/grub.cfg is used by default as the Grub
  30. configuration file. It can be overridden using a rootfs
  31. overlay or post-build script.
  32. For additional notes on using Grub 2 with Buildroot, see
  33. boot/grub2/readme.txt
  34. http://www.gnu.org/software/grub/
  35. if BR2_TARGET_GRUB2
  36. config BR2_TARGET_GRUB2_HAS_LEGACY_BOOT
  37. bool
  38. config BR2_TARGET_GRUB2_HAS_EFI_BOOT
  39. bool
  40. config BR2_TARGET_GRUB2_HAS_PTF
  41. bool
  42. config BR2_TARGET_GRUB2_I386_PC
  43. bool "i386-pc"
  44. depends on BR2_i386 || BR2_x86_64
  45. select BR2_TARGET_GRUB2_HAS_LEGACY_BOOT
  46. help
  47. Select this option if the platform you're targeting is a
  48. x86 or x86-64 legacy BIOS based platform.
  49. config BR2_TARGET_GRUB2_I386_EFI
  50. bool "i386-efi"
  51. depends on BR2_i386 || BR2_x86_64
  52. select BR2_TARGET_GRUB2_HAS_PTF
  53. select BR2_TARGET_GRUB2_HAS_EFI_BOOT
  54. help
  55. Select this option if the platform you're targeting has a
  56. 32 bits EFI BIOS. Note that some x86-64 platforms use a 32
  57. bits EFI BIOS, and this option should be used in this case.
  58. config BR2_TARGET_GRUB2_X86_64_EFI
  59. bool "x86-64-efi"
  60. depends on BR2_x86_64
  61. select BR2_TARGET_GRUB2_HAS_PTF
  62. select BR2_TARGET_GRUB2_HAS_EFI_BOOT
  63. help
  64. Select this option if the platform you're targeting has a
  65. 64 bits EFI BIOS.
  66. config BR2_TARGET_GRUB2_ARM_UBOOT
  67. bool "arm-uboot"
  68. depends on BR2_arm
  69. select BR2_TARGET_GRUB2_HAS_LEGACY_BOOT
  70. help
  71. Select this option if the platform you're targeting is an
  72. ARM u-boot platform, and you want to boot Grub 2 as an u-boot
  73. compatible image.
  74. config BR2_TARGET_GRUB2_ARM_EFI
  75. bool "arm-efi"
  76. depends on BR2_arm
  77. select BR2_TARGET_GRUB2_HAS_PTF
  78. select BR2_TARGET_GRUB2_HAS_EFI_BOOT
  79. help
  80. Select this option if the platform you're targeting is an
  81. ARM platform and you want to boot Grub 2 as an EFI
  82. application.
  83. config BR2_TARGET_GRUB2_ARM64_EFI
  84. bool "arm64-efi"
  85. depends on BR2_aarch64
  86. select BR2_TARGET_GRUB2_HAS_EFI_BOOT
  87. help
  88. Select this option if the platform you're targeting is an
  89. Aarch64 platform and you want to boot Grub 2 as an EFI
  90. application.
  91. config BR2_TARGET_GRUB2_RISCV64_EFI
  92. bool "riscv64-efi"
  93. depends on BR2_RISCV_64
  94. select BR2_TARGET_GRUB2_HAS_EFI_BOOT
  95. help
  96. Select this option if the platform you're targeting is a
  97. 64bit RISC-V platform and you want to boot Grub 2 as an EFI
  98. application.
  99. config BR2_TARGET_GRUB2_LOONGARCH64_EFI
  100. bool "loongarch64-efi"
  101. depends on BR2_loongarch64
  102. select BR2_TARGET_GRUB2_HAS_EFI_BOOT
  103. help
  104. Select this option if the platform you're targetting is a
  105. 64bit LoongArch platform and you want to boot Grub 2 as an EFI
  106. application.
  107. if BR2_TARGET_GRUB2_HAS_LEGACY_BOOT
  108. comment "Options for the x86 legacy BIOS or ARM U-Boot support"
  109. config BR2_TARGET_GRUB2_BOOT_PARTITION
  110. string "boot partition"
  111. default "hd0,msdos1"
  112. help
  113. Specify the partition where the /boot/grub/grub.cfg file is
  114. located. Use 'hd0,msdos1' for the first partition of the
  115. first disk if using a legacy partition table, or 'hd0,gpt1'
  116. if using GPT partition table.
  117. config BR2_TARGET_GRUB2_BUILTIN_MODULES_PC
  118. string "builtin modules"
  119. default BR2_TARGET_GRUB2_BUILTIN_MODULES if BR2_TARGET_GRUB2_BUILTIN_MODULES != "" # legacy
  120. default "boot linux ext2 fat squash4 part_msdos part_gpt normal biosdisk" if BR2_TARGET_GRUB2_I386_PC
  121. default "linux ext2 fat part_msdos normal" if BR2_TARGET_GRUB2_ARM_UBOOT
  122. config BR2_TARGET_GRUB2_BUILTIN_CONFIG_PC
  123. string "builtin config"
  124. default BR2_TARGET_GRUB2_BUILTIN_CONFIG if BR2_TARGET_GRUB2_BUILTIN_CONFIG != "" # legacy
  125. help
  126. Path to a Grub 2 configuration file that will be embedded
  127. into the Grub image itself. This allows to set the root
  128. device and other configuration parameters, but however menu
  129. entries cannot be described in this embedded configuration.
  130. endif # BR2_TARGET_GRUB2_HAS_LEGACY_BOOT
  131. if BR2_TARGET_GRUB2_HAS_EFI_BOOT
  132. comment "Options for the EFI BIOS or ARM EFI support"
  133. config BR2_TARGET_GRUB2_BUILTIN_MODULES_EFI
  134. string "builtin modules"
  135. default BR2_TARGET_GRUB2_BUILTIN_MODULES if BR2_TARGET_GRUB2_BUILTIN_MODULES != "" # legacy
  136. default "boot linux ext2 fat squash4 part_msdos part_gpt normal efi_gop"
  137. config BR2_TARGET_GRUB2_BUILTIN_CONFIG_EFI
  138. string "builtin config"
  139. default BR2_TARGET_GRUB2_BUILTIN_CONFIG if BR2_TARGET_GRUB2_BUILTIN_CONFIG != "" # legacy
  140. help
  141. Path to a Grub 2 configuration file that will be embedded
  142. into the Grub image itself. This allows to set the root
  143. device and other configuration parameters, but however menu
  144. entries cannot be described in this embedded configuration.
  145. endif # BR2_TARGET_GRUB2_HAS_EFI_BOOT
  146. config BR2_TARGET_GRUB2_INSTALL_TOOLS
  147. bool "install tools"
  148. help
  149. Install support tools to interact with GNU GRUB Multiboot
  150. boot loader.
  151. This will also install the Grub 2 loadable modules to the
  152. target.
  153. endif # BR2_TARGET_GRUB2
  154. comment "grub2 needs a toolchain w/ wchar"
  155. depends on BR2_TARGET_GRUB2_ARCH_SUPPORTS
  156. depends on !BR2_USE_WCHAR