A script for compiling OpenSSL for Apple Devices.
Go to file
Davide De Rosa 31c401bdf5
Mix OpenSSL patch and script version (#60)
SwiftPM only allows major.minor.patch version syntax, but we
need to avoid collisions.

E.g. OpenSSL 3.2.5 and script version 34 (0-99)

normalized_patch = (patch + 1) * 100 + script

-> 3.2.634

The +1 is necessary because e.g. 3.2.0 with script 34 would
translate to 3.2.34, which collides with OpenSSL versioning.

In this scheme, the repo tag will be of the form:

- .1xx (for 3.2.0)
- .2xx (for 3.2.1)
- ...

which is reversible to infer the OpenSSL patch.

E.g. 3.2.434

- Patch is 434
- OpenSSL patch is 434 / 100 - 1 = 3
- Script version is 434 % 100 = 34 (precondition is 0-99)

So 3.2.434 is OpenSSL 3.2.3 with script version 34
2023-12-16 13:56:52 +01:00
.github/workflows Whatever, include all targets in release 2023-12-16 12:52:21 +01:00
Demo Configure Demo for basic CI 2020-10-31 01:32:54 +01:00
Demo.xcodeproj Update Demo with XCFramework 2020-11-14 17:54:34 +01:00
Demo.xcworkspace Configure Demo for basic CI 2020-10-31 01:32:54 +01:00
DemoTests Configure Demo for basic CI 2020-10-31 01:32:54 +01:00
assets Produce XCFramework from per-platform frameworks 2020-11-14 16:51:24 +01:00
config Add arm64 target for Apple TV Simulator (#58) 2023-12-16 12:13:35 +01:00
include Add WatchOS targets to build script 2019-09-26 09:39:59 +02:00
scripts Mix OpenSSL patch and script version (#60) 2023-12-16 13:56:52 +01:00
.gitignore Make binaries available as Swift package 2021-10-25 13:08:10 +02:00
.travis.yml Fix cache syntax and be verbose 2021-01-05 01:58:56 +01:00
.version Whatever, include all targets in release 2023-12-16 12:52:21 +01:00
Gemfile Drop x permission 2020-12-28 17:33:58 +01:00
Gemfile.lock Update bundle 2021-10-06 17:54:28 +02:00
LICENSE Drop x permission 2020-12-28 17:33:58 +01:00
OPENSSL-LICENSE Drop x permission 2020-12-28 17:33:58 +01:00
OpenSSL-Apple.podspec Fix disable bitcode argument in Podfile (#45) 2022-01-03 15:11:12 +01:00
Package.swift Fix tag in manifest 2023-12-16 13:56:19 +01:00
Podfile Update Demo 2020-11-13 22:14:25 +01:00
Podfile.lock Update Demo with XCFramework 2020-11-14 17:54:34 +01:00
README.md Bump 2023-12-16 12:48:16 +01:00
build-libssl.sh Add arm64 target for Apple TV Simulator (#58) 2023-12-16 12:13:35 +01:00
create-openssl-framework.sh Fix stale use of get_target_sdk (#57) 2023-12-16 09:49:10 +01:00

README.md

OpenSSL-Apple

iOS support macOS support macOS Catalyst support watchOS support tvOS support OpenSSL version license

This is a fork of the popular work by Felix Schulze, that is a set of scripts for using self-compiled builds of the OpenSSL library on the iPhone and the Apple TV.

However, this repository focuses more on framework-based setups and also adds macOS and watchOS support.

Compile library

Compile OpenSSL 3.2.0 for all targets:

./build-libssl.sh --version=3.2.0

Compile OpenSSL 3.2.0 for specific targets:

./build-libssl.sh --version=3.2.0 --targets="ios64-cross-arm64 macos64-x86_64 macos64-arm64"

For all options see:

./build-libssl.sh --help

Generate frameworks

Generate dynamically linked frameworks and a compound XCFramework:

./create-openssl-framework.sh

Original project

Acknowledgements

This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (https://www.openssl.org/)