summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/libffi
Commit message (Collapse)AuthorAgeFilesLines
* libffi: add patch to revert clang VFP workaroundBrett Warren2020-12-182-0/+105
| | | | | | | | | | | | | | Patch is added to address an issue preventing libffi from compiling under clang. Change-Id: I55e36d252ec8e84de9b35fea18044c2c0e8c5aab (From OE-Core rev: a4944e9b553ddf55da9d9a1243fadc93a620b003) Signed-off-by: Brett Warren <brett.warren@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 01e8c53488dd5ebb206bef2415549e8ac1ac7601) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: fix multilib header conflictChangqing Li2020-08-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fix error: file /usr/include/ffitarget.h conflicts between attempted installs of lib32-libffi-dev-3.3-r0.armv7vet2hf_vfp and libffi-dev-3.3-r0.cortexa57 part of diff #ifndef LIBFFI_ASM -typedef unsigned long ffi_arg; -typedef signed long ffi_sarg; - -typedef enum ffi_abi { - FFI_FIRST_ABI = 0, - FFI_SYSV, - FFI_VFP, - FFI_LAST_ABI, -#if defined(__ARM_PCS_VFP) || defined(_M_ARM) - FFI_DEFAULT_ABI = FFI_VFP, +#ifdef __ILP32__ +#define FFI_SIZEOF_ARG 8 +#define FFI_SIZEOF_JAVA_RAW 4 +typedef unsigned long long ffi_arg; +typedef signed long long ffi_sarg; +#elif defined(_M_ARM64) +#define FFI_SIZEOF_ARG 8 +typedef unsigned long long ffi_arg; +typedef signed long long ffi_sarg; #else - FFI_DEFAULT_ABI = FFI_SYSV, -#endif -} ffi_abi; +typedef unsigned long ffi_arg; +typedef signed long ffi_sarg; #endif -#define FFI_EXTRA_CIF_FIELDS \ - int vfp_used; \ - unsigned short vfp_reg_free, vfp_nargs; \ - signed char vfp_args[16] \ - -#define FFI_TARGET_SPECIFIC_VARIADIC -#ifndef _M_ARM -#define FFI_TARGET_HAS_COMPLEX_TYPE +typedef enum ffi_abi + { + FFI_FIRST_ABI = 0, + FFI_SYSV, + FFI_LAST_ABI, + FFI_DEFAULT_ABI = FFI_SYSV + } ffi_abi; #endif /* ---- Definitions for closures ----------------------------------------- */ #define FFI_CLOSURES 1 -#define FFI_GO_CLOSURES 1 #define FFI_NATIVE_RAW_API 0 #if defined (FFI_EXEC_TRAMPOLINE_TABLE) && FFI_EXEC_TRAMPOLINE_TABLE #ifdef __MACH__ -#define FFI_TRAMPOLINE_SIZE 12 -#define FFI_TRAMPOLINE_CLOSURE_OFFSET 8 +#define FFI_TRAMPOLINE_SIZE 16 +#define FFI_TRAMPOLINE_CLOSURE_OFFSET 16 #else #error "No trampoline table implementation" #endif #else -#ifdef _MSC_VER -#define FFI_TRAMPOLINE_SIZE 16 -#define FFI_TRAMPOLINE_CLOSURE_FUNCTION 12 -#else -#define FFI_TRAMPOLINE_SIZE 12 -#endif +#define FFI_TRAMPOLINE_SIZE 24 #define FFI_TRAMPOLINE_CLOSURE_OFFSET FFI_TRAMPOLINE_SIZE #endif +#ifdef _M_ARM64 +#define FFI_EXTRA_CIF_FIELDS unsigned is_variadic +#endif + (From OE-Core rev: 6392d99de30e74c41b289c43fd98601e6cbc34ab) Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit efe8d76810973e7032e729beee106b8acc39b8ed) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: fix v3.3 compile on ppc64leAndrew Geissler2020-05-072-0/+63
| | | | | | | | | | | | | | | | The latest released version of libffi no longer compiles on ppc64le based machines. Some searching found a patch that fixed our issue but had not been submitted upstream to libffi. It has now been submitted upstream with this PR: https://github.com/libffi/libffi/pull/561 (From OE-Core rev: ed7ce0d5e9009d80a79c39bb3d0d45de6e7721c0) Signed-off-by: Andrew Geissler <geissonator@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: Fix build on ppc64Khem Raj2019-12-092-0/+35
| | | | | | | | | | Similar fix was applied already upstream but not extended to all the cases (From OE-Core rev: ec6d1e337f36d75588133d5b6988ee438600b8ad) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: update to 3.3 finalAlexander Kanavin2019-12-045-15/+86
| | | | | | | | | | | Add a couple patches to address ppc(64) build failures. License-Update: copyright years (From OE-Core rev: 9aab37ac40c8da5121a931f5979fcc88489021d2) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: fix upstream version checkAlexander Kanavin2019-09-011-0/+3
| | | | | | | | | | As there is no version newer than 3.3-rc0 yet, an exception from the check is needed. (From OE-Core rev: 5850d42187de00db4b0c01ba97fe41aaec3f6613) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: Make it build for MIPS o32Peter Kjellerstedt2019-08-282-0/+32
| | | | | | | | | | | | | | | This solves the following errors: src/mips/o32.S: Assembler messages: src/mips/o32.S:286: Error: opcode not supported on this processor: mips32r2 (mips32r2) `s.d $f12,((16*4)-10*4)($fp)' src/mips/o32.S:287: Error: opcode not supported on this processor: mips32r2 (mips32r2) `s.d $f14,((16*4)-8*4)($fp)' (From OE-Core rev: 250d85144c0118aebfce105f02425c25cb028087) Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: Upgrade to 3.3-rc0Khem Raj2019-08-226-1081/+14
| | | | | | | | | | | | | | | | | | | libffi 3.1 release has been a bit aged and new architectures, compilers have since been come on stage to compile it, we have been carrying patches, but its better to use the latest 3.3 rc0 which has lot of these issues handled and is in good shape. Use 3.3~rc0 for PV to keep room for upgrade path without PE bump fix the multilib header conflict file /usr/include/ffi.h from install of libffi-dev-3.2.1+3.3+rc0-r0.core2_32 conflicts with file from package lib64-libffi-dev-3.2.1+3.3+rc0-r0.x86_64 (From OE-Core rev: 06e731bdea527d5c42e99bbcef7f2835e158c0a0) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Change ftp:// URIs to http(s)://Adrian Bunk2019-08-031-1/+1
| | | | | | | (From OE-Core rev: a11edd68b256fffb088cde5b7298a5749161f600) Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: Add RISC-V supportAlistair Francis2019-06-192-2/+830
| | | | | | | | | Backport a libffi patch to add RISC-V support. (From OE-Core rev: 24f4b2a8f2a0ed52fd791a5c393dea7d02f45116) Signed-off-by: Alistair Francis <alistair.francis@wdc.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: refresh patchesRoss Burton2018-03-091-4/+8
| | | | | | | | | | | | | | | | | | | | | The patch tool will apply patches by default with "fuzz", which is where if the hunk context isn't present but what is there is close enough, it will force the patch in. Whilst this is useful when there's just whitespace changes, when applied to source it is possible for a patch applied with fuzz to produce broken code which still compiles (see #10450). This is obviously bad. We'd like to eventually have do_patch() rejecting any fuzz on these grounds. For that to be realistic the existing patches with fuzz need to be rebased and reviewed. (From OE-Core rev: 7ae4ce08071c02beaf09675c2c1ed70617b797dd) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: Add HOMEPAGE info into recipe file.Huang Qiyu2017-09-221-0/+1
| | | | | | | | (From OE-Core rev: cfe74cb67f284e58c6d133d456fb6d8e763f3e5c) Signed-off-by: Huang Qiyu <huangqy.fnst@cn.fujitsu.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* ossp-uuid, libffi, libgcrypt: Pass --tag=CC option to libtoolKhem Raj2017-08-091-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | libtool tries to guess the --tag value based on CC/CXX environment variables and the compile commandline generated by makefiles. This heuristics however fails when we construct CC variables in OE and add security flags to it, especially -fPIE -pie which are added by external compilers e.g. clang particularly. It fails because libtool removed PIE flags from compiler cmdline intelligently if it figures out that its building a library, which means that the CC variable passed from cmdline does not match with the compiler cmdline constructed by libtool and we end up with errors like | arm-bec-linux-musleabi-libtool: compile: unable to infer tagged configuration | arm-bec-linux-musleabi-libtool: error: specify a tag with '--tag' This works with internal gcc toolchain because we configure gcc for PIE when hardening is selected and dont pass -fPIE -pie options explicitly but this is not an option for clang, and some external gcc toolchains using older gcc This patch adds the --tag option to help libtool set correct tags in packages where it cant get it right via its heuristics (From OE-Core rev: 0505075ae8d339ba097aebb82b4d0ae62f87c0a9) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: Support musl-x32 buildsweeaun2017-07-242-0/+31
| | | | | | | | | | Added target musl-x32 in configure.ac to support musl-x32 build in libffi. (From OE-Core rev: 318e33a708378652edcf61ce7d9d7f3a07743000) Signed-off-by: sweeaun <swee.aun.khor@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: backport patch to fix building MIPS soft floatAndré Draszik2016-09-082-0/+178
| | | | | | | | | | | Upstream-Status: Backport [https://github.com/libffi/libffi/commit/2ded2a4f494165c93293afc14ab0be1243cf8c49] (From OE-Core rev: 0231a6f92d2c8b89b419aeb09a4b35f871bfb2bf) (From OE-Core rev: 0ce7415bb50bf1941981ef61590fe642b055d290) Signed-off-by: André Draszik <git@andred.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: fix a typo (mips)André Draszik2016-08-201-1/+1
| | | | | | | | | | | | | While code elsewhere checks for MIPS_INSTRUCTION_SET == mips16e in order to decide how to compile, hence the typo doesn't affect behaviour, the intention was to set it to 'mips', as is done everywhere else. Fixing the typo also helps to avoid confusion. (From OE-Core rev: 45b27564324c754a34a1930437a7167079fe1ee4) Signed-off-by: André Draszik <git@andred.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: don't compile in mips16e modeAndré Draszik2016-07-011-0/+4
| | | | | | | | | | | libffi contains hand-written assembly which is not compatible with the MIPS16e mode. (From OE-Core rev: 27467ca354801aeb6d7e3a658cff3dda37db971a) Signed-off-by: André Draszik <adraszik@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libffi: move from recipes-gnome to recipes-supportRoss Burton2016-02-043-0/+80
(From OE-Core rev: a2c43ffe55e022cb5621d549c8aae914c6fa54a1) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>