]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
INSTALL.md: add CMake examples for macOS and iOS
authorViktor Szakats <commit@vsz.me>
Sun, 26 Jan 2025 23:44:49 +0000 (00:44 +0100)
committerViktor Szakats <commit@vsz.me>
Mon, 27 Jan 2025 11:49:12 +0000 (12:49 +0100)
Closes #16095

docs/INSTALL.md

index a6732cffcdd487c3b85069d7fc750a8f2b1c326f..690741d77e5d918c058dc3e676a3af4f5ad239b9 100644 (file)
@@ -367,6 +367,15 @@ make -j8
 make install
 ```
 
+With CMake:
+
+```bash
+cmake . \
+  -DCMAKE_OSX_ARCHITECTURES=x86_64 \
+  -DCMAKE_OSX_DEPLOYMENT_TARGET=10.8 \
+  -DCMAKE_OSX_SYSROOT="$(xcrun --sdk macosx --show-sdk-path)"
+```
+
 The above command lines build curl for macOS platform with `x86_64`
 architecture and `10.8` as deployment target.
 
@@ -383,6 +392,15 @@ make -j8
 make install
 ```
 
+With CMake (3.16 or upper recommended):
+
+```bash
+cmake . \
+  -DCMAKE_SYSTEM_NAME=iOS \
+  -DCMAKE_OSX_ARCHITECTURES=arm64 \
+  -DCMAKE_OSX_DEPLOYMENT_TARGET=11.0
+```
+
 Another example for watchOS simulator for macs with Apple Silicon:
 
 ```bash