mirror of
https://git.jami.net/savoirfairelinux/jami-daemon.git
synced 2025-08-12 22:09:25 +08:00
libressl: fix iOS build
OSByteOrder.h on macOS does not include the required macro definitions. Applied the fix suggested in https://github.com/libressl/portable/issues/1025. Change-Id: I033fb5f405aed6fb8bcf859ea13bc8d3cb4959f1
This commit is contained in:
25
contrib/src/libressl/ios-add-byte-order-macros.patch
Normal file
25
contrib/src/libressl/ios-add-byte-order-macros.patch
Normal file
@ -0,0 +1,25 @@
|
||||
diff --git a/.DS_Store b/.DS_Store
|
||||
index d154117..67f406e 100644
|
||||
Binary files a/.DS_Store and b/.DS_Store differ
|
||||
diff --git a/include/compat/endian.h b/include/compat/endian.h
|
||||
index 5376c1a..2a318af 100644
|
||||
--- a/include/compat/endian.h
|
||||
+++ b/include/compat/endian.h
|
||||
@@ -62,7 +62,7 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
-#if defined(__APPLE__) && !defined(HAVE_ENDIAN_H)
|
||||
+#if defined(__APPLE__) && !defined(be16toh)
|
||||
#include <libkern/OSByteOrder.h>
|
||||
#define be16toh(x) OSSwapBigToHostInt16((x))
|
||||
#define htobe16(x) OSSwapHostToBigInt16((x))
|
||||
@@ -74,7 +74,7 @@
|
||||
#define htobe64(x) OSSwapHostToBigInt64(x)
|
||||
#define le64toh(x) OSSwapLittleToHostInt64(x)
|
||||
#define be64toh(x) OSSwapBigToHostInt64(x)
|
||||
-#endif /* __APPLE__ && !HAVE_ENDIAN_H */
|
||||
+#endif /* __APPLE__ && !be16toh */
|
||||
|
||||
#if defined(_WIN32) && !defined(HAVE_ENDIAN_H)
|
||||
#include <winsock2.h>
|
@ -33,6 +33,9 @@ $(TARBALLS)/$(LIBRESSL_VERSION).tar.gz:
|
||||
|
||||
libressl: $(LIBRESSL_VERSION).tar.gz
|
||||
$(UNPACK)
|
||||
ifdef HAVE_IOS
|
||||
$(APPLY) $(SRC)/libressl/ios-add-byte-order-macros.patch
|
||||
endif
|
||||
$(MOVE)
|
||||
|
||||
LIBRESSL_CONF := \
|
||||
@ -50,6 +53,10 @@ ifeq ($(HOST_ARCH),arm-linux-gnueabihf)
|
||||
LIBRESSL_CONF += -DCMAKE_SYSTEM_PROCESSOR=arm -DENABLE_ASM=Off -DCMAKE_C_FLAGS='-march=armv7-a -mfpu=neon-vfpv4 -mfloat-abi=hard'
|
||||
endif
|
||||
|
||||
ifdef HAVE_IOS
|
||||
LIBRESSL_CONF += -DCMAKE_SYSTEM_PROCESSOR=aarch64 -DENABLE_ASM=Off
|
||||
endif
|
||||
|
||||
.libressl: libressl .sum-libressl
|
||||
mkdir -p "$(PREFIX)/include"
|
||||
ifdef HAVE_WIN32
|
||||
|
Reference in New Issue
Block a user