diff options
Diffstat (limited to 'mkspecs/macx-ios-clang/xcodebuild.mk')
-rw-r--r-- | mkspecs/macx-ios-clang/xcodebuild.mk | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/mkspecs/macx-ios-clang/xcodebuild.mk b/mkspecs/macx-ios-clang/xcodebuild.mk index 1bd18430df..bf6b791368 100644 --- a/mkspecs/macx-ios-clang/xcodebuild.mk +++ b/mkspecs/macx-ios-clang/xcodebuild.mk @@ -56,11 +56,12 @@ iphonesimulator-install: ACTION = build release-%: CONFIGURATION = Release debug-%: CONFIGURATION = Debug +SPECDIR := $(dir $(lastword $(MAKEFILE_LIST))) + # Test and build (device) destinations ifneq ($(filter check%,$(MAKECMDGOALS)),) ifeq ($(DEVICES),) $(info Enumerating test destinations (you may override this by setting DEVICES explicitly), please wait...) - SPECDIR := $(dir $(lastword $(MAKEFILE_LIST))) DESTINATIONS_INCLUDE = /tmp/ios_destinations.mk $(shell $(SPECDIR)/ios_destinations.sh $(TARGET) > $(DESTINATIONS_INCLUDE)) include $(DESTINATIONS_INCLUDE) @@ -71,7 +72,7 @@ endif %-iphoneos: DEVICES = $(IPHONEOS_DEVICES) IPHONEOS_GENERIC_DESTINATION := "generic/platform=iOS" -IPHONESIMULATOR_GENERIC_DESTINATION := "id=$(shell xcrun simctl list devices | grep -E 'iPhone|iPad' | grep -v unavailable | perl -lne 'print $$1 if /\((.*?)\)/' | tail -n 1)" +IPHONESIMULATOR_GENERIC_DESTINATION := "id=$(shell $(SPECDIR)/ios_devices.pl "iPhone|iPad" "NOT unavailable" | tail -n 1)" DESTINATION = $(if $(DESTINATION_ID),"id=$(DESTINATION_ID)",$(value $(call toupper,$(call basesdk,$(SDK)))_GENERIC_DESTINATION)) |