diff options
author | WANG Xuerui <xen0n@gentoo.org> | 2022-04-25 12:31:54 +0800 |
---|---|---|
committer | WANG Xuerui <xen0n@gentoo.org> | 2022-04-25 18:11:14 +0800 |
commit | 43dd58338de06e5f214e616425c17578908adfec (patch) | |
tree | 4eabc20d223c94185c96eddbe87b623aba13f4c3 /sys-devel/m4 | |
parent | sys-apps/grep: fix build on loong (diff) | |
download | gentoo-43dd58338de06e5f214e616425c17578908adfec.tar.gz gentoo-43dd58338de06e5f214e616425c17578908adfec.tar.bz2 gentoo-43dd58338de06e5f214e616425c17578908adfec.zip |
sys-devel/m4: fix build on loong
Upstream has updated gnulib but hasn't tagged a new release yet, so only
add the bare minimum to fix build on loong.
This has been inside loongson-overlay for a while, and is tested on real
loong hardware.
See: https://github.com/gentoo/gentoo/pull/25189
Acked-by: Andreas K. Hüttel <dilfridge@gentoo.org>
Signed-off-by: WANG Xuerui <xen0n@gentoo.org>
Diffstat (limited to 'sys-devel/m4')
-rw-r--r-- | sys-devel/m4/files/loong-fix-build.patch | 26 | ||||
-rw-r--r-- | sys-devel/m4/m4-1.4.19.ebuild | 1 |
2 files changed, 27 insertions, 0 deletions
diff --git a/sys-devel/m4/files/loong-fix-build.patch b/sys-devel/m4/files/loong-fix-build.patch new file mode 100644 index 000000000000..cd06fa8df5e4 --- /dev/null +++ b/sys-devel/m4/files/loong-fix-build.patch @@ -0,0 +1,26 @@ +From 34add045fd2ec3f1031dee961c4d9cc4285486a7 Mon Sep 17 00:00:00 2001 +From: Sun Haiyong <youbest@sina.com> +Date: Tue, 31 Aug 2021 11:11:52 +0800 +Subject: [PATCH] stack-direction: Add support for loongarch CPU + +* m4/stack-direction.m4 (SV_STACK_DIRECTION): When the CPU is loongarch, +set "sv_cv_stack_direction" to "-1" . +--- + m4/stack-direction.m4 | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/m4/stack-direction.m4 b/m4/stack-direction.m4 +index 93287254b..e6c3284ce 100644 +--- a/m4/stack-direction.m4 ++++ b/m4/stack-direction.m4 +@@ -32,6 +32,7 @@ AC_DEFUN([SV_STACK_DIRECTION], + i?86 | x86_64 | \ + i860 | \ + ia64 | \ ++ loongarch* | \ + m32r | \ + m68* | \ + m88k | \ +-- +2.17.2 + diff --git a/sys-devel/m4/m4-1.4.19.ebuild b/sys-devel/m4/m4-1.4.19.ebuild index 744de66535d5..8c29c255fee5 100644 --- a/sys-devel/m4/m4-1.4.19.ebuild +++ b/sys-devel/m4/m4-1.4.19.ebuild @@ -38,6 +38,7 @@ BDEPEND="app-arch/xz-utils PATCHES=( "${FILESDIR}"/ppc-musl.patch + "${FILESDIR}"/loong-fix-build.patch "${WORKDIR}"/${P}-test-198-sysval-r1.patch ) |