From 7a1e3b51d722e93d0646e17f8981868dc8e35604 Mon Sep 17 00:00:00 2001 From: Andrei Ermoshin Date: Wed, 24 Aug 2022 17:43:09 +0300 Subject: [PATCH] [iOS] Skip same architecture for universal build to allow lipo command to finish FAT binary successfully --- boost.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/boost.sh b/boost.sh index aa05571e..fe953649 100755 --- a/boost.sh +++ b/boost.sh @@ -1379,7 +1379,17 @@ buildUniversal() ARCH_FILES+=("iphoneos/$ARCH/libboost_$NAME.a") done for ARCH in "${IOS_SIM_ARCHS[@]}"; do - ARCH_FILES+=("iphonesimulator/$ARCH/libboost_$NAME.a") + passed=1 + for IOS_ARCH in "${IOS_ARCHS[@]}"; do + if [ $ARCH == $IOS_ARCH ]; then + passed=0 + echo "Skipping already included architecture: $ARCH" + break + fi + done + if [ $passed -eq 1 ]; then + ARCH_FILES+=("iphonesimulator/$ARCH/libboost_$NAME.a") + fi done if [[ "${#ARCH_FILES[@]}" -gt 0 ]]; then echo "... $NAME"