[DO-973] harfbuzz package (!10)
Co-authored-by: aleksandr.vodyanov <aleksandr.vodyanov@avroid.tech> Reviewed-on: https://git.avroid.tech/Conan/conan_build/pulls/10
This commit is contained in:
20
recipes/libffi/all/patches/0002-3.3-fix-libtool-path.patch
Normal file
20
recipes/libffi/all/patches/0002-3.3-fix-libtool-path.patch
Normal file
@@ -0,0 +1,20 @@
|
||||
--- configure
|
||||
+++ configure
|
||||
@@ -8964,7 +8964,7 @@
|
||||
LIBTOOL_DEPS=$ltmain
|
||||
|
||||
# Always use our own libtool.
|
||||
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
|
||||
+LIBTOOL='$(SHELL) $(top_builddir)/libtool.sh'
|
||||
|
||||
|
||||
|
||||
@@ -9057,7 +9057,7 @@
|
||||
esac
|
||||
|
||||
# Global variables:
|
||||
-ofile=libtool
|
||||
+ofile=libtool.sh
|
||||
can_build_shared=yes
|
||||
|
||||
# All known linkers require a '.a' archive for static linking (except MSVC,
|
||||
20
recipes/libffi/all/patches/0002-3.4.3-fix-libtool-path.patch
Normal file
20
recipes/libffi/all/patches/0002-3.4.3-fix-libtool-path.patch
Normal file
@@ -0,0 +1,20 @@
|
||||
--- configure
|
||||
+++ configure
|
||||
@@ -9940,7 +9940,7 @@
|
||||
LIBTOOL_DEPS=$ltmain
|
||||
|
||||
# Always use our own libtool.
|
||||
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
|
||||
+LIBTOOL='$(SHELL) $(top_builddir)/libtool.sh'
|
||||
|
||||
|
||||
|
||||
@@ -10032,7 +10032,7 @@
|
||||
esac
|
||||
|
||||
# Global variables:
|
||||
-ofile=libtool
|
||||
+ofile=libtool.sh
|
||||
can_build_shared=yes
|
||||
|
||||
# All known linkers require a '.a' archive for static linking (except MSVC and
|
||||
20
recipes/libffi/all/patches/0002-3.4.6-fix-libtool-path.patch
Normal file
20
recipes/libffi/all/patches/0002-3.4.6-fix-libtool-path.patch
Normal file
@@ -0,0 +1,20 @@
|
||||
--- configure
|
||||
+++ configure
|
||||
@@ -9882,7 +9882,7 @@
|
||||
LIBTOOL_DEPS=$ltmain
|
||||
|
||||
# Always use our own libtool.
|
||||
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
|
||||
+LIBTOOL='$(SHELL) $(top_builddir)/libtool.sh'
|
||||
|
||||
|
||||
|
||||
@@ -9974,7 +9974,7 @@
|
||||
esac
|
||||
|
||||
# Global variables:
|
||||
-ofile=libtool
|
||||
+ofile=libtool.sh
|
||||
can_build_shared=yes
|
||||
|
||||
# All known linkers require a '.a' archive for static linking (except MSVC and
|
||||
@@ -0,0 +1,56 @@
|
||||
--- src/types.c
|
||||
+++ src/types.c
|
||||
@@ -31,6 +31,8 @@
|
||||
#include <ffi.h>
|
||||
#include <ffi_common.h>
|
||||
|
||||
+#include <complex.h>
|
||||
+
|
||||
/* Type definitions */
|
||||
|
||||
#define FFI_TYPEDEF(name, type, id, maybe_const)\
|
||||
@@ -45,17 +47,17 @@
|
||||
id, NULL \
|
||||
}
|
||||
|
||||
-#define FFI_COMPLEX_TYPEDEF(name, type, maybe_const) \
|
||||
+#define FFI_COMPLEX_TYPEDEF(name, complex_type, maybe_const) \
|
||||
static ffi_type *ffi_elements_complex_##name [2] = { \
|
||||
(ffi_type *)(&ffi_type_##name), NULL \
|
||||
}; \
|
||||
struct struct_align_complex_##name { \
|
||||
char c; \
|
||||
- _Complex type x; \
|
||||
+ complex_type x; \
|
||||
}; \
|
||||
FFI_EXTERN \
|
||||
maybe_const ffi_type ffi_type_complex_##name = { \
|
||||
- sizeof(_Complex type), \
|
||||
+ sizeof(complex_type), \
|
||||
offsetof(struct struct_align_complex_##name, x), \
|
||||
FFI_TYPE_COMPLEX, \
|
||||
(ffi_type **)ffi_elements_complex_##name \
|
||||
@@ -99,10 +101,20 @@
|
||||
FFI_TYPEDEF(longdouble, long double, FFI_TYPE_LONGDOUBLE, FFI_LDBL_CONST);
|
||||
#endif
|
||||
|
||||
+#ifdef _MSC_VER
|
||||
+# define FLOAT_COMPLEX _C_float_complex
|
||||
+# define DOUBLE_COMPLEX _C_double_complex
|
||||
+# define LDOUBLE_COMPLEX _C_ldouble_complex
|
||||
+#else
|
||||
+# define FLOAT_COMPLEX float _Complex
|
||||
+# define DOUBLE_COMPLEX double _Complex
|
||||
+# define LDOUBLE_COMPLEX long double _Complex
|
||||
+#endif
|
||||
+
|
||||
#ifdef FFI_TARGET_HAS_COMPLEX_TYPE
|
||||
-FFI_COMPLEX_TYPEDEF(float, float, const);
|
||||
-FFI_COMPLEX_TYPEDEF(double, double, const);
|
||||
+FFI_COMPLEX_TYPEDEF(float, FLOAT_COMPLEX, const);
|
||||
+FFI_COMPLEX_TYPEDEF(double, DOUBLE_COMPLEX, const);
|
||||
#if FFI_TYPE_LONGDOUBLE != FFI_TYPE_DOUBLE
|
||||
-FFI_COMPLEX_TYPEDEF(longdouble, long double, FFI_LDBL_CONST);
|
||||
+FFI_COMPLEX_TYPEDEF(longdouble, LDOUBLE_COMPLEX, FFI_LDBL_CONST);
|
||||
#endif
|
||||
#endif
|
||||
@@ -0,0 +1,56 @@
|
||||
diff --git a/src/types.c b/src/types.c
|
||||
index c1c27f3..d5d52bb 100644
|
||||
--- a/src/types.c
|
||||
+++ b/src/types.c
|
||||
@@ -31,6 +31,8 @@
|
||||
#include <ffi.h>
|
||||
#include <ffi_common.h>
|
||||
|
||||
+#include <complex.h>
|
||||
+
|
||||
/* Type definitions */
|
||||
|
||||
#define FFI_TYPEDEF(name, type, id, maybe_const)\
|
||||
@@ -45,17 +47,17 @@ maybe_const ffi_type ffi_type_##name = { \
|
||||
id, NULL \
|
||||
}
|
||||
|
||||
-#define FFI_COMPLEX_TYPEDEF(name, type, maybe_const) \
|
||||
+#define FFI_COMPLEX_TYPEDEF(name, complex_type, maybe_const) \
|
||||
static ffi_type *ffi_elements_complex_##name [2] = { \
|
||||
(ffi_type *)(&ffi_type_##name), NULL \
|
||||
}; \
|
||||
struct struct_align_complex_##name { \
|
||||
char c; \
|
||||
- _Complex type x; \
|
||||
+ complex_type x; \
|
||||
}; \
|
||||
FFI_EXTERN \
|
||||
maybe_const ffi_type ffi_type_complex_##name = { \
|
||||
- sizeof(_Complex type), \
|
||||
+ sizeof(complex_type), \
|
||||
offsetof(struct struct_align_complex_##name, x), \
|
||||
FFI_TYPE_COMPLEX, \
|
||||
(ffi_type **)ffi_elements_complex_##name \
|
||||
@@ -99,8 +101,18 @@ const ffi_type ffi_type_longdouble = { 16, 16, 4, NULL };
|
||||
FFI_TYPEDEF(longdouble, long double, FFI_TYPE_LONGDOUBLE, FFI_LDBL_CONST);
|
||||
#endif
|
||||
|
||||
+#ifdef _MSC_VER
|
||||
+# define FLOAT_COMPLEX _C_float_complex
|
||||
+# define DOUBLE_COMPLEX _C_double_complex
|
||||
+# define LDOUBLE_COMPLEX _C_ldouble_complex
|
||||
+#else
|
||||
+# define FLOAT_COMPLEX float _Complex
|
||||
+# define DOUBLE_COMPLEX double _Complex
|
||||
+# define LDOUBLE_COMPLEX long double _Complex
|
||||
+#endif
|
||||
+
|
||||
#ifdef FFI_TARGET_HAS_COMPLEX_TYPE
|
||||
-FFI_COMPLEX_TYPEDEF(float, float, const);
|
||||
-FFI_COMPLEX_TYPEDEF(double, double, const);
|
||||
-FFI_COMPLEX_TYPEDEF(longdouble, long double, FFI_LDBL_CONST);
|
||||
+FFI_COMPLEX_TYPEDEF(float, FLOAT_COMPLEX, const);
|
||||
+FFI_COMPLEX_TYPEDEF(double, DOUBLE_COMPLEX, const);
|
||||
+FFI_COMPLEX_TYPEDEF(longdouble, LDOUBLE_COMPLEX, FFI_LDBL_CONST);
|
||||
#endif
|
||||
@@ -0,0 +1,11 @@
|
||||
--- Makefile.in
|
||||
+++ Makefile.in
|
||||
@@ -510,7 +510,7 @@
|
||||
target_os = @target_os@
|
||||
target_vendor = @target_vendor@
|
||||
toolexecdir = @toolexecdir@
|
||||
-toolexeclibdir = @toolexeclibdir@
|
||||
+toolexeclibdir = @libdir@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
@@ -0,0 +1,13 @@
|
||||
diff --git a/Makefile.in b/Makefile.in
|
||||
index 86eb4a5..450200a 100644
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -521,7 +521,7 @@ target_os = @target_os@
|
||||
target_vendor = @target_vendor@
|
||||
tmake_file = @tmake_file@
|
||||
toolexecdir = @toolexecdir@
|
||||
-toolexeclibdir = @toolexeclibdir@
|
||||
+toolexeclibdir = @libdir@
|
||||
top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
@@ -0,0 +1,11 @@
|
||||
--- Makefile.in
|
||||
+++ Makefile.in
|
||||
@@ -613,7 +613,7 @@
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_FALSE@libffi_version_dep =
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_GNU_TRUE@@LIBFFI_BUILD_VERSIONED_SHLIB_TRUE@libffi_version_dep = libffi.map
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_SUN_TRUE@@LIBFFI_BUILD_VERSIONED_SHLIB_TRUE@libffi_version_dep = libffi.map-sun
|
||||
-libffi_version_info = -version-info `grep -v '^\#' $(srcdir)/libtool-version`
|
||||
+libffi_version_info = -avoid-version
|
||||
libffi_la_LDFLAGS = -no-undefined $(libffi_version_info) $(libffi_version_script) $(LTLDFLAGS) $(AM_LTLDFLAGS)
|
||||
libffi_la_DEPENDENCIES = $(libffi_la_LIBADD) $(libffi_version_dep)
|
||||
AM_CPPFLAGS = -I. -I$(top_srcdir)/include -Iinclude -I$(top_srcdir)/src
|
||||
@@ -0,0 +1,13 @@
|
||||
diff --git a/Makefile.in b/Makefile.in
|
||||
index 450200a..abcee85 100644
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -616,7 +616,7 @@ AM_CFLAGS = $(am__append_3)
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_FALSE@libffi_version_dep =
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_GNU_TRUE@@LIBFFI_BUILD_VERSIONED_SHLIB_TRUE@libffi_version_dep = libffi.map
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_SUN_TRUE@@LIBFFI_BUILD_VERSIONED_SHLIB_TRUE@libffi_version_dep = libffi.map-sun
|
||||
-libffi_version_info = -version-info `grep -v '^\#' $(srcdir)/libtool-version`
|
||||
+libffi_version_info = -avoid-version
|
||||
libffi_la_LDFLAGS = -no-undefined $(libffi_version_info) $(libffi_version_script) $(LTLDFLAGS) $(AM_LTLDFLAGS)
|
||||
libffi_la_DEPENDENCIES = $(libffi_la_LIBADD) $(libffi_version_dep)
|
||||
AM_CPPFLAGS = -I. -I$(top_srcdir)/include -Iinclude -I$(top_srcdir)/src
|
||||
@@ -0,0 +1,13 @@
|
||||
diff --git a/Makefile.in b/Makefile.in
|
||||
index 450200a..abcee85 100644
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -618,7 +618,7 @@ AM_CFLAGS = $(am__append_3)
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_FALSE@libffi_version_dep =
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_GNU_TRUE@@LIBFFI_BUILD_VERSIONED_SHLIB_TRUE@libffi_version_dep = libffi.map
|
||||
@LIBFFI_BUILD_VERSIONED_SHLIB_SUN_TRUE@@LIBFFI_BUILD_VERSIONED_SHLIB_TRUE@libffi_version_dep = libffi.map-sun
|
||||
-libffi_version_info = -version-info `grep -v '^\#' $(srcdir)/libtool-version`
|
||||
+libffi_version_info = -avoid-version
|
||||
libffi_la_LDFLAGS = -no-undefined $(libffi_version_info) $(libffi_version_script) $(LTLDFLAGS) $(AM_LTLDFLAGS)
|
||||
libffi_la_DEPENDENCIES = $(libffi_la_LIBADD) $(libffi_version_dep)
|
||||
AM_CPPFLAGS = -I. -I$(top_srcdir)/include -Iinclude -I$(top_srcdir)/src
|
||||
@@ -0,0 +1,30 @@
|
||||
diff --git a/include/ffi_common.h b/include/ffi_common.h
|
||||
index 2bd31b0..c53a794 100644
|
||||
--- a/include/ffi_common.h
|
||||
+++ b/include/ffi_common.h
|
||||
@@ -128,6 +128,10 @@ void *ffi_data_to_code_pointer (void *data) FFI_HIDDEN;
|
||||
static trampoline. */
|
||||
int ffi_tramp_is_present (void *closure) FFI_HIDDEN;
|
||||
|
||||
+/* Return a file descriptor of a temporary zero-sized file in a
|
||||
+ writable and executable filesystem. */
|
||||
+int open_temp_exec_file(void) FFI_HIDDEN;
|
||||
+
|
||||
/* Extended cif, used in callback from assembly routine */
|
||||
typedef struct
|
||||
{
|
||||
diff --git a/src/tramp.c b/src/tramp.c
|
||||
index b9d273a..c3f4c99 100644
|
||||
--- a/src/tramp.c
|
||||
+++ b/src/tramp.c
|
||||
@@ -39,6 +39,10 @@
|
||||
#ifdef __linux__
|
||||
#define _GNU_SOURCE 1
|
||||
#endif
|
||||
+
|
||||
+#include <ffi.h>
|
||||
+#include <ffi_common.h>
|
||||
+
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
#include <stdlib.h>
|
||||
Reference in New Issue
Block a user