apotocki/mbedtls 4.2.0 (r1, apple)
- Library
- mbedtls
- Variant
- apple, target apple
- Channel
- stable
- Published
- 2026-11-10
- Recipe source
- https://github.com/otok-dev/recipes.git
7387b6ee8dee98c91c576f3e39051559e5e83d83inrecipes/mbedtls/4.2/apple/ - Recipe SHA-256
d93572811abbb9114a1a41b1ebb6cedc7b5decdb4660bc472d4b5112e5006621
Recipe files changed
Inputs
| source.sha256 | 2bed9d713b4668f76553b097e72b8aa30bc8f112a940d7ae228d524bbde6ffea |
|---|---|
| source.url | https://github.com/Mbed-TLS/mbedtls/releases/download/mbedtls-4.2.0/mbedtls-4.2.0.tar.bz2 |
Platforms
ios, iossim, macosx, catalyst, tvos, tvossim, watchos, watchossim, xros, xrossim
Toolchains
cmake { default-recipe = "apotocki/cmake", version = ">= 3.20" }ninja { default-recipe = "apotocki/ninja", version = ">= 1.10" }
Recipe files
PrivacyInfo.xcprivacy
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyTracking</key>
<false/>
<key>NSPrivacyTrackingDomains</key>
<array/>
<key>NSPrivacyCollectedDataTypes</key>
<array/>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
<string>0A2A.1</string>
</array>
</dict>
</array>
</dict>
</plist>
build.lua
-- Mbed TLS's CMake project, the libraries only, with the default configuration (include/mbedtls/mbedtls_config.h and
-- TF-PSA-Crypto's include/psa/crypto_config.h). Python, which the project looks for only to check the configuration,
-- is not looked for: nothing of the machine.
function build(slice, options, deps)
local static = slice.linkage == "static"
otok.cmake{ defines = {
ENABLE_PROGRAMS = false, ENABLE_TESTING = false, GEN_FILES = false,
MBEDTLS_FATAL_WARNINGS = false, TF_PSA_CRYPTO_FATAL_WARNINGS = false,
USE_STATIC_MBEDTLS_LIBRARY = static, USE_SHARED_MBEDTLS_LIBRARY = not static,
USE_STATIC_TF_PSA_CRYPTO_LIBRARY = static, USE_SHARED_TF_PSA_CRYPTO_LIBRARY = not static,
CMAKE_DISABLE_FIND_PACKAGE_Python3 = true,
} }
local p = slice.prefix
-- the headers of Everest, the variant of X25519 the default configuration leaves out (MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED):
-- they are no part of the module of the product, whose headers each compile alone
otok.remove(p .. "/include/tf-psa-crypto/private/everest")
-- libtfpsacrypto.a or libtfpsacrypto.dylib, and so on
local lib = function(name) return p .. "/lib/lib" .. name .. (static and ".a" or ".dylib") end
return {
libraries = { mbedtls = lib("mbedtls"), mbedx509 = lib("mbedx509"), tfpsacrypto = lib("tfpsacrypto") },
headers = p .. "/include",
}
end
recipe.toml
# The otok recipe of Mbed TLS (https://github.com/apotocki/otok): libmbedtls, libmbedx509 and libtfpsacrypto (the
# PSA Cryptography API of TF-PSA-Crypto) for every Apple platform, from the release archive, with Mbed TLS's CMake and its default
# configuration; static or dynamic.
[recipe]
api = 1
library = "mbedtls"
name = "mbedtls"
version = "4.2.0"
revision = 1
license = "Apache-2.0 OR GPL-2.0-or-later"
license-files = ["LICENSE"]
homepage = "https://www.trustedfirmware.org/projects/mbed-tls/"
documentation = "https://mbed-tls.readthedocs.io"
description = "Mbed TLS, a small, portable implementation of TLS, DTLS, X.509 and the PSA Cryptography API."
keywords = ["tls", "ssl", "x509", "crypto", "cryptography", "psa"]
linkage = ["static", "dynamic"]
# The archive of the release, with TF-PSA-Crypto and the framework the git tag has as submodules, and the files its
# scripts generate; its SHA-256 is mbedtls-4.2.0-sha256sum.txt of the release.
[source]
url = "https://github.com/Mbed-TLS/mbedtls/releases/download/mbedtls-4.2.0/mbedtls-4.2.0.tar.bz2"
sha256 = "2bed9d713b4668f76553b097e72b8aa30bc8f112a940d7ae228d524bbde6ffea"
[platforms]
supported = ["ios", "iossim", "macosx", "catalyst", "tvos", "tvossim", "watchos", "watchossim", "xros", "xrossim"]
build-on = ["macos/xcode"]
[toolchains]
cmake = { version = ">= 3.20", default-recipe = "apotocki/cmake" }
ninja = { version = ">= 1.10", default-recipe = "apotocki/ninja" }
[[product]]
name = "MbedTLS"
libraries = ["mbedtls", "mbedx509", "tfpsacrypto"]
apple = { privacy-manifest = "PrivacyInfo.xcprivacy" }