aboutsummaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorCem Keylan <cem@ckyln.com>2020-03-09 10:14:27 +0300
committerCem Keylan <cem@ckyln.com>2020-03-09 10:14:27 +0300
commit302e594f9e6e932c87d5592493aa756cb97f8d49 (patch)
treec2b2bde17eab71cffd906d22dfda316527c4bac8 /core
parentc9683824a50006cc08e86b26f772c633436e14de (diff)
downloadrepository-302e594f9e6e932c87d5592493aa756cb97f8d49.tar.gz
grub: add KISS patches
Diffstat (limited to 'core')
-rwxr-xr-xcore/grub/build18
-rw-r--r--core/grub/depends1
2 files changed, 17 insertions, 2 deletions
diff --git a/core/grub/build b/core/grub/build
index d0cee821..c937d263 100755
--- a/core/grub/build
+++ b/core/grub/build
@@ -1,6 +1,21 @@
#!/bin/sh -e
-# Grub is built in a function so the script argument needs to be stored.
+# Grub expects Python but it isn't actually needed. Give
+# it something fake so that configure passes.
+export PYTHON=/bin/true
+
+# Disable the post-python mv calls as a means of disabling
+# the Python tooling. The /bin/true above will create a
+# blank file, this prevents the blank file from overwriting
+# the existing one.
+sed -i 's/mv $@.new $@/:/g' grub/Makefile.in
+
+# Strip '-march' from 'CFLAGS' as per advice from upstream.
+# Fixes build fails on specific hardware.
+CFLAGS=$(printf %s "$CFLAGS" | sed 's/-march=[^ ]*//g')
+
+# Grub is built in a function so the script argument
+# needs to be stored.
pkg_dir=$1
build_grub() (
@@ -12,6 +27,7 @@ build_grub() (
--sbindir=/usr/bin \
--sysconfdir=/etc \
--disable-werror \
+ --disable-nls \
--disable-grub-mkfont \
--disable-grub-mount \
"$@"
diff --git a/core/grub/depends b/core/grub/depends
index 58223007..b37ce94a 100644
--- a/core/grub/depends
+++ b/core/grub/depends
@@ -2,5 +2,4 @@ binutils make
bison make
flex make
linux-headers make
-python make
xz