Updating link to change in openSUSE:Factory/libffi revision 11.0
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libffi?expand=0&rev=572816b58542a7c51451b3fc476d5bb1
This commit is contained in:
parent
9c4f6cb9b5
commit
16006e09f8
@ -11,6 +11,11 @@ Fri Sep 23 13:17:48 UTC 2022 - Richard Biener <rguenther@suse.com>
|
|||||||
- includes fix for RISCV64
|
- includes fix for RISCV64
|
||||||
- disable LTO due to (ffi#733)
|
- disable LTO due to (ffi#733)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Sep 23 12:48:15 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
- add riscv-rvalue-ext.patch to fix libffi for RISCV64
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Dec 1 15:44:46 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
Wed Dec 1 15:44:46 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
@ -26,6 +26,7 @@ Group: Development/Languages/C and C++
|
|||||||
URL: https://sourceware.org/libffi/
|
URL: https://sourceware.org/libffi/
|
||||||
Source: https://github.com/libffi/libffi/releases/download/v%{version}/libffi-%{version}.tar.gz
|
Source: https://github.com/libffi/libffi/releases/download/v%{version}/libffi-%{version}.tar.gz
|
||||||
Source99: baselibs.conf
|
Source99: baselibs.conf
|
||||||
|
Patch24301: riscv-rvalue-ext.patch
|
||||||
# for make check
|
# for make check
|
||||||
BuildRequires: dejagnu
|
BuildRequires: dejagnu
|
||||||
BuildRequires: expect
|
BuildRequires: expect
|
||||||
@ -64,7 +65,7 @@ time.
|
|||||||
%postun -n libffi%{libffi_sover} -p /sbin/ldconfig
|
%postun -n libffi%{libffi_sover} -p /sbin/ldconfig
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%autosetup -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# https://github.com/libffi/libffi/issues/733
|
# https://github.com/libffi/libffi/issues/733
|
||||||
|
50
riscv-rvalue-ext.patch
Normal file
50
riscv-rvalue-ext.patch
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
From 1bb79549b68e223c18bbc979d56879c82f0eba53 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Andreas Schwab <schwab@suse.de>
|
||||||
|
Date: Thu, 9 Dec 2021 23:03:30 +0100
|
||||||
|
Subject: [PATCH] riscv: extend return types smaller than ffi_arg
|
||||||
|
|
||||||
|
---
|
||||||
|
src/riscv/ffi.c | 27 ++++++++++++++++++++++++++-
|
||||||
|
1 file changed, 26 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/src/riscv/ffi.c b/src/riscv/ffi.c
|
||||||
|
index c910858..ebd05ba 100644
|
||||||
|
--- a/src/riscv/ffi.c
|
||||||
|
+++ b/src/riscv/ffi.c
|
||||||
|
@@ -373,7 +373,32 @@ ffi_call_int (ffi_cif *cif, void (*fn) (void), void *rvalue, void **avalue,
|
||||||
|
|
||||||
|
cb.used_float = cb.used_integer = 0;
|
||||||
|
if (!return_by_ref && rvalue)
|
||||||
|
- unmarshal(&cb, cif->rtype, 0, rvalue);
|
||||||
|
+ {
|
||||||
|
+ if (IS_INT(cif->rtype->type)
|
||||||
|
+ && cif->rtype->size < sizeof (ffi_arg))
|
||||||
|
+ {
|
||||||
|
+ /* Integer types smaller than ffi_arg need to be extended. */
|
||||||
|
+ switch (cif->rtype->type)
|
||||||
|
+ {
|
||||||
|
+ case FFI_TYPE_SINT8:
|
||||||
|
+ case FFI_TYPE_SINT16:
|
||||||
|
+ case FFI_TYPE_SINT32:
|
||||||
|
+ unmarshal_atom (&cb, (sizeof (ffi_arg) > 4
|
||||||
|
+ ? FFI_TYPE_SINT64 : FFI_TYPE_SINT32),
|
||||||
|
+ rvalue);
|
||||||
|
+ break;
|
||||||
|
+ case FFI_TYPE_UINT8:
|
||||||
|
+ case FFI_TYPE_UINT16:
|
||||||
|
+ case FFI_TYPE_UINT32:
|
||||||
|
+ unmarshal_atom (&cb, (sizeof (ffi_arg) > 4
|
||||||
|
+ ? FFI_TYPE_UINT64 : FFI_TYPE_UINT32),
|
||||||
|
+ rvalue);
|
||||||
|
+ break;
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
+ else
|
||||||
|
+ unmarshal(&cb, cif->rtype, 0, rvalue);
|
||||||
|
+ }
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
--
|
||||||
|
2.34.0
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user