aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/grub/grub2.inc
AgeCommit message (Collapse)Author
2019-01-28grub2: Fix passing null to printf formatsKhem Raj
Backport a patch that helps with this error which is found by gcc9 (From OE-Core rev: 93419fb569b827056a422614d3dc29cd41b2b6bb) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com>
2018-07-26grub2.inc: set GRUBPLATFORM_arm to efiMingli Yu
* grub-efi support on arm is enabled as below commit: commit 65f9fb788371a9a08e3b0e6febecb9cc2aaeefe7 Author: Kristian Amlie <kristian.amlie@northern.tech> Date: Tue Jul 10 16:07:12 2018 +0200 grub-efi: Provide target architecture for 32-bit ARM. * But it fails on arm as below: | grub-mkimage: error: cannot open `./grub-core//serial.mod': No such file or directory. Set GRUBPLATFORM_arm = "efi" to fix the above error Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-07-26grub: fix build with new binutilsRoss Burton
2018-05-11grub2: fix build with gcc8Martin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-01-22grub: Fix device mapper dependencyRobert Joslyn
The lvm2 recipe in meta-oe was split, so the libdevmapper library is provided by the libdevmapper recipe rather than lvm2. Signed-off-by: Robert Joslyn <robert_joslyn@selinc.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2018-01-19grub/grub-efi: fix conflictHongxu Jia
While installing grub and grub-efi, there are conflict files in ${sysconfdir} ${datadir} ${bindir} ${sbindir}. - Since all of the conflicted files are tools which is common for grub and grub-efi, we split them (except grub-editenv) to grub-common in grub. - The package grub-common runtime depends grub-editenv - The package grub-editenv runtime provides grub-efi-editenv - Remove SYSROOT_DIRS_BLACKLIST - The recipe grub-efi does not generate the duplicated files and use runtime depends grub-common to instead Debian and Fedora do the similar thing. Debian use a common package grub-common for both of pc bios and efi, and use package grub-pc-bin for pc bios, grub-efi-amd64-bin for efi. Both of grub-pc-bin and grub-efi-amd64-bin requires grub-common. https://packages.debian.org/sid/grub-common https://packages.debian.org/jessie/grub-pc-bin https://packages.debian.org/jessie/grub-efi-amd64-bin Fedora use a common package grub2-tools for both of pc bios and efi, and use package grub2 for pc bios, grub2-efi-modules for efi. Both of grub2 and grub2-efi-modules requires grub2-tools. https://www.rpmfind.net/linux/RPM/fedora/devel/rawhide/x86_64/g/grub2-tools-2.02-0.34.fc24.x86_64.html https://www.rpmfind.net/linux/RPM/fedora/devel/rawhide/x86_64/g/grub2-2.02-0.34.fc24.x86_64.html https://www.rpmfind.net/linux/RPM/fedora/devel/rawhide/x86_64/g/grub2-efi-modules-2.02-0.34.fc24.x86_64.html [YOCTO #11639] Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-12-10grub: Move grub-editenv packaging to grub2.incOtavio Salvador
The editenv utility must be available on grub and grub-efi so we better have it inside the grub2.inc file to avoid the duplication of metadata. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-08-23grub2: fix build on gcc where _FORTIFY_SOURCE is definedMartin Jansa
* e.g. with gentoo gcc-7.1 they define _FORTIFY_SOURCE by default with: https://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo/src/patchsets/gcc/7.1.0/gentoo/10_all_default-fortify-source.patch?view=markup which results in following error while building grub-efi-native: ./config-util.h:1504:48: error: this use of "defined" may not be portable [-Werror=expansion-to-defined] || (defined _FORTIFY_SOURCE && 0 < _FORTIFY_SOURCE \ ^~~~~~~~~~~~~~~ this part comes from gnulib and it's used only for Apple and BSD, so we can ignore it, but we cannot add -Wno-error=expansion-to-defined because this warning was introduced only in gcc-7 and older gcc will fail with: cc1: error: -Werror=expansion-to-defined: no option -Wexpansion-to-defined use #pragma to work around this Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-06-28grub: fix 0001-grub.d-10_linux.in-add-oe-s-kernel-name.patch missingHongxu Jia
Since grub upgraded to 2.02, it forgot to aplly 0001-grub.d-10_linux.in-add-oe-s-kernel-name.patch. ... commit 4f27e4042dfb39caa71c7c6eb0a327de6af4d563 Author: Khem Raj <raj.khem@gmail.com> Date: Fri Apr 21 20:36:06 2017 +0000 grub: Update to 2.02 ... The missing caused grub-mkconfig could not detect kernel bzImage. Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2017-06-28grub2: remove autogen dependencyAlexander Kanavin
Hasn't been required by grub for quite a while. Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
2017-06-14grub: switch from ftp to httpsMaxin B. John
For the same reasons as Debian: https://www.debian.org/News/2017/20170425 Signed-off-by: Maxin B. John <maxin.john@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-05-23grub: Update to 2.02Khem Raj
Drop git recipe, add arm bits to 2.02 itself Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-12-19grub: Fix build with glibc 2.25Khem Raj
Backport relevant patch from grub git Signed-off-by: Khem Raj <raj.khem@gmail.com>
2016-12-13grub2: fix some quirks and div by zeroAwais Belal
Rather than erroring out on a single attempt while terminating EFI services, make a few retries because such quirks are found in a few implementations. Also fix a div by zero issue in the same framework which causes an infinite reboot on the target. Both patches included here are backports. Signed-off-by: Awais Belal <awais_belal@mentor.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-12-08grub2: enforce -no-pie if supported by compilerAlexander Kanavin
Recent distros are enabling -pie by default; in case of grub we need to turn it off. Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-08-23grub: fix load module all_video failedHongxu Jia
While using oe-core toolchain to strip grub module 'all_video.mod', it stripped symbol table: -------------- root@localhost:~# objdump -t all_video.mod all_video.mod: file format elf64-x86-64 SYMBOL TABLE: no symbols -------------- It caused grub to load module all_video failed. (This module will be loaded by defalut which configed in grub.cfg) -------------- grub> insmod all_video error: no symbol table. -------------- Tweak strip option to keep symbol .module_license could workaround the issue. -------------- root@localhost:~# objdump -t all_video.mod all_video.mod: file format elf64-x86-64 SYMBOL TABLE: 0000000000000000 l d .text 0000000000000000 .text 0000000000000000 l d .data 0000000000000000 .data 0000000000000000 l d .module_license 0000000000000000 .module_license 0000000000000000 l d .bss 0000000000000000 .bss 0000000000000000 l d .moddeps 0000000000000000 .moddeps 0000000000000000 l d .modname 0000000000000000 .modname -------------- Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-08-04grub2.inc: run autogen.sh before configuremingli.yu@windriver.com
* When adding new source files from upstream the autogen.sh script needs to be run * Rework grub2-remove-sparc64-setup-from-x86-builds.patch to remove the grub-setup helper program grub-sparc64-setup in Makefile.util.def instead of the previous Makefile.util.am to avoid the update for Makefile.util.am in do_patch phase is overwritten by the autogen.sh in do_configure phase Signed-off-by: Catalin Enache <catalin.enache@windriver.com> Signed-off-by: Mingli Yu <mingli.yu@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-05-13grub: Fix build with gcc-6Khem Raj
Backport patch which silences following '../../grub-2.00/grub-core/'`gfxmenu/model.c ../../grub-2.00/grub-core/gettext/gettext.c:37:36: error: storage size of 'main_context' isn't known static struct grub_gettext_context main_context, secondary_context; ^~~~~~~~~~~~ make[3]: *** [gettext/gettext_module-gettext.o] Error 1 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-13grub2.inc: Use SYSROOT_DIRS_BLACKLIST to exclude dirs from the sysrootPeter Kjellerstedt
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-20grub: fix documentation rebuildsRoss Burton
If the documentation needs to rebuild then it will fail as the syntax isn't valid with modern texinfo. Backport a patch from git to fix the syntax. [ YOCTO #9306 ] Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-03-02grub2.inc: drop bogus dependency on xzAndre McCurdy
grub contains it's own internal lzma library. Attempting to build grub against the system liblzma shared library or header files is not likely to end well. This change does not cause a floating dependency since all grub2.inc based recipes pass "--enable-liblzma=no" to configure. Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-03-02grub2.inc: avoid passing -isystem to native buildsAndre McCurdy
grub2 creates its own set of -nostdinc / -isystem / -ffreestanding CFLAGS and OE's default BUILD_CFLAGS (assigned to CFLAGS for native builds) etc, conflict with that. Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-03-02grub2.inc: dont export TARGET_CFLAGS etc to grub2 configureAndre McCurdy
The grub2 configure script uses variables such as TARGET_CFLAGS etc for its own purposes. Remove the OE versions from the configure environment to avoid conflicts. Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-01-29grub: Backport fix for largefile detection/useKhem Raj
This is inspired by musl porting, where grub's configure is enabling largefile support based on glibc versions, instead an upstream patch turns it into autoconf check Update git version recipe arm platforms use this recipe to provide grub and it needed fixes from upstream so upgrade to latest tip of git and forward port patches as well as drop the ones already applied upstream Signed-off-by: Khem Raj <raj.khem@gmail.com>
2016-01-07grub2: Fix CVE-2015-8370Awais Belal
http://git.savannah.gnu.org/cgit/grub.git/commit/?id=451d80e52d851432e109771bb8febafca7a5f1f2 Signed-off-by: Awais Belal <awais_belal@mentor.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-04-30grub2: fix initrd size restriction bugShan Hai
The current grub2 fails on loading large initrd file (> 500M) since the initrd size is added to the addr_min and causes the failure. Fix it by picking a patch from grub2 upstream. Signed-off-by: Shan Hai <shan.hai@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-27grub: Backport const qualifier fix for gcc-5Khem Raj
gcc-5 is stricter and complains about const to non-const conversions, we backport the patch from upstream into 2.00 Change-Id: I17db365fdd253daaa1ab726e2a70ecad0ac7b2ae Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-21recipes: Fix charset.alias for muslKhem Raj
This is same gnulib fix replicated across needed recipes Change-Id: I756713407111a726eae98e26c9c1ff64981371c0 Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-04-13grub-efi: add PACKAGECONFIG for grub-mount and device-mapperRobert Yang
We had PACKAGECONFIGs for grub_2.00 and grub_git, we also need them for grub-efi, otherwise there might be failures as: grub-2.00/util/grub-mount.c:37:23: fatal error: fuse/fuse.h: No such file or directory Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-23grub: remove autogen-native dependency for tarball recipesRoss Burton
The tarballs of grub ship the files that are generated by autogen, so tarball recipes don't need to depend on autogen-native (and thus guile-native). Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-01-16grub 2.0: several fixesRobert Yang
* Make grub, grub-efi grub_git use a grub2.inc to reduce the duplicated code. * Make grub and grub-efi use the same patches since they use the same source. (grub_git is different). * grub-efi: - Use autotools to replace autotools-brokensep - Remove the DEPENDS of freetype, it should be a RDEPENDS. - Remove grub-2.00-ignore-gnulib-gets-stupidity.patch since it is a duplication of remove-gets.patch. - Make grub-efi.rpm contain files rather than make an empty package. * grub_git: - Fix a SSE build failure. [YOCTO #6310] Signed-off-by: Robert Yang <liezhi.yang@windriver.com>