Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 1 | require grub2.inc |
| 2 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 3 | RDEPENDS_${PN}-common += "${PN}-editenv" |
Brad Bishop | a34c030 | 2019-09-23 22:34:48 -0400 | [diff] [blame] | 4 | RDEPENDS_${PN} += "${PN}-common" |
Andrew Geissler | d25ed32 | 2020-06-27 00:28:28 -0500 | [diff] [blame] | 5 | RDEPENDS_${PN}_class-native = "" |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 6 | |
| 7 | RPROVIDES_${PN}-editenv += "${PN}-efi-editenv" |
| 8 | |
Andrew Geissler | d25ed32 | 2020-06-27 00:28:28 -0500 | [diff] [blame] | 9 | PROVIDES_append_class-native = " grub-efi-native" |
| 10 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 11 | PACKAGES =+ "${PN}-editenv ${PN}-common" |
| 12 | FILES_${PN}-editenv = "${bindir}/grub-editenv" |
| 13 | FILES_${PN}-common = " \ |
| 14 | ${bindir} \ |
| 15 | ${sysconfdir} \ |
| 16 | ${sbindir} \ |
| 17 | ${datadir}/grub \ |
| 18 | " |
Andrew Geissler | 90fd73c | 2021-03-05 15:25:55 -0600 | [diff] [blame^] | 19 | ALLOW_EMPTY_${PN} = "1" |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 20 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 21 | do_install_append () { |
Andrew Geissler | 90fd73c | 2021-03-05 15:25:55 -0600 | [diff] [blame^] | 22 | # Avoid conflicts with the EFI package for systems such as arm64 where we |
| 23 | # need to build grub and grub-efi but only EFI is supported by removing EFI |
| 24 | # from this package. |
| 25 | rm -rf ${D}${libdir}/grub/*-efi/ |
| 26 | rmdir --ignore-fail-on-non-empty ${D}${libdir}/grub ${D}${libdir} |
| 27 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 28 | install -d ${D}${sysconfdir}/grub.d |
| 29 | # Remove build host references... |
| 30 | find "${D}" -name modinfo.sh -type f -exec \ |
| 31 | sed -i \ |
| 32 | -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \ |
| 33 | -e 's|${DEBUG_PREFIX_MAP}||g' \ |
| 34 | -e 's:${RECIPE_SYSROOT_NATIVE}::g' \ |
| 35 | {} + |
| 36 | } |
| 37 | |
| 38 | INSANE_SKIP_${PN} = "arch" |
| 39 | INSANE_SKIP_${PN}-dbg = "arch" |
Andrew Geissler | d25ed32 | 2020-06-27 00:28:28 -0500 | [diff] [blame] | 40 | |
Andrew Geissler | 6ce62a2 | 2020-11-30 19:58:47 -0600 | [diff] [blame] | 41 | BBCLASSEXTEND = "native nativesdk" |