mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 00:48:18 -07:00
dev-libs/ffcall: revert patch of support for clang
which is a problem for release 2.4 but fixed in 2.5.
The bug is:
> libtool: compile: clang -O2 -pipe -g -fPIC -x none -c avcall-x86_64.s -fPIC -DPIC -o .libs/avcall-x86_64.o
> avcall-x86_64.s:591:2: error: changed section flags for .eh_frame, expected: 0x2
> .section .eh_frame,"aw",@progbits
Which is fixed by change flags "aw" to "a" on all platforms, see commit below:
> https://git.savannah.gnu.org/cgit/libffcall.git/commit/?id=580f0bb144c0d63560c61229291e172e55971437
So the old patch (add "-no-integrated-as" for clang) is reverted:
> https://git.savannah.gnu.org/cgit/libffcall.git/commit/?id=fe6d9f089d8326b077420c10fec8c2174557be30
Fixes: 5b89df93ef
Signed-off-by: Z. Liu <zhixu.liu@gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/42572
Closes: https://github.com/gentoo/gentoo/pull/42572
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit autotools dot-a flag-o-matic libtool
|
||||
inherit dot-a flag-o-matic libtool
|
||||
|
||||
MY_PV="libffcall-${PV}"
|
||||
|
||||
@@ -19,10 +19,6 @@ LICENSE="GPL-2+"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha amd64 ~arm ~arm64 ~hppa ~mips ppc ppc64 ~riscv ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/ffcall-2.5-add-support-for-clang.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
# The build system is a strange mix of autogenerated
|
||||
# files and manual tweaks on top. Uses $CFLAGS / $LDFLAGS randomly.
|
||||
@@ -38,7 +34,6 @@ src_prepare() {
|
||||
done
|
||||
|
||||
default
|
||||
eautoreconf
|
||||
elibtoolize
|
||||
|
||||
if use kernel_linux ; then
|
||||
|
||||
@@ -1,53 +0,0 @@
|
||||
https://git.savannah.gnu.org/cgit/libffcall.git/commit/?id=fe6d9f089d8326b077420c10fec8c2174557be30
|
||||
|
||||
From fe6d9f089d8326b077420c10fec8c2174557be30 Mon Sep 17 00:00:00 2001
|
||||
From: Bruno Haible <bruno@clisp.org>
|
||||
Date: Tue, 20 Aug 2024 13:38:19 +0200
|
||||
Subject: [PATCH] Add support for Android.
|
||||
|
||||
* m4/cc-gcc.m4 (CL_CC_GCC): If using clang as compiler, add the option
|
||||
-no-integrated-as to GCC_X_NONE.
|
||||
* NEWS: Mention Android as supported.
|
||||
|
||||
diff --git a/m4/cc-gcc.m4 b/m4/cc-gcc.m4
|
||||
index 1e12d8e..97c2dac 100644
|
||||
--- a/m4/cc-gcc.m4
|
||||
+++ b/m4/cc-gcc.m4
|
||||
@@ -1,5 +1,5 @@
|
||||
dnl -*- Autoconf -*-
|
||||
-dnl Copyright (C) 1993-2017 Free Software Foundation, Inc.
|
||||
+dnl Copyright (C) 1993-2024 Free Software Foundation, Inc.
|
||||
dnl This file is free software, distributed under the terms of the GNU
|
||||
dnl General Public License as published by the Free Software Foundation;
|
||||
dnl either version 2 of the License, or (at your option) any later version.
|
||||
@@ -27,6 +27,27 @@ AC_DEFUN([CL_CC_GCC],
|
||||
if test $cl_cv_prog_cc_gcc = yes; then
|
||||
CC_GCC=true
|
||||
GCC_X_NONE='-x none'
|
||||
+
|
||||
+ dnl On arm, there are two slightly different syntaxes for assembly language:
|
||||
+ dnl The "divided" syntax (standard since ca. 2000) and the "unified" syntax
|
||||
+ dnl (supported by GNU binutils since 2009). See
|
||||
+ dnl https://sourceware.org/binutils/docs/as/ARM_002dInstruction_002dSet.html
|
||||
+ dnl While GNU as and thus GCC supports both, clang by default uses an
|
||||
+ dnl "integrated" assembler that supports only the "unified" syntax, leading
|
||||
+ dnl to errors "error: invalid instruction" on instructions such as stmeqia.
|
||||
+ dnl We therefore need to tell clang to use the external assembler.
|
||||
+ AC_CACHE_CHECK([whether using clang], [cl_cv_prog_cc_clang],
|
||||
+ [AC_EGREP_CPP([yes],
|
||||
+ [#ifdef __clang__
|
||||
+ yes
|
||||
+ #endif
|
||||
+ ],
|
||||
+ [cl_cv_prog_cc_clang=yes],
|
||||
+ [cl_cv_prog_cc_clang=no])
|
||||
+ ])
|
||||
+ if test $cl_cv_prog_cc_clang = yes; then
|
||||
+ GCC_X_NONE="$GCC_X_NONE -no-integrated-as"
|
||||
+ fi
|
||||
else
|
||||
CC_GCC=false
|
||||
GCC_X_NONE=''
|
||||
--
|
||||
2.45.2
|
||||
|
||||
Reference in New Issue
Block a user