From c98ad6041a6f0a0abc7252bce8fda08f2b875ad9 Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Mon, 25 Jul 2016 16:13:29 +0200 Subject: [PATCH] ios_destinations.sh: ignore devices that are marked as placeholders When xcodebuild in Xcode 8 beta dumps out the available destinations, it prints an extra section called 'Ineligible destinations for the "tst_someTest" scheme'. Those destinations doesn't contain valid ID-s for the script to use, which will result in "make check" failing. This patch will filter out devices that are marked as placeholders. Change-Id: I88a25b7307e21b76c6f7764a82f67627aae8f02f Reviewed-by: Jake Petroules --- mkspecs/macx-ios-clang/ios_destinations.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mkspecs/macx-ios-clang/ios_destinations.sh b/mkspecs/macx-ios-clang/ios_destinations.sh index e7b13c212c..ce6b238a65 100755 --- a/mkspecs/macx-ios-clang/ios_destinations.sh +++ b/mkspecs/macx-ios-clang/ios_destinations.sh @@ -38,6 +38,8 @@ echo "IPHONESIMULATOR_DEVICES = $booted_simulator" xcodebuild test -scheme $1 -destination 'id=0' -destination-timeout 1 2>&1| sed -n 's/{ \(platform:.*\) }/\1/p' | while read destination; do id=$(echo $destination | sed -n -E 's/.*id:([^ ,]+).*/\1/p') + [[ $id == *"placeholder"* ]] && continue + echo $destination | tr ',' '\n' | while read keyval; do key=$(echo $keyval | cut -d ':' -f 1 | tr '[:lower:]' '[:upper:]') val=$(echo $keyval | cut -d ':' -f 2)