From 73df946d56c74384511a194dd01dbe099584fd1a Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 15:14:23 +0200 Subject: Adding upstream version 1.16.10. Signed-off-by: Daniel Baumann --- misc/ios/clangwrap.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 misc/ios/clangwrap.sh (limited to 'misc/ios/clangwrap.sh') diff --git a/misc/ios/clangwrap.sh b/misc/ios/clangwrap.sh new file mode 100755 index 0000000..dca3fcc --- /dev/null +++ b/misc/ios/clangwrap.sh @@ -0,0 +1,20 @@ +#!/bin/sh +# This uses the latest available iOS SDK, which is recommended. +# To select a specific SDK, run 'xcodebuild -showsdks' +# to see the available SDKs and replace iphoneos with one of them. +if [ "$GOARCH" == "arm64" ]; then + SDK=iphoneos + PLATFORM=ios + CLANGARCH="arm64" +else + SDK=iphonesimulator + PLATFORM=ios-simulator + CLANGARCH="x86_64" +fi + +SDK_PATH=`xcrun --sdk $SDK --show-sdk-path` +export IPHONEOS_DEPLOYMENT_TARGET=5.1 +# cmd/cgo doesn't support llvm-gcc-4.2, so we have to use clang. +CLANG=`xcrun --sdk $SDK --find clang` + +exec "$CLANG" -arch $CLANGARCH -isysroot "$SDK_PATH" -m${PLATFORM}-version-min=10.0 "$@" -- cgit v1.2.3