From e65b54277eeff1ca83677006c6f6fe28fce8c6e1 Mon Sep 17 00:00:00 2001 From: Adrian Smith Date: Thu, 12 Sep 2024 18:31:57 -0700 Subject: [PATCH] Use latest libffi instead of libffi from static jdk. The libffi version from the static jdk crashes when using closures. --- lib/ios-arm64/libffi.a | Bin 54024 -> 0 bytes src/com/phronemophobic/grease/membrane.clj | 2 + third_party/ffi/ffi.h | 24 - third_party/ffi/ffi_arm64.h | 533 ------------------ third_party/ffi/ffi_armv7.h | 533 ------------------ third_party/ffi/ffi_x86_64.h | 533 ------------------ third_party/ffi/ffitarget.h | 24 - third_party/ffi/ffitarget_arm64.h | 102 ---- third_party/ffi/ffitarget_armv7.h | 94 --- third_party/ffi/ffitarget_x86_64.h | 167 ------ .../TestSkia.xcodeproj/project.pbxproj | 109 +++- 11 files changed, 108 insertions(+), 2013 deletions(-) delete mode 100644 lib/ios-arm64/libffi.a delete mode 100644 third_party/ffi/ffi.h delete mode 100644 third_party/ffi/ffi_arm64.h delete mode 100644 third_party/ffi/ffi_armv7.h delete mode 100644 third_party/ffi/ffi_x86_64.h delete mode 100644 third_party/ffi/ffitarget.h delete mode 100644 third_party/ffi/ffitarget_arm64.h delete mode 100644 third_party/ffi/ffitarget_armv7.h delete mode 100644 third_party/ffi/ffitarget_x86_64.h diff --git a/lib/ios-arm64/libffi.a b/lib/ios-arm64/libffi.a deleted file mode 100644 index a79500e04e8033f56508eedd6e1cadb3ddc7236a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 54024 zcmd_Tf0R{KcJI3nhaaa3P*9W~0#!5^s(?~J6pfxxbkVUylBN|E8}U#U2sA$hv>~nO z(lX=GjrRqNNqpUXI|VwDQ>C4FdGxzgBi$_q#|Yh+j@YIz_YFI*K+QO(usfR9xwq9;CpF1UW-{ObN| z!J->)SiE5I!udB=SKm1Q1`=HIg8B1rTC}LTdcph~ZgRQTRc12R-F^S>Ec@JVSKs~l zyH`(Zg3fJmI16 zt{fgkmwEVAkLQm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J?K+)|sAHNrQB>KHM+{HHnXA{=B8sSR;$+BX& zgK0@D)%OfYW&ytkRJajHlk08+QiZx%K#Hi-K1!Ner@cH>z3vQiQBtgtq5MHUxBL8Wdwf6k>EA-G>iTDX%KxSh ze?j%<7xt~K_3er4BjrEl@%^EH{uxz->q(#gqz~`(^ zZ}Ro|FT%$!)aUONh9Sc~xVhlc{>NZ1e4FPL4*KybpH8%0|AYTZZ{(-zAovsx`uKM4 zeUhc$SQ6e&{&@OdmW01w5?0=L{yin((+U zuxL?r(~fOBHg4FyVaKB!6`?l`%fnlDH0|NchL5od_mi1Z7i^y2xr5^&g`*Z5ns#NZ wLdAshCoSSV&IybDPT|bQqq{cf=!KOFQTn@Js7=EQ=HKj2NX!qrhZzI^KOmj7t^fc4 diff --git a/src/com/phronemophobic/grease/membrane.clj b/src/com/phronemophobic/grease/membrane.clj index 6eeca42..729ca57 100644 --- a/src/com/phronemophobic/grease/membrane.clj +++ b/src/com/phronemophobic/grease/membrane.clj @@ -15,6 +15,8 @@ [com.phronemophobic.scify :as scify] [com.phronemophobic.grease.objc :as objc] [com.phronemophobic.objcjure :as objcjure] + com.phronemophobic.clj-libffi.callback + com.phronemophobic.clj-libffi [tech.v3.datatype.ffi :as dt-ffi] [tech.v3.datatype :as dtype] diff --git a/third_party/ffi/ffi.h b/third_party/ffi/ffi.h deleted file mode 100644 index c2480ba..0000000 --- a/third_party/ffi/ffi.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifdef __arm64__ - -#include - - -#endif -#ifdef __i386__ - -#include - - -#endif -#ifdef __arm__ - -#include - - -#endif -#ifdef __x86_64__ - -#include - - -#endif diff --git a/third_party/ffi/ffi_arm64.h b/third_party/ffi/ffi_arm64.h deleted file mode 100644 index 36fed9d..0000000 --- a/third_party/ffi/ffi_arm64.h +++ /dev/null @@ -1,533 +0,0 @@ -#ifdef __arm64__ - -/* -----------------------------------------------------------------*-C-*- - libffi 3.4.2 - - Copyright (c) 2011, 2014, 2019, 2021 Anthony Green - - Copyright (c) 1996-2003, 2007, 2008 Red Hat, Inc. - - Permission is hereby granted, free of charge, to any person - obtaining a copy of this software and associated documentation - files (the ``Software''), to deal in the Software without - restriction, including without limitation the rights to use, copy, - modify, merge, publish, distribute, sublicense, and/or sell copies - of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be - included in all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND - NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT - HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - DEALINGS IN THE SOFTWARE. - - ----------------------------------------------------------------------- */ - -/* ------------------------------------------------------------------- - Most of the API is documented in doc/libffi.texi. - - The raw API is designed to bypass some of the argument packing and - unpacking on architectures for which it can be avoided. Routines - are provided to emulate the raw API if the underlying platform - doesn't allow faster implementation. - - More details on the raw API can be found in: - - http://gcc.gnu.org/ml/java/1999-q3/msg00138.html - - and - - http://gcc.gnu.org/ml/java/1999-q3/msg00174.html - -------------------------------------------------------------------- */ - -#ifndef LIBFFI_H -#define LIBFFI_H - -#ifdef __cplusplus -extern "C" { -#endif - -/* Specify which architecture libffi is configured for. */ -#ifndef AARCH64 -#define AARCH64 -#endif - -/* ---- System configuration information --------------------------------- */ - -#include - -#ifndef LIBFFI_ASM - -#if defined(_MSC_VER) && !defined(__clang__) -#define __attribute__(X) -#endif - -#include -#include - -/* LONG_LONG_MAX is not always defined (not if STRICT_ANSI, for example). - But we can find it either under the correct ANSI name, or under GNU - C's internal name. */ - -#define FFI_64_BIT_MAX 9223372036854775807 - -#ifdef LONG_LONG_MAX -# define FFI_LONG_LONG_MAX LONG_LONG_MAX -#else -# ifdef LLONG_MAX -# define FFI_LONG_LONG_MAX LLONG_MAX -# ifdef _AIX52 /* or newer has C99 LLONG_MAX */ -# undef FFI_64_BIT_MAX -# define FFI_64_BIT_MAX 9223372036854775807LL -# endif /* _AIX52 or newer */ -# else -# ifdef __GNUC__ -# define FFI_LONG_LONG_MAX __LONG_LONG_MAX__ -# endif -# ifdef _AIX /* AIX 5.1 and earlier have LONGLONG_MAX */ -# ifndef __PPC64__ -# if defined (__IBMC__) || defined (__IBMCPP__) -# define FFI_LONG_LONG_MAX LONGLONG_MAX -# endif -# endif /* __PPC64__ */ -# undef FFI_64_BIT_MAX -# define FFI_64_BIT_MAX 9223372036854775807LL -# endif -# endif -#endif - -/* The closure code assumes that this works on pointers, i.e. a size_t - can hold a pointer. */ - -typedef struct _ffi_type -{ - size_t size; - unsigned short alignment; - unsigned short type; - struct _ffi_type **elements; -} ffi_type; - -/* Need minimal decorations for DLLs to work on Windows. GCC has - autoimport and autoexport. Always mark externally visible symbols - as dllimport for MSVC clients, even if it means an extra indirection - when using the static version of the library. - Besides, as a workaround, they can define FFI_BUILDING if they - *know* they are going to link with the static library. */ -#if defined _MSC_VER -# if defined FFI_BUILDING_DLL /* Building libffi.DLL with msvcc.sh */ -# define FFI_API __declspec(dllexport) -# elif !defined FFI_BUILDING /* Importing libffi.DLL */ -# define FFI_API __declspec(dllimport) -# else /* Building/linking static library */ -# define FFI_API -# endif -#else -# define FFI_API -#endif - -/* The externally visible type declarations also need the MSVC DLL - decorations, or they will not be exported from the object file. */ -#if defined LIBFFI_HIDE_BASIC_TYPES -# define FFI_EXTERN FFI_API -#else -# define FFI_EXTERN extern FFI_API -#endif - -#ifndef LIBFFI_HIDE_BASIC_TYPES -#if SCHAR_MAX == 127 -# define ffi_type_uchar ffi_type_uint8 -# define ffi_type_schar ffi_type_sint8 -#else - #error "char size not supported" -#endif - -#if SHRT_MAX == 32767 -# define ffi_type_ushort ffi_type_uint16 -# define ffi_type_sshort ffi_type_sint16 -#elif SHRT_MAX == 2147483647 -# define ffi_type_ushort ffi_type_uint32 -# define ffi_type_sshort ffi_type_sint32 -#else - #error "short size not supported" -#endif - -#if INT_MAX == 32767 -# define ffi_type_uint ffi_type_uint16 -# define ffi_type_sint ffi_type_sint16 -#elif INT_MAX == 2147483647 -# define ffi_type_uint ffi_type_uint32 -# define ffi_type_sint ffi_type_sint32 -#elif INT_MAX == 9223372036854775807 -# define ffi_type_uint ffi_type_uint64 -# define ffi_type_sint ffi_type_sint64 -#else - #error "int size not supported" -#endif - -#if LONG_MAX == 2147483647 -# if FFI_LONG_LONG_MAX != FFI_64_BIT_MAX - #error "no 64-bit data type supported" -# endif -#elif LONG_MAX != FFI_64_BIT_MAX - #error "long size not supported" -#endif - -#if LONG_MAX == 2147483647 -# define ffi_type_ulong ffi_type_uint32 -# define ffi_type_slong ffi_type_sint32 -#elif LONG_MAX == FFI_64_BIT_MAX -# define ffi_type_ulong ffi_type_uint64 -# define ffi_type_slong ffi_type_sint64 -#else - #error "long size not supported" -#endif - -/* These are defined in types.c. */ -FFI_EXTERN ffi_type ffi_type_void; -FFI_EXTERN ffi_type ffi_type_uint8; -FFI_EXTERN ffi_type ffi_type_sint8; -FFI_EXTERN ffi_type ffi_type_uint16; -FFI_EXTERN ffi_type ffi_type_sint16; -FFI_EXTERN ffi_type ffi_type_uint32; -FFI_EXTERN ffi_type ffi_type_sint32; -FFI_EXTERN ffi_type ffi_type_uint64; -FFI_EXTERN ffi_type ffi_type_sint64; -FFI_EXTERN ffi_type ffi_type_float; -FFI_EXTERN ffi_type ffi_type_double; -FFI_EXTERN ffi_type ffi_type_pointer; - -#if 0 -FFI_EXTERN ffi_type ffi_type_longdouble; -#else -#define ffi_type_longdouble ffi_type_double -#endif - -#ifdef FFI_TARGET_HAS_COMPLEX_TYPE -FFI_EXTERN ffi_type ffi_type_complex_float; -FFI_EXTERN ffi_type ffi_type_complex_double; -#if 0 -FFI_EXTERN ffi_type ffi_type_complex_longdouble; -#else -#define ffi_type_complex_longdouble ffi_type_complex_double -#endif -#endif -#endif /* LIBFFI_HIDE_BASIC_TYPES */ - -typedef enum { - FFI_OK = 0, - FFI_BAD_TYPEDEF, - FFI_BAD_ABI, - FFI_BAD_ARGTYPE -} ffi_status; - -typedef struct { - ffi_abi abi; - unsigned nargs; - ffi_type **arg_types; - ffi_type *rtype; - unsigned bytes; - unsigned flags; -#ifdef FFI_EXTRA_CIF_FIELDS - FFI_EXTRA_CIF_FIELDS; -#endif -} ffi_cif; - -/* ---- Definitions for the raw API -------------------------------------- */ - -#ifndef FFI_SIZEOF_ARG -# if LONG_MAX == 2147483647 -# define FFI_SIZEOF_ARG 4 -# elif LONG_MAX == FFI_64_BIT_MAX -# define FFI_SIZEOF_ARG 8 -# endif -#endif - -#ifndef FFI_SIZEOF_JAVA_RAW -# define FFI_SIZEOF_JAVA_RAW FFI_SIZEOF_ARG -#endif - -typedef union { - ffi_sarg sint; - ffi_arg uint; - float flt; - char data[FFI_SIZEOF_ARG]; - void* ptr; -} ffi_raw; - -#if FFI_SIZEOF_JAVA_RAW == 4 && FFI_SIZEOF_ARG == 8 -/* This is a special case for mips64/n32 ABI (and perhaps others) where - sizeof(void *) is 4 and FFI_SIZEOF_ARG is 8. */ -typedef union { - signed int sint; - unsigned int uint; - float flt; - char data[FFI_SIZEOF_JAVA_RAW]; - void* ptr; -} ffi_java_raw; -#else -typedef ffi_raw ffi_java_raw; -#endif - - -FFI_API -void ffi_raw_call (ffi_cif *cif, - void (*fn)(void), - void *rvalue, - ffi_raw *avalue); - -FFI_API void ffi_ptrarray_to_raw (ffi_cif *cif, void **args, ffi_raw *raw); -FFI_API void ffi_raw_to_ptrarray (ffi_cif *cif, ffi_raw *raw, void **args); -FFI_API size_t ffi_raw_size (ffi_cif *cif); - -/* This is analogous to the raw API, except it uses Java parameter - packing, even on 64-bit machines. I.e. on 64-bit machines longs - and doubles are followed by an empty 64-bit word. */ - -#if !FFI_NATIVE_RAW_API -FFI_API -void ffi_java_raw_call (ffi_cif *cif, - void (*fn)(void), - void *rvalue, - ffi_java_raw *avalue) __attribute__((deprecated)); -#endif - -FFI_API -void ffi_java_ptrarray_to_raw (ffi_cif *cif, void **args, ffi_java_raw *raw) __attribute__((deprecated)); -FFI_API -void ffi_java_raw_to_ptrarray (ffi_cif *cif, ffi_java_raw *raw, void **args) __attribute__((deprecated)); -FFI_API -size_t ffi_java_raw_size (ffi_cif *cif) __attribute__((deprecated)); - -/* ---- Definitions for closures ----------------------------------------- */ - -#if FFI_CLOSURES - -#ifdef _MSC_VER -__declspec(align(8)) -#endif -typedef struct { -#if 1 - void *trampoline_table; - void *trampoline_table_entry; -#else - union { - char tramp[FFI_TRAMPOLINE_SIZE]; - void *ftramp; - }; -#endif - ffi_cif *cif; - void (*fun)(ffi_cif*,void*,void**,void*); - void *user_data; -} ffi_closure -#ifdef __GNUC__ - __attribute__((aligned (8))) -#endif - ; - -#ifndef __GNUC__ -# ifdef __sgi -# pragma pack 0 -# endif -#endif - -FFI_API void *ffi_closure_alloc (size_t size, void **code); -FFI_API void ffi_closure_free (void *); - -#if defined(PA_LINUX) || defined(PA_HPUX) -#define FFI_CLOSURE_PTR(X) ((void *)((unsigned int)(X) | 2)) -#define FFI_RESTORE_PTR(X) ((void *)((unsigned int)(X) & ~3)) -#else -#define FFI_CLOSURE_PTR(X) (X) -#define FFI_RESTORE_PTR(X) (X) -#endif - -FFI_API ffi_status -ffi_prep_closure (ffi_closure*, - ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*), - void *user_data) -#if defined(__GNUC__) && (((__GNUC__ * 100) + __GNUC_MINOR__) >= 405) - __attribute__((deprecated ("use ffi_prep_closure_loc instead"))) -#elif defined(__GNUC__) && __GNUC__ >= 3 - __attribute__((deprecated)) -#endif - ; - -FFI_API ffi_status -ffi_prep_closure_loc (ffi_closure*, - ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*), - void *user_data, - void*codeloc); - -#ifdef __sgi -# pragma pack 8 -#endif -typedef struct { -#if 1 - void *trampoline_table; - void *trampoline_table_entry; -#else - char tramp[FFI_TRAMPOLINE_SIZE]; -#endif - ffi_cif *cif; - -#if !FFI_NATIVE_RAW_API - - /* If this is enabled, then a raw closure has the same layout - as a regular closure. We use this to install an intermediate - handler to do the transaltion, void** -> ffi_raw*. */ - - void (*translate_args)(ffi_cif*,void*,void**,void*); - void *this_closure; - -#endif - - void (*fun)(ffi_cif*,void*,ffi_raw*,void*); - void *user_data; - -} ffi_raw_closure; - -typedef struct { -#if 1 - void *trampoline_table; - void *trampoline_table_entry; -#else - char tramp[FFI_TRAMPOLINE_SIZE]; -#endif - - ffi_cif *cif; - -#if !FFI_NATIVE_RAW_API - - /* If this is enabled, then a raw closure has the same layout - as a regular closure. We use this to install an intermediate - handler to do the translation, void** -> ffi_raw*. */ - - void (*translate_args)(ffi_cif*,void*,void**,void*); - void *this_closure; - -#endif - - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*); - void *user_data; - -} ffi_java_raw_closure; - -FFI_API ffi_status -ffi_prep_raw_closure (ffi_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_raw*,void*), - void *user_data); - -FFI_API ffi_status -ffi_prep_raw_closure_loc (ffi_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_raw*,void*), - void *user_data, - void *codeloc); - -#if !FFI_NATIVE_RAW_API -FFI_API ffi_status -ffi_prep_java_raw_closure (ffi_java_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*), - void *user_data) __attribute__((deprecated)); - -FFI_API ffi_status -ffi_prep_java_raw_closure_loc (ffi_java_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*), - void *user_data, - void *codeloc) __attribute__((deprecated)); -#endif - -#endif /* FFI_CLOSURES */ - -#if FFI_GO_CLOSURES - -typedef struct { - void *tramp; - ffi_cif *cif; - void (*fun)(ffi_cif*,void*,void**,void*); -} ffi_go_closure; - -FFI_API ffi_status ffi_prep_go_closure (ffi_go_closure*, ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*)); - -FFI_API void ffi_call_go (ffi_cif *cif, void (*fn)(void), void *rvalue, - void **avalue, void *closure); - -#endif /* FFI_GO_CLOSURES */ - -/* ---- Public interface definition -------------------------------------- */ - -FFI_API -ffi_status ffi_prep_cif(ffi_cif *cif, - ffi_abi abi, - unsigned int nargs, - ffi_type *rtype, - ffi_type **atypes); - -FFI_API -ffi_status ffi_prep_cif_var(ffi_cif *cif, - ffi_abi abi, - unsigned int nfixedargs, - unsigned int ntotalargs, - ffi_type *rtype, - ffi_type **atypes); - -FFI_API -void ffi_call(ffi_cif *cif, - void (*fn)(void), - void *rvalue, - void **avalue); - -FFI_API -ffi_status ffi_get_struct_offsets (ffi_abi abi, ffi_type *struct_type, - size_t *offsets); - -/* Useful for eliminating compiler warnings. */ -#define FFI_FN(f) ((void (*)(void))f) - -/* ---- Definitions shared with assembly code ---------------------------- */ - -#endif - -/* If these change, update src/mips/ffitarget.h. */ -#define FFI_TYPE_VOID 0 -#define FFI_TYPE_INT 1 -#define FFI_TYPE_FLOAT 2 -#define FFI_TYPE_DOUBLE 3 -#if 0 -#define FFI_TYPE_LONGDOUBLE 4 -#else -#define FFI_TYPE_LONGDOUBLE FFI_TYPE_DOUBLE -#endif -#define FFI_TYPE_UINT8 5 -#define FFI_TYPE_SINT8 6 -#define FFI_TYPE_UINT16 7 -#define FFI_TYPE_SINT16 8 -#define FFI_TYPE_UINT32 9 -#define FFI_TYPE_SINT32 10 -#define FFI_TYPE_UINT64 11 -#define FFI_TYPE_SINT64 12 -#define FFI_TYPE_STRUCT 13 -#define FFI_TYPE_POINTER 14 -#define FFI_TYPE_COMPLEX 15 - -/* This should always refer to the last type code (for sanity checks). */ -#define FFI_TYPE_LAST FFI_TYPE_COMPLEX - -#ifdef __cplusplus -} -#endif - -#endif - - -#endif \ No newline at end of file diff --git a/third_party/ffi/ffi_armv7.h b/third_party/ffi/ffi_armv7.h deleted file mode 100644 index fd46dc0..0000000 --- a/third_party/ffi/ffi_armv7.h +++ /dev/null @@ -1,533 +0,0 @@ -#ifdef __arm__ - -/* -----------------------------------------------------------------*-C-*- - libffi 3.4.2 - - Copyright (c) 2011, 2014, 2019, 2021 Anthony Green - - Copyright (c) 1996-2003, 2007, 2008 Red Hat, Inc. - - Permission is hereby granted, free of charge, to any person - obtaining a copy of this software and associated documentation - files (the ``Software''), to deal in the Software without - restriction, including without limitation the rights to use, copy, - modify, merge, publish, distribute, sublicense, and/or sell copies - of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be - included in all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND - NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT - HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - DEALINGS IN THE SOFTWARE. - - ----------------------------------------------------------------------- */ - -/* ------------------------------------------------------------------- - Most of the API is documented in doc/libffi.texi. - - The raw API is designed to bypass some of the argument packing and - unpacking on architectures for which it can be avoided. Routines - are provided to emulate the raw API if the underlying platform - doesn't allow faster implementation. - - More details on the raw API can be found in: - - http://gcc.gnu.org/ml/java/1999-q3/msg00138.html - - and - - http://gcc.gnu.org/ml/java/1999-q3/msg00174.html - -------------------------------------------------------------------- */ - -#ifndef LIBFFI_H -#define LIBFFI_H - -#ifdef __cplusplus -extern "C" { -#endif - -/* Specify which architecture libffi is configured for. */ -#ifndef ARM -#define ARM -#endif - -/* ---- System configuration information --------------------------------- */ - -#include - -#ifndef LIBFFI_ASM - -#if defined(_MSC_VER) && !defined(__clang__) -#define __attribute__(X) -#endif - -#include -#include - -/* LONG_LONG_MAX is not always defined (not if STRICT_ANSI, for example). - But we can find it either under the correct ANSI name, or under GNU - C's internal name. */ - -#define FFI_64_BIT_MAX 9223372036854775807 - -#ifdef LONG_LONG_MAX -# define FFI_LONG_LONG_MAX LONG_LONG_MAX -#else -# ifdef LLONG_MAX -# define FFI_LONG_LONG_MAX LLONG_MAX -# ifdef _AIX52 /* or newer has C99 LLONG_MAX */ -# undef FFI_64_BIT_MAX -# define FFI_64_BIT_MAX 9223372036854775807LL -# endif /* _AIX52 or newer */ -# else -# ifdef __GNUC__ -# define FFI_LONG_LONG_MAX __LONG_LONG_MAX__ -# endif -# ifdef _AIX /* AIX 5.1 and earlier have LONGLONG_MAX */ -# ifndef __PPC64__ -# if defined (__IBMC__) || defined (__IBMCPP__) -# define FFI_LONG_LONG_MAX LONGLONG_MAX -# endif -# endif /* __PPC64__ */ -# undef FFI_64_BIT_MAX -# define FFI_64_BIT_MAX 9223372036854775807LL -# endif -# endif -#endif - -/* The closure code assumes that this works on pointers, i.e. a size_t - can hold a pointer. */ - -typedef struct _ffi_type -{ - size_t size; - unsigned short alignment; - unsigned short type; - struct _ffi_type **elements; -} ffi_type; - -/* Need minimal decorations for DLLs to work on Windows. GCC has - autoimport and autoexport. Always mark externally visible symbols - as dllimport for MSVC clients, even if it means an extra indirection - when using the static version of the library. - Besides, as a workaround, they can define FFI_BUILDING if they - *know* they are going to link with the static library. */ -#if defined _MSC_VER -# if defined FFI_BUILDING_DLL /* Building libffi.DLL with msvcc.sh */ -# define FFI_API __declspec(dllexport) -# elif !defined FFI_BUILDING /* Importing libffi.DLL */ -# define FFI_API __declspec(dllimport) -# else /* Building/linking static library */ -# define FFI_API -# endif -#else -# define FFI_API -#endif - -/* The externally visible type declarations also need the MSVC DLL - decorations, or they will not be exported from the object file. */ -#if defined LIBFFI_HIDE_BASIC_TYPES -# define FFI_EXTERN FFI_API -#else -# define FFI_EXTERN extern FFI_API -#endif - -#ifndef LIBFFI_HIDE_BASIC_TYPES -#if SCHAR_MAX == 127 -# define ffi_type_uchar ffi_type_uint8 -# define ffi_type_schar ffi_type_sint8 -#else - #error "char size not supported" -#endif - -#if SHRT_MAX == 32767 -# define ffi_type_ushort ffi_type_uint16 -# define ffi_type_sshort ffi_type_sint16 -#elif SHRT_MAX == 2147483647 -# define ffi_type_ushort ffi_type_uint32 -# define ffi_type_sshort ffi_type_sint32 -#else - #error "short size not supported" -#endif - -#if INT_MAX == 32767 -# define ffi_type_uint ffi_type_uint16 -# define ffi_type_sint ffi_type_sint16 -#elif INT_MAX == 2147483647 -# define ffi_type_uint ffi_type_uint32 -# define ffi_type_sint ffi_type_sint32 -#elif INT_MAX == 9223372036854775807 -# define ffi_type_uint ffi_type_uint64 -# define ffi_type_sint ffi_type_sint64 -#else - #error "int size not supported" -#endif - -#if LONG_MAX == 2147483647 -# if FFI_LONG_LONG_MAX != FFI_64_BIT_MAX - #error "no 64-bit data type supported" -# endif -#elif LONG_MAX != FFI_64_BIT_MAX - #error "long size not supported" -#endif - -#if LONG_MAX == 2147483647 -# define ffi_type_ulong ffi_type_uint32 -# define ffi_type_slong ffi_type_sint32 -#elif LONG_MAX == FFI_64_BIT_MAX -# define ffi_type_ulong ffi_type_uint64 -# define ffi_type_slong ffi_type_sint64 -#else - #error "long size not supported" -#endif - -/* These are defined in types.c. */ -FFI_EXTERN ffi_type ffi_type_void; -FFI_EXTERN ffi_type ffi_type_uint8; -FFI_EXTERN ffi_type ffi_type_sint8; -FFI_EXTERN ffi_type ffi_type_uint16; -FFI_EXTERN ffi_type ffi_type_sint16; -FFI_EXTERN ffi_type ffi_type_uint32; -FFI_EXTERN ffi_type ffi_type_sint32; -FFI_EXTERN ffi_type ffi_type_uint64; -FFI_EXTERN ffi_type ffi_type_sint64; -FFI_EXTERN ffi_type ffi_type_float; -FFI_EXTERN ffi_type ffi_type_double; -FFI_EXTERN ffi_type ffi_type_pointer; - -#if 0 -FFI_EXTERN ffi_type ffi_type_longdouble; -#else -#define ffi_type_longdouble ffi_type_double -#endif - -#ifdef FFI_TARGET_HAS_COMPLEX_TYPE -FFI_EXTERN ffi_type ffi_type_complex_float; -FFI_EXTERN ffi_type ffi_type_complex_double; -#if 0 -FFI_EXTERN ffi_type ffi_type_complex_longdouble; -#else -#define ffi_type_complex_longdouble ffi_type_complex_double -#endif -#endif -#endif /* LIBFFI_HIDE_BASIC_TYPES */ - -typedef enum { - FFI_OK = 0, - FFI_BAD_TYPEDEF, - FFI_BAD_ABI, - FFI_BAD_ARGTYPE -} ffi_status; - -typedef struct { - ffi_abi abi; - unsigned nargs; - ffi_type **arg_types; - ffi_type *rtype; - unsigned bytes; - unsigned flags; -#ifdef FFI_EXTRA_CIF_FIELDS - FFI_EXTRA_CIF_FIELDS; -#endif -} ffi_cif; - -/* ---- Definitions for the raw API -------------------------------------- */ - -#ifndef FFI_SIZEOF_ARG -# if LONG_MAX == 2147483647 -# define FFI_SIZEOF_ARG 4 -# elif LONG_MAX == FFI_64_BIT_MAX -# define FFI_SIZEOF_ARG 8 -# endif -#endif - -#ifndef FFI_SIZEOF_JAVA_RAW -# define FFI_SIZEOF_JAVA_RAW FFI_SIZEOF_ARG -#endif - -typedef union { - ffi_sarg sint; - ffi_arg uint; - float flt; - char data[FFI_SIZEOF_ARG]; - void* ptr; -} ffi_raw; - -#if FFI_SIZEOF_JAVA_RAW == 4 && FFI_SIZEOF_ARG == 8 -/* This is a special case for mips64/n32 ABI (and perhaps others) where - sizeof(void *) is 4 and FFI_SIZEOF_ARG is 8. */ -typedef union { - signed int sint; - unsigned int uint; - float flt; - char data[FFI_SIZEOF_JAVA_RAW]; - void* ptr; -} ffi_java_raw; -#else -typedef ffi_raw ffi_java_raw; -#endif - - -FFI_API -void ffi_raw_call (ffi_cif *cif, - void (*fn)(void), - void *rvalue, - ffi_raw *avalue); - -FFI_API void ffi_ptrarray_to_raw (ffi_cif *cif, void **args, ffi_raw *raw); -FFI_API void ffi_raw_to_ptrarray (ffi_cif *cif, ffi_raw *raw, void **args); -FFI_API size_t ffi_raw_size (ffi_cif *cif); - -/* This is analogous to the raw API, except it uses Java parameter - packing, even on 64-bit machines. I.e. on 64-bit machines longs - and doubles are followed by an empty 64-bit word. */ - -#if !FFI_NATIVE_RAW_API -FFI_API -void ffi_java_raw_call (ffi_cif *cif, - void (*fn)(void), - void *rvalue, - ffi_java_raw *avalue) __attribute__((deprecated)); -#endif - -FFI_API -void ffi_java_ptrarray_to_raw (ffi_cif *cif, void **args, ffi_java_raw *raw) __attribute__((deprecated)); -FFI_API -void ffi_java_raw_to_ptrarray (ffi_cif *cif, ffi_java_raw *raw, void **args) __attribute__((deprecated)); -FFI_API -size_t ffi_java_raw_size (ffi_cif *cif) __attribute__((deprecated)); - -/* ---- Definitions for closures ----------------------------------------- */ - -#if FFI_CLOSURES - -#ifdef _MSC_VER -__declspec(align(8)) -#endif -typedef struct { -#if 1 - void *trampoline_table; - void *trampoline_table_entry; -#else - union { - char tramp[FFI_TRAMPOLINE_SIZE]; - void *ftramp; - }; -#endif - ffi_cif *cif; - void (*fun)(ffi_cif*,void*,void**,void*); - void *user_data; -} ffi_closure -#ifdef __GNUC__ - __attribute__((aligned (8))) -#endif - ; - -#ifndef __GNUC__ -# ifdef __sgi -# pragma pack 0 -# endif -#endif - -FFI_API void *ffi_closure_alloc (size_t size, void **code); -FFI_API void ffi_closure_free (void *); - -#if defined(PA_LINUX) || defined(PA_HPUX) -#define FFI_CLOSURE_PTR(X) ((void *)((unsigned int)(X) | 2)) -#define FFI_RESTORE_PTR(X) ((void *)((unsigned int)(X) & ~3)) -#else -#define FFI_CLOSURE_PTR(X) (X) -#define FFI_RESTORE_PTR(X) (X) -#endif - -FFI_API ffi_status -ffi_prep_closure (ffi_closure*, - ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*), - void *user_data) -#if defined(__GNUC__) && (((__GNUC__ * 100) + __GNUC_MINOR__) >= 405) - __attribute__((deprecated ("use ffi_prep_closure_loc instead"))) -#elif defined(__GNUC__) && __GNUC__ >= 3 - __attribute__((deprecated)) -#endif - ; - -FFI_API ffi_status -ffi_prep_closure_loc (ffi_closure*, - ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*), - void *user_data, - void*codeloc); - -#ifdef __sgi -# pragma pack 8 -#endif -typedef struct { -#if 1 - void *trampoline_table; - void *trampoline_table_entry; -#else - char tramp[FFI_TRAMPOLINE_SIZE]; -#endif - ffi_cif *cif; - -#if !FFI_NATIVE_RAW_API - - /* If this is enabled, then a raw closure has the same layout - as a regular closure. We use this to install an intermediate - handler to do the transaltion, void** -> ffi_raw*. */ - - void (*translate_args)(ffi_cif*,void*,void**,void*); - void *this_closure; - -#endif - - void (*fun)(ffi_cif*,void*,ffi_raw*,void*); - void *user_data; - -} ffi_raw_closure; - -typedef struct { -#if 1 - void *trampoline_table; - void *trampoline_table_entry; -#else - char tramp[FFI_TRAMPOLINE_SIZE]; -#endif - - ffi_cif *cif; - -#if !FFI_NATIVE_RAW_API - - /* If this is enabled, then a raw closure has the same layout - as a regular closure. We use this to install an intermediate - handler to do the translation, void** -> ffi_raw*. */ - - void (*translate_args)(ffi_cif*,void*,void**,void*); - void *this_closure; - -#endif - - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*); - void *user_data; - -} ffi_java_raw_closure; - -FFI_API ffi_status -ffi_prep_raw_closure (ffi_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_raw*,void*), - void *user_data); - -FFI_API ffi_status -ffi_prep_raw_closure_loc (ffi_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_raw*,void*), - void *user_data, - void *codeloc); - -#if !FFI_NATIVE_RAW_API -FFI_API ffi_status -ffi_prep_java_raw_closure (ffi_java_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*), - void *user_data) __attribute__((deprecated)); - -FFI_API ffi_status -ffi_prep_java_raw_closure_loc (ffi_java_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*), - void *user_data, - void *codeloc) __attribute__((deprecated)); -#endif - -#endif /* FFI_CLOSURES */ - -#if FFI_GO_CLOSURES - -typedef struct { - void *tramp; - ffi_cif *cif; - void (*fun)(ffi_cif*,void*,void**,void*); -} ffi_go_closure; - -FFI_API ffi_status ffi_prep_go_closure (ffi_go_closure*, ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*)); - -FFI_API void ffi_call_go (ffi_cif *cif, void (*fn)(void), void *rvalue, - void **avalue, void *closure); - -#endif /* FFI_GO_CLOSURES */ - -/* ---- Public interface definition -------------------------------------- */ - -FFI_API -ffi_status ffi_prep_cif(ffi_cif *cif, - ffi_abi abi, - unsigned int nargs, - ffi_type *rtype, - ffi_type **atypes); - -FFI_API -ffi_status ffi_prep_cif_var(ffi_cif *cif, - ffi_abi abi, - unsigned int nfixedargs, - unsigned int ntotalargs, - ffi_type *rtype, - ffi_type **atypes); - -FFI_API -void ffi_call(ffi_cif *cif, - void (*fn)(void), - void *rvalue, - void **avalue); - -FFI_API -ffi_status ffi_get_struct_offsets (ffi_abi abi, ffi_type *struct_type, - size_t *offsets); - -/* Useful for eliminating compiler warnings. */ -#define FFI_FN(f) ((void (*)(void))f) - -/* ---- Definitions shared with assembly code ---------------------------- */ - -#endif - -/* If these change, update src/mips/ffitarget.h. */ -#define FFI_TYPE_VOID 0 -#define FFI_TYPE_INT 1 -#define FFI_TYPE_FLOAT 2 -#define FFI_TYPE_DOUBLE 3 -#if 0 -#define FFI_TYPE_LONGDOUBLE 4 -#else -#define FFI_TYPE_LONGDOUBLE FFI_TYPE_DOUBLE -#endif -#define FFI_TYPE_UINT8 5 -#define FFI_TYPE_SINT8 6 -#define FFI_TYPE_UINT16 7 -#define FFI_TYPE_SINT16 8 -#define FFI_TYPE_UINT32 9 -#define FFI_TYPE_SINT32 10 -#define FFI_TYPE_UINT64 11 -#define FFI_TYPE_SINT64 12 -#define FFI_TYPE_STRUCT 13 -#define FFI_TYPE_POINTER 14 -#define FFI_TYPE_COMPLEX 15 - -/* This should always refer to the last type code (for sanity checks). */ -#define FFI_TYPE_LAST FFI_TYPE_COMPLEX - -#ifdef __cplusplus -} -#endif - -#endif - - -#endif \ No newline at end of file diff --git a/third_party/ffi/ffi_x86_64.h b/third_party/ffi/ffi_x86_64.h deleted file mode 100644 index 6331671..0000000 --- a/third_party/ffi/ffi_x86_64.h +++ /dev/null @@ -1,533 +0,0 @@ -#ifdef __x86_64__ - -/* -----------------------------------------------------------------*-C-*- - libffi 3.4.2 - - Copyright (c) 2011, 2014, 2019, 2021 Anthony Green - - Copyright (c) 1996-2003, 2007, 2008 Red Hat, Inc. - - Permission is hereby granted, free of charge, to any person - obtaining a copy of this software and associated documentation - files (the ``Software''), to deal in the Software without - restriction, including without limitation the rights to use, copy, - modify, merge, publish, distribute, sublicense, and/or sell copies - of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be - included in all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND - NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT - HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - DEALINGS IN THE SOFTWARE. - - ----------------------------------------------------------------------- */ - -/* ------------------------------------------------------------------- - Most of the API is documented in doc/libffi.texi. - - The raw API is designed to bypass some of the argument packing and - unpacking on architectures for which it can be avoided. Routines - are provided to emulate the raw API if the underlying platform - doesn't allow faster implementation. - - More details on the raw API can be found in: - - http://gcc.gnu.org/ml/java/1999-q3/msg00138.html - - and - - http://gcc.gnu.org/ml/java/1999-q3/msg00174.html - -------------------------------------------------------------------- */ - -#ifndef LIBFFI_H -#define LIBFFI_H - -#ifdef __cplusplus -extern "C" { -#endif - -/* Specify which architecture libffi is configured for. */ -#ifndef X86_64 -#define X86_64 -#endif - -/* ---- System configuration information --------------------------------- */ - -#include - -#ifndef LIBFFI_ASM - -#if defined(_MSC_VER) && !defined(__clang__) -#define __attribute__(X) -#endif - -#include -#include - -/* LONG_LONG_MAX is not always defined (not if STRICT_ANSI, for example). - But we can find it either under the correct ANSI name, or under GNU - C's internal name. */ - -#define FFI_64_BIT_MAX 9223372036854775807 - -#ifdef LONG_LONG_MAX -# define FFI_LONG_LONG_MAX LONG_LONG_MAX -#else -# ifdef LLONG_MAX -# define FFI_LONG_LONG_MAX LLONG_MAX -# ifdef _AIX52 /* or newer has C99 LLONG_MAX */ -# undef FFI_64_BIT_MAX -# define FFI_64_BIT_MAX 9223372036854775807LL -# endif /* _AIX52 or newer */ -# else -# ifdef __GNUC__ -# define FFI_LONG_LONG_MAX __LONG_LONG_MAX__ -# endif -# ifdef _AIX /* AIX 5.1 and earlier have LONGLONG_MAX */ -# ifndef __PPC64__ -# if defined (__IBMC__) || defined (__IBMCPP__) -# define FFI_LONG_LONG_MAX LONGLONG_MAX -# endif -# endif /* __PPC64__ */ -# undef FFI_64_BIT_MAX -# define FFI_64_BIT_MAX 9223372036854775807LL -# endif -# endif -#endif - -/* The closure code assumes that this works on pointers, i.e. a size_t - can hold a pointer. */ - -typedef struct _ffi_type -{ - size_t size; - unsigned short alignment; - unsigned short type; - struct _ffi_type **elements; -} ffi_type; - -/* Need minimal decorations for DLLs to work on Windows. GCC has - autoimport and autoexport. Always mark externally visible symbols - as dllimport for MSVC clients, even if it means an extra indirection - when using the static version of the library. - Besides, as a workaround, they can define FFI_BUILDING if they - *know* they are going to link with the static library. */ -#if defined _MSC_VER -# if defined FFI_BUILDING_DLL /* Building libffi.DLL with msvcc.sh */ -# define FFI_API __declspec(dllexport) -# elif !defined FFI_BUILDING /* Importing libffi.DLL */ -# define FFI_API __declspec(dllimport) -# else /* Building/linking static library */ -# define FFI_API -# endif -#else -# define FFI_API -#endif - -/* The externally visible type declarations also need the MSVC DLL - decorations, or they will not be exported from the object file. */ -#if defined LIBFFI_HIDE_BASIC_TYPES -# define FFI_EXTERN FFI_API -#else -# define FFI_EXTERN extern FFI_API -#endif - -#ifndef LIBFFI_HIDE_BASIC_TYPES -#if SCHAR_MAX == 127 -# define ffi_type_uchar ffi_type_uint8 -# define ffi_type_schar ffi_type_sint8 -#else - #error "char size not supported" -#endif - -#if SHRT_MAX == 32767 -# define ffi_type_ushort ffi_type_uint16 -# define ffi_type_sshort ffi_type_sint16 -#elif SHRT_MAX == 2147483647 -# define ffi_type_ushort ffi_type_uint32 -# define ffi_type_sshort ffi_type_sint32 -#else - #error "short size not supported" -#endif - -#if INT_MAX == 32767 -# define ffi_type_uint ffi_type_uint16 -# define ffi_type_sint ffi_type_sint16 -#elif INT_MAX == 2147483647 -# define ffi_type_uint ffi_type_uint32 -# define ffi_type_sint ffi_type_sint32 -#elif INT_MAX == 9223372036854775807 -# define ffi_type_uint ffi_type_uint64 -# define ffi_type_sint ffi_type_sint64 -#else - #error "int size not supported" -#endif - -#if LONG_MAX == 2147483647 -# if FFI_LONG_LONG_MAX != FFI_64_BIT_MAX - #error "no 64-bit data type supported" -# endif -#elif LONG_MAX != FFI_64_BIT_MAX - #error "long size not supported" -#endif - -#if LONG_MAX == 2147483647 -# define ffi_type_ulong ffi_type_uint32 -# define ffi_type_slong ffi_type_sint32 -#elif LONG_MAX == FFI_64_BIT_MAX -# define ffi_type_ulong ffi_type_uint64 -# define ffi_type_slong ffi_type_sint64 -#else - #error "long size not supported" -#endif - -/* These are defined in types.c. */ -FFI_EXTERN ffi_type ffi_type_void; -FFI_EXTERN ffi_type ffi_type_uint8; -FFI_EXTERN ffi_type ffi_type_sint8; -FFI_EXTERN ffi_type ffi_type_uint16; -FFI_EXTERN ffi_type ffi_type_sint16; -FFI_EXTERN ffi_type ffi_type_uint32; -FFI_EXTERN ffi_type ffi_type_sint32; -FFI_EXTERN ffi_type ffi_type_uint64; -FFI_EXTERN ffi_type ffi_type_sint64; -FFI_EXTERN ffi_type ffi_type_float; -FFI_EXTERN ffi_type ffi_type_double; -FFI_EXTERN ffi_type ffi_type_pointer; - -#if 1 -FFI_EXTERN ffi_type ffi_type_longdouble; -#else -#define ffi_type_longdouble ffi_type_double -#endif - -#ifdef FFI_TARGET_HAS_COMPLEX_TYPE -FFI_EXTERN ffi_type ffi_type_complex_float; -FFI_EXTERN ffi_type ffi_type_complex_double; -#if 1 -FFI_EXTERN ffi_type ffi_type_complex_longdouble; -#else -#define ffi_type_complex_longdouble ffi_type_complex_double -#endif -#endif -#endif /* LIBFFI_HIDE_BASIC_TYPES */ - -typedef enum { - FFI_OK = 0, - FFI_BAD_TYPEDEF, - FFI_BAD_ABI, - FFI_BAD_ARGTYPE -} ffi_status; - -typedef struct { - ffi_abi abi; - unsigned nargs; - ffi_type **arg_types; - ffi_type *rtype; - unsigned bytes; - unsigned flags; -#ifdef FFI_EXTRA_CIF_FIELDS - FFI_EXTRA_CIF_FIELDS; -#endif -} ffi_cif; - -/* ---- Definitions for the raw API -------------------------------------- */ - -#ifndef FFI_SIZEOF_ARG -# if LONG_MAX == 2147483647 -# define FFI_SIZEOF_ARG 4 -# elif LONG_MAX == FFI_64_BIT_MAX -# define FFI_SIZEOF_ARG 8 -# endif -#endif - -#ifndef FFI_SIZEOF_JAVA_RAW -# define FFI_SIZEOF_JAVA_RAW FFI_SIZEOF_ARG -#endif - -typedef union { - ffi_sarg sint; - ffi_arg uint; - float flt; - char data[FFI_SIZEOF_ARG]; - void* ptr; -} ffi_raw; - -#if FFI_SIZEOF_JAVA_RAW == 4 && FFI_SIZEOF_ARG == 8 -/* This is a special case for mips64/n32 ABI (and perhaps others) where - sizeof(void *) is 4 and FFI_SIZEOF_ARG is 8. */ -typedef union { - signed int sint; - unsigned int uint; - float flt; - char data[FFI_SIZEOF_JAVA_RAW]; - void* ptr; -} ffi_java_raw; -#else -typedef ffi_raw ffi_java_raw; -#endif - - -FFI_API -void ffi_raw_call (ffi_cif *cif, - void (*fn)(void), - void *rvalue, - ffi_raw *avalue); - -FFI_API void ffi_ptrarray_to_raw (ffi_cif *cif, void **args, ffi_raw *raw); -FFI_API void ffi_raw_to_ptrarray (ffi_cif *cif, ffi_raw *raw, void **args); -FFI_API size_t ffi_raw_size (ffi_cif *cif); - -/* This is analogous to the raw API, except it uses Java parameter - packing, even on 64-bit machines. I.e. on 64-bit machines longs - and doubles are followed by an empty 64-bit word. */ - -#if !FFI_NATIVE_RAW_API -FFI_API -void ffi_java_raw_call (ffi_cif *cif, - void (*fn)(void), - void *rvalue, - ffi_java_raw *avalue) __attribute__((deprecated)); -#endif - -FFI_API -void ffi_java_ptrarray_to_raw (ffi_cif *cif, void **args, ffi_java_raw *raw) __attribute__((deprecated)); -FFI_API -void ffi_java_raw_to_ptrarray (ffi_cif *cif, ffi_java_raw *raw, void **args) __attribute__((deprecated)); -FFI_API -size_t ffi_java_raw_size (ffi_cif *cif) __attribute__((deprecated)); - -/* ---- Definitions for closures ----------------------------------------- */ - -#if FFI_CLOSURES - -#ifdef _MSC_VER -__declspec(align(8)) -#endif -typedef struct { -#if 0 - void *trampoline_table; - void *trampoline_table_entry; -#else - union { - char tramp[FFI_TRAMPOLINE_SIZE]; - void *ftramp; - }; -#endif - ffi_cif *cif; - void (*fun)(ffi_cif*,void*,void**,void*); - void *user_data; -} ffi_closure -#ifdef __GNUC__ - __attribute__((aligned (8))) -#endif - ; - -#ifndef __GNUC__ -# ifdef __sgi -# pragma pack 0 -# endif -#endif - -FFI_API void *ffi_closure_alloc (size_t size, void **code); -FFI_API void ffi_closure_free (void *); - -#if defined(PA_LINUX) || defined(PA_HPUX) -#define FFI_CLOSURE_PTR(X) ((void *)((unsigned int)(X) | 2)) -#define FFI_RESTORE_PTR(X) ((void *)((unsigned int)(X) & ~3)) -#else -#define FFI_CLOSURE_PTR(X) (X) -#define FFI_RESTORE_PTR(X) (X) -#endif - -FFI_API ffi_status -ffi_prep_closure (ffi_closure*, - ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*), - void *user_data) -#if defined(__GNUC__) && (((__GNUC__ * 100) + __GNUC_MINOR__) >= 405) - __attribute__((deprecated ("use ffi_prep_closure_loc instead"))) -#elif defined(__GNUC__) && __GNUC__ >= 3 - __attribute__((deprecated)) -#endif - ; - -FFI_API ffi_status -ffi_prep_closure_loc (ffi_closure*, - ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*), - void *user_data, - void*codeloc); - -#ifdef __sgi -# pragma pack 8 -#endif -typedef struct { -#if 0 - void *trampoline_table; - void *trampoline_table_entry; -#else - char tramp[FFI_TRAMPOLINE_SIZE]; -#endif - ffi_cif *cif; - -#if !FFI_NATIVE_RAW_API - - /* If this is enabled, then a raw closure has the same layout - as a regular closure. We use this to install an intermediate - handler to do the transaltion, void** -> ffi_raw*. */ - - void (*translate_args)(ffi_cif*,void*,void**,void*); - void *this_closure; - -#endif - - void (*fun)(ffi_cif*,void*,ffi_raw*,void*); - void *user_data; - -} ffi_raw_closure; - -typedef struct { -#if 0 - void *trampoline_table; - void *trampoline_table_entry; -#else - char tramp[FFI_TRAMPOLINE_SIZE]; -#endif - - ffi_cif *cif; - -#if !FFI_NATIVE_RAW_API - - /* If this is enabled, then a raw closure has the same layout - as a regular closure. We use this to install an intermediate - handler to do the translation, void** -> ffi_raw*. */ - - void (*translate_args)(ffi_cif*,void*,void**,void*); - void *this_closure; - -#endif - - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*); - void *user_data; - -} ffi_java_raw_closure; - -FFI_API ffi_status -ffi_prep_raw_closure (ffi_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_raw*,void*), - void *user_data); - -FFI_API ffi_status -ffi_prep_raw_closure_loc (ffi_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_raw*,void*), - void *user_data, - void *codeloc); - -#if !FFI_NATIVE_RAW_API -FFI_API ffi_status -ffi_prep_java_raw_closure (ffi_java_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*), - void *user_data) __attribute__((deprecated)); - -FFI_API ffi_status -ffi_prep_java_raw_closure_loc (ffi_java_raw_closure*, - ffi_cif *cif, - void (*fun)(ffi_cif*,void*,ffi_java_raw*,void*), - void *user_data, - void *codeloc) __attribute__((deprecated)); -#endif - -#endif /* FFI_CLOSURES */ - -#if FFI_GO_CLOSURES - -typedef struct { - void *tramp; - ffi_cif *cif; - void (*fun)(ffi_cif*,void*,void**,void*); -} ffi_go_closure; - -FFI_API ffi_status ffi_prep_go_closure (ffi_go_closure*, ffi_cif *, - void (*fun)(ffi_cif*,void*,void**,void*)); - -FFI_API void ffi_call_go (ffi_cif *cif, void (*fn)(void), void *rvalue, - void **avalue, void *closure); - -#endif /* FFI_GO_CLOSURES */ - -/* ---- Public interface definition -------------------------------------- */ - -FFI_API -ffi_status ffi_prep_cif(ffi_cif *cif, - ffi_abi abi, - unsigned int nargs, - ffi_type *rtype, - ffi_type **atypes); - -FFI_API -ffi_status ffi_prep_cif_var(ffi_cif *cif, - ffi_abi abi, - unsigned int nfixedargs, - unsigned int ntotalargs, - ffi_type *rtype, - ffi_type **atypes); - -FFI_API -void ffi_call(ffi_cif *cif, - void (*fn)(void), - void *rvalue, - void **avalue); - -FFI_API -ffi_status ffi_get_struct_offsets (ffi_abi abi, ffi_type *struct_type, - size_t *offsets); - -/* Useful for eliminating compiler warnings. */ -#define FFI_FN(f) ((void (*)(void))f) - -/* ---- Definitions shared with assembly code ---------------------------- */ - -#endif - -/* If these change, update src/mips/ffitarget.h. */ -#define FFI_TYPE_VOID 0 -#define FFI_TYPE_INT 1 -#define FFI_TYPE_FLOAT 2 -#define FFI_TYPE_DOUBLE 3 -#if 1 -#define FFI_TYPE_LONGDOUBLE 4 -#else -#define FFI_TYPE_LONGDOUBLE FFI_TYPE_DOUBLE -#endif -#define FFI_TYPE_UINT8 5 -#define FFI_TYPE_SINT8 6 -#define FFI_TYPE_UINT16 7 -#define FFI_TYPE_SINT16 8 -#define FFI_TYPE_UINT32 9 -#define FFI_TYPE_SINT32 10 -#define FFI_TYPE_UINT64 11 -#define FFI_TYPE_SINT64 12 -#define FFI_TYPE_STRUCT 13 -#define FFI_TYPE_POINTER 14 -#define FFI_TYPE_COMPLEX 15 - -/* This should always refer to the last type code (for sanity checks). */ -#define FFI_TYPE_LAST FFI_TYPE_COMPLEX - -#ifdef __cplusplus -} -#endif - -#endif - - -#endif \ No newline at end of file diff --git a/third_party/ffi/ffitarget.h b/third_party/ffi/ffitarget.h deleted file mode 100644 index 0a95c81..0000000 --- a/third_party/ffi/ffitarget.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifdef __arm64__ - -#include - - -#endif -#ifdef __i386__ - -#include - - -#endif -#ifdef __arm__ - -#include - - -#endif -#ifdef __x86_64__ - -#include - - -#endif diff --git a/third_party/ffi/ffitarget_arm64.h b/third_party/ffi/ffitarget_arm64.h deleted file mode 100644 index 83a3169..0000000 --- a/third_party/ffi/ffitarget_arm64.h +++ /dev/null @@ -1,102 +0,0 @@ -#ifdef __arm64__ - -/* Copyright (c) 2009, 2010, 2011, 2012 ARM Ltd. - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -``Software''), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ - -#ifndef LIBFFI_TARGET_H -#define LIBFFI_TARGET_H - -#ifndef LIBFFI_H -#error "Please do not include ffitarget.h directly into your source. Use ffi.h instead." -#endif - -#ifndef LIBFFI_ASM -#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(_WIN32) -#define FFI_SIZEOF_ARG 8 -typedef unsigned long long ffi_arg; -typedef signed long long ffi_sarg; -#else -typedef unsigned long ffi_arg; -typedef signed long ffi_sarg; -#endif - -typedef enum ffi_abi - { - FFI_FIRST_ABI = 0, - FFI_SYSV, - FFI_WIN64, - FFI_LAST_ABI, -#if defined(_WIN32) - FFI_DEFAULT_ABI = FFI_WIN64 -#else - FFI_DEFAULT_ABI = FFI_SYSV -#endif - } ffi_abi; -#endif - -/* ---- Definitions for closures ----------------------------------------- */ - -#define FFI_CLOSURES 1 -#define FFI_NATIVE_RAW_API 0 - -#if defined (FFI_EXEC_TRAMPOLINE_TABLE) && FFI_EXEC_TRAMPOLINE_TABLE - -#ifdef __MACH__ -#define FFI_TRAMPOLINE_SIZE 16 -#define FFI_TRAMPOLINE_CLOSURE_OFFSET 16 -#else -#error "No trampoline table implementation" -#endif - -#else -#define FFI_TRAMPOLINE_SIZE 24 -#define FFI_TRAMPOLINE_CLOSURE_OFFSET FFI_TRAMPOLINE_SIZE -#endif - -#ifdef _WIN32 -#define FFI_EXTRA_CIF_FIELDS unsigned is_variadic -#endif -#define FFI_TARGET_SPECIFIC_VARIADIC - -/* ---- Internal ---- */ - -#if defined (__APPLE__) -#define FFI_EXTRA_CIF_FIELDS unsigned aarch64_nfixedargs -#elif !defined(_WIN32) -/* iOS and Windows reserve x18 for the system. Disable Go closures until - a new static chain is chosen. */ -#define FFI_GO_CLOSURES 1 -#endif - -#ifndef _WIN32 -/* No complex type on Windows */ -#define FFI_TARGET_HAS_COMPLEX_TYPE -#endif - -#endif - - -#endif \ No newline at end of file diff --git a/third_party/ffi/ffitarget_armv7.h b/third_party/ffi/ffitarget_armv7.h deleted file mode 100644 index a927784..0000000 --- a/third_party/ffi/ffitarget_armv7.h +++ /dev/null @@ -1,94 +0,0 @@ -#ifdef __arm__ - -/* -----------------------------------------------------------------*-C-*- - ffitarget.h - Copyright (c) 2012 Anthony Green - Copyright (c) 2010 CodeSourcery - Copyright (c) 1996-2003 Red Hat, Inc. - - Target configuration macros for ARM. - - Permission is hereby granted, free of charge, to any person obtaining - a copy of this software and associated documentation files (the - ``Software''), to deal in the Software without restriction, including - without limitation the rights to use, copy, modify, merge, publish, - distribute, sublicense, and/or sell copies of the Software, and to - permit persons to whom the Software is furnished to do so, subject to - the following conditions: - - The above copyright notice and this permission notice shall be included - in all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND - NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT - HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - DEALINGS IN THE SOFTWARE. - - ----------------------------------------------------------------------- */ - -#ifndef LIBFFI_TARGET_H -#define LIBFFI_TARGET_H - -#ifndef LIBFFI_H -#error "Please do not include ffitarget.h directly into your source. Use ffi.h instead." -#endif - -#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(_WIN32) - FFI_DEFAULT_ABI = FFI_VFP, -#else - FFI_DEFAULT_ABI = FFI_SYSV, -#endif -} ffi_abi; -#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 _WIN32 -#define FFI_TARGET_HAS_COMPLEX_TYPE -#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 -#else -#error "No trampoline table implementation" -#endif - -#else -#ifdef _WIN32 -#define FFI_TRAMPOLINE_SIZE 16 -#define FFI_TRAMPOLINE_CLOSURE_FUNCTION 12 -#else -#define FFI_TRAMPOLINE_SIZE 12 -#endif -#define FFI_TRAMPOLINE_CLOSURE_OFFSET FFI_TRAMPOLINE_SIZE -#endif - -#endif - - -#endif \ No newline at end of file diff --git a/third_party/ffi/ffitarget_x86_64.h b/third_party/ffi/ffitarget_x86_64.h deleted file mode 100644 index ecde63c..0000000 --- a/third_party/ffi/ffitarget_x86_64.h +++ /dev/null @@ -1,167 +0,0 @@ -#ifdef __x86_64__ - -/* -----------------------------------------------------------------*-C-*- - ffitarget.h - Copyright (c) 2012, 2014, 2018 Anthony Green - Copyright (c) 1996-2003, 2010 Red Hat, Inc. - Copyright (C) 2008 Free Software Foundation, Inc. - - Target configuration macros for x86 and x86-64. - - Permission is hereby granted, free of charge, to any person obtaining - a copy of this software and associated documentation files (the - ``Software''), to deal in the Software without restriction, including - without limitation the rights to use, copy, modify, merge, publish, - distribute, sublicense, and/or sell copies of the Software, and to - permit persons to whom the Software is furnished to do so, subject to - the following conditions: - - The above copyright notice and this permission notice shall be included - in all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, - EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND - NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT - HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, - WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - DEALINGS IN THE SOFTWARE. - - ----------------------------------------------------------------------- */ - -#ifndef LIBFFI_TARGET_H -#define LIBFFI_TARGET_H - -#ifndef LIBFFI_H -#error "Please do not include ffitarget.h directly into your source. Use ffi.h instead." -#endif - -/* ---- System specific configurations ----------------------------------- */ - -/* For code common to all platforms on x86 and x86_64. */ -#define X86_ANY - -#if defined (X86_64) && defined (__i386__) -#undef X86_64 -#define X86 -#endif - -#ifdef X86_WIN64 -#define FFI_SIZEOF_ARG 8 -#define USE_BUILTIN_FFS 0 /* not yet implemented in mingw-64 */ -#endif - -#define FFI_TARGET_SPECIFIC_STACK_SPACE_ALLOCATION -#ifndef _MSC_VER -#define FFI_TARGET_HAS_COMPLEX_TYPE -#endif - -/* ---- Generic type definitions ----------------------------------------- */ - -#ifndef LIBFFI_ASM -#ifdef X86_WIN64 -#ifdef _MSC_VER -typedef unsigned __int64 ffi_arg; -typedef __int64 ffi_sarg; -#else -typedef unsigned long long ffi_arg; -typedef long long ffi_sarg; -#endif -#else -#if defined __x86_64__ && defined __ILP32__ -#define FFI_SIZEOF_ARG 8 -#define FFI_SIZEOF_JAVA_RAW 4 -typedef unsigned long long ffi_arg; -typedef long long ffi_sarg; -#else -typedef unsigned long ffi_arg; -typedef signed long ffi_sarg; -#endif -#endif - -typedef enum ffi_abi { -#if defined(X86_WIN64) - FFI_FIRST_ABI = 0, - FFI_WIN64, /* sizeof(long double) == 8 - microsoft compilers */ - FFI_GNUW64, /* sizeof(long double) == 16 - GNU compilers */ - FFI_LAST_ABI, -#ifdef __GNUC__ - FFI_DEFAULT_ABI = FFI_GNUW64 -#else - FFI_DEFAULT_ABI = FFI_WIN64 -#endif - -#elif defined(X86_64) || (defined (__x86_64__) && defined (X86_DARWIN)) - FFI_FIRST_ABI = 1, - FFI_UNIX64, - FFI_WIN64, - FFI_EFI64 = FFI_WIN64, - FFI_GNUW64, - FFI_LAST_ABI, - FFI_DEFAULT_ABI = FFI_UNIX64 - -#elif defined(X86_WIN32) - FFI_FIRST_ABI = 0, - FFI_SYSV = 1, - FFI_STDCALL = 2, - FFI_THISCALL = 3, - FFI_FASTCALL = 4, - FFI_MS_CDECL = 5, - FFI_PASCAL = 6, - FFI_REGISTER = 7, - FFI_LAST_ABI, - FFI_DEFAULT_ABI = FFI_MS_CDECL -#else - FFI_FIRST_ABI = 0, - FFI_SYSV = 1, - FFI_THISCALL = 3, - FFI_FASTCALL = 4, - FFI_STDCALL = 5, - FFI_PASCAL = 6, - FFI_REGISTER = 7, - FFI_MS_CDECL = 8, - FFI_LAST_ABI, - FFI_DEFAULT_ABI = FFI_SYSV -#endif -} ffi_abi; -#endif - -/* ---- Definitions for closures ----------------------------------------- */ - -#define FFI_CLOSURES 1 -#define FFI_GO_CLOSURES 1 - -#define FFI_TYPE_SMALL_STRUCT_1B (FFI_TYPE_LAST + 1) -#define FFI_TYPE_SMALL_STRUCT_2B (FFI_TYPE_LAST + 2) -#define FFI_TYPE_SMALL_STRUCT_4B (FFI_TYPE_LAST + 3) -#define FFI_TYPE_MS_STRUCT (FFI_TYPE_LAST + 4) - -#if defined (X86_64) || defined(X86_WIN64) \ - || (defined (__x86_64__) && defined (X86_DARWIN)) -/* 4 bytes of ENDBR64 + 7 bytes of LEA + 6 bytes of JMP + 7 bytes of NOP - + 8 bytes of pointer. */ -# define FFI_TRAMPOLINE_SIZE 32 -# define FFI_NATIVE_RAW_API 0 -#else -/* 4 bytes of ENDBR32 + 5 bytes of MOV + 5 bytes of JMP + 2 unused - bytes. */ -# define FFI_TRAMPOLINE_SIZE 16 -# define FFI_NATIVE_RAW_API 1 /* x86 has native raw api support */ -#endif - -#if !defined(GENERATE_LIBFFI_MAP) && defined(__CET__) -# include -# if (__CET__ & 1) != 0 -# define ENDBR_PRESENT -# endif -# define _CET_NOTRACK notrack -#else -# define _CET_ENDBR -# define _CET_NOTRACK -#endif - -#endif - - - -#endif \ No newline at end of file diff --git a/xcode/TestSkia/TestSkia.xcodeproj/project.pbxproj b/xcode/TestSkia/TestSkia.xcodeproj/project.pbxproj index 0d0af73..42abd04 100644 --- a/xcode/TestSkia/TestSkia.xcodeproj/project.pbxproj +++ b/xcode/TestSkia/TestSkia.xcodeproj/project.pbxproj @@ -12,6 +12,7 @@ 3A110A522676B06200C5D250 /* MetalKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A110A512676B06200C5D250 /* MetalKit.framework */; }; 3A110A542676B0BD00C5D250 /* ModelIO.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A110A532676B0BD00C5D250 /* ModelIO.framework */; }; 3A1A88DA26A79B420005E9C7 /* gol.clj in Resources */ = {isa = PBXBuildFile; fileRef = 3A1A88D926A79B410005E9C7 /* gol.clj */; }; + 3A2C43762C93CD30009D8338 /* libffi.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A2C436D2C93CD26009D8338 /* libffi.a */; }; 3A43FED52C8E31E4008D67EB /* libskparagraph.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A43FED02C8E31E4008D67EB /* libskparagraph.a */; }; 3A43FED62C8E31E4008D67EB /* libskresources.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A43FED12C8E31E4008D67EB /* libskresources.a */; }; 3A43FED72C8E31E5008D67EB /* libskshaper.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A43FED22C8E31E4008D67EB /* libskshaper.a */; }; @@ -40,6 +41,44 @@ 3AC80E7E27F7FFAA006D165F /* bb.o in Frameworks */ = {isa = PBXBuildFile; fileRef = 3AC80E7D27F7FFAA006D165F /* bb.o */; }; /* End PBXBuildFile section */ +/* Begin PBXContainerItemProxy section */ + 3A2C436C2C93CD26009D8338 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = DB13B1661849DF1E0010F42D; + remoteInfo = "libffi-iOS"; + }; + 3A2C436E2C93CD26009D8338 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = FDB52FC51F6144FA00AA92E6; + remoteInfo = "libffi-tvOS"; + }; + 3A2C43702C93CD26009D8338 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = DB13B1911849DF510010F42D; + remoteInfo = "libffi-Mac"; + }; + 3A2C43722C93CD26009D8338 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = FDDB2F621F5D846400EF414E; + remoteInfo = "libffi-static-Mac"; + }; + 3A2C43742C93CD2B009D8338 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */; + proxyType = 1; + remoteGlobalIDString = DB13B1651849DF1E0010F42D; + remoteInfo = "libffi-iOS"; + }; +/* End PBXContainerItemProxy section */ + /* Begin PBXFileReference section */ 3A0761A8269A94E900E90293 /* CoreMotion.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreMotion.framework; path = System/Library/Frameworks/CoreMotion.framework; sourceTree = SDKROOT; }; 3A110A4E2676A38A00C5D250 /* MembraneView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MembraneView.h; sourceTree = ""; }; @@ -47,6 +86,7 @@ 3A110A512676B06200C5D250 /* MetalKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MetalKit.framework; path = System/Library/Frameworks/MetalKit.framework; sourceTree = SDKROOT; }; 3A110A532676B0BD00C5D250 /* ModelIO.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ModelIO.framework; path = System/Library/Frameworks/ModelIO.framework; sourceTree = SDKROOT; }; 3A1A88D926A79B410005E9C7 /* gol.clj */ = {isa = PBXFileReference; lastKnownFileType = text; name = gol.clj; path = ../../examples/gol/gol.clj; sourceTree = ""; }; + 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = libffi.xcodeproj; path = "../../third_party/libffi-3.4.6/libffi.xcodeproj"; sourceTree = ""; }; 3A43FED02C8E31E4008D67EB /* libskparagraph.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libskparagraph.a; sourceTree = ""; }; 3A43FED12C8E31E4008D67EB /* libskresources.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libskresources.a; sourceTree = ""; }; 3A43FED22C8E31E4008D67EB /* libskshaper.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libskshaper.a; sourceTree = ""; }; @@ -81,6 +121,8 @@ 3A7759A926A649810014EA55 /* libmembraneiosskia.o */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.objfile"; path = libmembraneiosskia.o; sourceTree = ""; }; 3A7759AB26A649E70014EA55 /* libskia.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libskia.a; sourceTree = ""; }; 3AC80E7D27F7FFAA006D165F /* bb.o */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.objfile"; name = bb.o; path = ../../library/build/out/bb.o; sourceTree = ""; }; + 3AD3FEA22C935686007A5155 /* libffi-trampolines.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libffi-trampolines.tbd"; path = "Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator17.5.sdk/usr/lib/libffi-trampolines.tbd"; sourceTree = DEVELOPER_DIR; }; + 3AD3FEA32C935686007A5155 /* libffi.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libffi.tbd; path = Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator17.5.sdk/usr/lib/libffi.tbd; sourceTree = DEVELOPER_DIR; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -88,6 +130,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 3A2C43762C93CD30009D8338 /* libffi.a in Frameworks */, 3A6C99A626B0FC73000479D4 /* CoreFoundation.framework in Frameworks */, 3A7759A826A646A20014EA55 /* SwiftUI.framework in Frameworks */, 3A7759AA26A649810014EA55 /* libmembraneiosskia.o in Frameworks */, @@ -115,11 +158,23 @@ /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ + 3A2C43662C93CD26009D8338 /* Products */ = { + isa = PBXGroup; + children = ( + 3A2C436D2C93CD26009D8338 /* libffi.a */, + 3A2C436F2C93CD26009D8338 /* libffi.a */, + 3A2C43712C93CD26009D8338 /* ffi.dylib */, + 3A2C43732C93CD26009D8338 /* libffi.a */, + ); + name = Products; + sourceTree = ""; + }; 3A75F27B267445BB0015D82C = { isa = PBXGroup; children = ( - 3A1A88D926A79B410005E9C7 /* gol.clj */, + 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */, 3A75F286267445BC0015D82C /* TestSkia */, + 3A1A88D926A79B410005E9C7 /* gol.clj */, 3A75F285267445BC0015D82C /* Products */, 3A75F2A72674696C0015D82C /* Frameworks */, ); @@ -159,6 +214,8 @@ 3A75F2A72674696C0015D82C /* Frameworks */ = { isa = PBXGroup; children = ( + 3AD3FEA22C935686007A5155 /* libffi-trampolines.tbd */, + 3AD3FEA32C935686007A5155 /* libffi.tbd */, 3A43FED02C8E31E4008D67EB /* libskparagraph.a */, 3A43FED12C8E31E4008D67EB /* libskresources.a */, 3A43FED22C8E31E4008D67EB /* libskshaper.a */, @@ -199,6 +256,7 @@ buildRules = ( ); dependencies = ( + 3A2C43752C93CD2B009D8338 /* PBXTargetDependency */, ); name = TestSkia; productName = TestSkia; @@ -229,6 +287,12 @@ mainGroup = 3A75F27B267445BB0015D82C; productRefGroup = 3A75F285267445BC0015D82C /* Products */; projectDirPath = ""; + projectReferences = ( + { + ProductGroup = 3A2C43662C93CD26009D8338 /* Products */; + ProjectRef = 3A2C43652C93CD26009D8338 /* libffi.xcodeproj */; + }, + ); projectRoot = ""; targets = ( 3A75F283267445BB0015D82C /* TestSkia */, @@ -236,6 +300,37 @@ }; /* End PBXProject section */ +/* Begin PBXReferenceProxy section */ + 3A2C436D2C93CD26009D8338 /* libffi.a */ = { + isa = PBXReferenceProxy; + fileType = archive.ar; + path = libffi.a; + remoteRef = 3A2C436C2C93CD26009D8338 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; + 3A2C436F2C93CD26009D8338 /* libffi.a */ = { + isa = PBXReferenceProxy; + fileType = archive.ar; + path = libffi.a; + remoteRef = 3A2C436E2C93CD26009D8338 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; + 3A2C43712C93CD26009D8338 /* ffi.dylib */ = { + isa = PBXReferenceProxy; + fileType = "compiled.mach-o.dylib"; + path = ffi.dylib; + remoteRef = 3A2C43702C93CD26009D8338 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; + 3A2C43732C93CD26009D8338 /* libffi.a */ = { + isa = PBXReferenceProxy; + fileType = "compiled.mach-o.dylib"; + path = libffi.a; + remoteRef = 3A2C43722C93CD26009D8338 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; +/* End PBXReferenceProxy section */ + /* Begin PBXResourcesBuildPhase section */ 3A75F282267445BB0015D82C /* Resources */ = { isa = PBXResourcesBuildPhase; @@ -266,6 +361,14 @@ }; /* End PBXSourcesBuildPhase section */ +/* Begin PBXTargetDependency section */ + 3A2C43752C93CD2B009D8338 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + name = "libffi-iOS"; + targetProxy = 3A2C43742C93CD2B009D8338 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + /* Begin PBXVariantGroup section */ 3A75F293267445BC0015D82C /* Main.storyboard */ = { isa = PBXVariantGroup; @@ -495,8 +598,8 @@ "-lstdc++", "-lpthread", "-llibchelper", - "-lffi", "-ldarwin", + "-lffi", "-Wl,-framework,Foundation", "-Wl,-framework,UIKit", "-Wl,-framework,CoreGraphics", @@ -568,8 +671,8 @@ "-lstdc++", "-lpthread", "-llibchelper", - "-lffi", "-ldarwin", + "-lffi", "-Wl,-framework,Foundation", "-Wl,-framework,UIKit", "-Wl,-framework,CoreGraphics",