Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Commit

Permalink
Merge pull request #5 from russellhancox/master
Browse files Browse the repository at this point in the history
Fix Makefile
  • Loading branch information
russellhancox authored Oct 10, 2017
2 parents f494505 + f466ad5 commit 9f3137a
Showing 1 changed file with 15 additions and 21 deletions.
36 changes: 15 additions & 21 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,13 +1,3 @@
ifeq (,$(wildcard Pods))
$(warning Pods dir does not exist, running 'pod install')
@pod install
endif

XCPRETTY_AVAIL:=$(shell command -v xcpretty 2>/dev/null)
ifdef XCPRETTY_AVAIL
XCPRETTY:=| ${XCPRETTY_AVAIL} -sc
endif

ifeq (,${BUILD_D})
DERIVED_DATA=$(shell xcodebuild -workspace Restor.xcworkspace -scheme Restor -showBuildSettings | grep TARGET_BUILD_DIR | head -n1 | awk '{print $$3}')
else
Expand All @@ -24,38 +14,42 @@ list:
sort | egrep -v -e '^[^[:alnum:]]' -e '^$@$$' | \
xargs

debug:
.PHONY: .prebuild
.prebuild:
ifeq (,$(wildcard Pods))
@echo "Pods dir does not exist, running 'pod install'"
@pod install
endif

debug: .prebuild
@xcodebuild \
-derivedDataPath ${DERIVED_DATA} \
-parallelizeTargets -jobs ${NCPUS} \
-workspace Restor.xcworkspace \
-scheme Restor \
-configuration Debug \
build \
${XCPRETTY}
build

release:
release: .prebuild
@xcodebuild \
-derivedDataPath ${DERIVED_DATA} \
-parallelizeTargets -jobs ${NCPUS} \
-workspace Restor.xcworkspace \
-scheme Restor \
-configuration Release \
build \
${XCPRETTY}
build

google_release:
google_release: .prebuild
@xcodebuild \
TEAM_ID=EQHXZ8M8AV \
-derivedDataPath ${DERIVED_DATA} \
-parallelizeTargets -jobs ${NCPUS} \
-workspace Restor.xcworkspace \
-scheme Restor \
-configuration Release \
build \
${XCPRETTY}
build

clean:
@xcodebuild -workspace Restor.xcworkspace -scheme Restor clean ${XCPRETTY}
@rm -rf build
@xcodebuild -workspace Restor.xcworkspace -scheme Restor clean
@rm -rf ${DERIVED_DATA}

0 comments on commit 9f3137a

Please sign in to comment.