From 77cdab0823b6aa422772e02052ad8fa9e0bbbb69 Mon Sep 17 00:00:00 2001 From: Sebastian Imlay Date: Sat, 27 Nov 2021 12:21:50 -0500 Subject: [PATCH 1/2] Added work around for big sur clang issue --- examples/ios-feedback/.cargo/config | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 examples/ios-feedback/.cargo/config diff --git a/examples/ios-feedback/.cargo/config b/examples/ios-feedback/.cargo/config new file mode 100644 index 0000000..47acd89 --- /dev/null +++ b/examples/ios-feedback/.cargo/config @@ -0,0 +1,4 @@ +[target.aarch64-apple-ios] +linker="/usr/bin/clang" +[target.x86_64-apple-darwin] +linker="/usr/bin/clang" From d36e39ee1436fb49a20e6f4905524b588cc26cde Mon Sep 17 00:00:00 2001 From: Sebastian Imlay Date: Fri, 31 Dec 2021 11:06:14 -0500 Subject: [PATCH 2/2] Maybe fix ci --- examples/ios-feedback/.cargo/config | 4 ---- examples/ios-feedback/build_rust_deps.sh | 7 +++++++ .../cpal-ios-example.xcodeproj/project.pbxproj | 1 + 3 files changed, 8 insertions(+), 4 deletions(-) delete mode 100644 examples/ios-feedback/.cargo/config diff --git a/examples/ios-feedback/.cargo/config b/examples/ios-feedback/.cargo/config deleted file mode 100644 index 47acd89..0000000 --- a/examples/ios-feedback/.cargo/config +++ /dev/null @@ -1,4 +0,0 @@ -[target.aarch64-apple-ios] -linker="/usr/bin/clang" -[target.x86_64-apple-darwin] -linker="/usr/bin/clang" diff --git a/examples/ios-feedback/build_rust_deps.sh b/examples/ios-feedback/build_rust_deps.sh index c9c2f17..be65a39 100755 --- a/examples/ios-feedback/build_rust_deps.sh +++ b/examples/ios-feedback/build_rust_deps.sh @@ -3,6 +3,13 @@ set -e PATH=$PATH:$HOME/.cargo/bin +if [[ -n "${DEVELOPER_SDK_DIR:-}" ]]; then + # Assume we're in Xcode, which means we're probably cross-compiling. + # In this case, we need to add an extra library search path for build scripts and proc-macros, + # which run on the host instead of the target. + # (macOS Big Sur does not have linkable libraries in /usr/lib/.) + export LIBRARY_PATH="${DEVELOPER_SDK_DIR}/MacOSX.sdk/usr/lib:${LIBRARY_PATH:-}" +fi # If you want your build to run faster, add a "--targets x86_64-apple-ios" for just using the ios simulator. if [ -n "${IOS_TARGETS}" ]; then diff --git a/examples/ios-feedback/cpal-ios-example.xcodeproj/project.pbxproj b/examples/ios-feedback/cpal-ios-example.xcodeproj/project.pbxproj index fde407c..7526f76 100644 --- a/examples/ios-feedback/cpal-ios-example.xcodeproj/project.pbxproj +++ b/examples/ios-feedback/cpal-ios-example.xcodeproj/project.pbxproj @@ -253,6 +253,7 @@ DEBUG_INFORMATION_FORMAT = dwarf; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; + "EXCLUDED_ARCHS[sdk=*]" = arm64; GCC_C_LANGUAGE_STANDARD = gnu11; GCC_DYNAMIC_NO_PIC = NO; GCC_NO_COMMON_BLOCKS = YES;