Add ARM64 support for watchOS.

This commit is contained in:
levlam 2023-03-03 14:10:15 +03:00
parent dff135fa6c
commit 15944f2a00
3 changed files with 6 additions and 5 deletions

View File

@ -199,7 +199,7 @@ if (NOT DEFINED IOS_ARCH)
elseif (IOS_PLATFORM STREQUAL "SIMULATOR")
set (IOS_ARCH "i386;x86_64;arm64")
elseif (IOS_PLATFORM STREQUAL "WATCHOS")
set (IOS_ARCH "armv7k;arm64_32")
set (IOS_ARCH "armv7k;arm64_32;arm64")
elseif (IOS_PLATFORM STREQUAL "WATCHSIMULATOR")
set (IOS_ARCH "i386;x86_64;arm64")
elseif (IOS_PLATFORM STREQUAL "TVOS")

View File

@ -14,7 +14,7 @@ index 695be54..eda7b0d 100644
# - BZip2-macOS - build BZip2 for macOS
# - BZip2-iOS - build BZip2 for iOS
# - BZip2-tvOS - build BZip2 for tvOS
@@ -30,37 +33,51 @@ PYTHON_VERSION=2.7.14
@@ -30,37 +33,52 @@ PYTHON_VERSION=2.7.14
PYTHON_VER=$(basename $(PYTHON_VERSION))
OPENSSL_VERSION_NUMBER=1.0.2
@ -63,11 +63,12 @@ index 695be54..eda7b0d 100644
+
# watchOS targets
-TARGETS-watchOS=watchsimulator.i386 watchos.armv7k
+TARGETS-watchOS=watchos.armv7k watchos.arm64_32
+TARGETS-watchOS=watchos.armv7k watchos.arm64_32 watchos.arm64
CFLAGS-watchOS=-mwatchos-version-min=4.0
-CFLAGS-watchos.armv7k=-fembed-bitcode
+CFLAGS-watchos.armv7k=
+CFLAGS-watchos.arm64_32=
+CFLAGS-watchos.arm64=
PYTHON_CONFIGURE-watchOS=ac_cv_func_sigaltstack=no
+# watchOS-simulator targets
@ -77,7 +78,7 @@ index 695be54..eda7b0d 100644
# override machine types for arm64
MACHINE_DETAILED-arm64=aarch64
MACHINE_SIMPLE-arm64=arm
@@ -194,9 +211,11 @@ endif
@@ -194,9 +212,11 @@ endif
# Configure the build
ifeq ($2,macOS)

View File

@ -8,7 +8,7 @@ For example of usage take a look at our [Swift example](https://github.com/tdlib
To compile `TDLib` you will need to:
* Install the latest Xcode via `xcode-select --install` or downloading it from [Xcode website](https://developer.apple.com/xcode/).
It is not enough to install only command line developer tools to build `TDLib` for iOS.
It is not enough to install only command line developer tools to build `TDLib` for iOS. Xcode >= 14.0 is required to build TDLib for watchOS.
* Install other build dependencies using [Homebrew](https://brew.sh):
```
brew install gperf cmake coreutils