1 Star 0 Fork 83

KMF / grub2

forked from src-openEuler / grub2 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0095-Disable-non-wordsize-allocations-on-arm.patch 1.43 KB
一键复制 编辑 原始数据 按行查看 历史
zhangqiumiao 提交于 2022-03-07 17:05 . update to version 2.06
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 2 Aug 2018 10:56:38 -0400
Subject: [PATCH] Disable non-wordsize allocations on arm
Signed-off-by: Peter Jones <pjones@redhat.com>
---
configure.ac | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/configure.ac b/configure.ac
index b27573b3de5..bb4e05ceef3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1288,6 +1288,26 @@ if test "x$target_cpu" = xarm; then
done
])
+ AC_CACHE_CHECK([for options to disable movt and movw relocations],
+ grub_cv_target_cc_mword_relocations,
+ [grub_cv_target_cc_mword_relocations=no
+ for cand in "-mword-relocations" ; do
+ if test x"$grub_cv_target_cc_mword_relocations" != xno ; then
+ break
+ fi
+ CFLAGS="$TARGET_CFLAGS $cand -Werror"
+ CPPFLAGS="$TARGET_CPPFLAGS"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],
+ [grub_cv_target_cc_mword_relocations="$cand"],
+ [])
+ done
+ ])
+ if test x"$grub_cv_target_cc_mword_relocations" = xno ; then
+ AC_MSG_ERROR(["your compiler doesn't support disabling movw/movt relocations"])
+ else
+ TARGET_CFLAGS="$TARGET_CFLAGS $grub_cv_target_cc_mword_relocations"
+ fi
+
if test x"$grub_cv_target_cc_mno_movt" != xno ; then
# A trick so that clang doesn't see it on link stage
TARGET_CPPFLAGS="$TARGET_CPPFLAGS $grub_cv_target_cc_mno_movt"
1
https://gitee.com/kmf/grub2.git
git@gitee.com:kmf/grub2.git
kmf
grub2
grub2
master

搜索帮助