This repository has been archived by the owner on Apr 5, 2023. It is now read-only.
forked from optimizely/objective-c-sdk
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
63 lines (59 loc) · 2.25 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
SIMULATOR = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app/Contents/MacOS/iPhone\ Simulator
SDK = $(if $(IOS_SDK), $(IOS_SDK), iphonesimulator)
.DEFAULT_GOAL := help
PWD = $(shell pwd)
CONFIG = Release
EXTRA_PREPROCESSOR_DEFINITIONS =
PROJECT_NAME=OptimizelySDK
company=Optimizely
companyID=com.optimizely
companyURL=http://www.optimizely.com
DOC_OUTPUT_DIR=${PWD}/help
RETAIL_OUTPUT_DIR=${PWD}/Optimizely-Core-Objective-C-SDK
FRAMEWORK_PATH=${PWD}/OptimizelySDK/build/Release-iphoneos/OptimizelySDK.framework
BUILD_ERROR_MSG=$(shell perl -MURI::Escape -e 'print uri_escape($$ARGV[0]);' "${BUILD_NUMBER}-${GIT_BRANCH} failed to build! Look at ${BUILD_URL}")
###############################################
# Build commands
###############################################
seperator:
@echo "############################################################################"
build-docs: seperator
@echo "Building Documentation in ${DOC_OUTPUT_DIR}"
rm -rf ${DOC_OUTPUT_DIR}
mkdir -p ${DOC_OUTPUT_DIR}
appledoc \
--project-name "${PROJECT_NAME}" \
--project-company "${company}" \
--company-id "${companyID}" \
--docset-atom-filename "${company}.atom" \
--docset-feed-url "${companyURL}/${company}/%DOCSETATOMFILENAME" \
--docset-package-url "${companyURL}/${company}/%DOCSETPACKAGEFILENAME" \
--docset-fallback-url "${companyURL}/${company}" \
--output "${DOC_OUTPUT_DIR}" \
--publish-docset \
--logformat xcode \
--keep-intermediate-files \
--no-repeat-first-par \
--no-warn-invalid-crossref \
--exit-threshold 2 \
"${PWD}/OptimizelySDK/OptimizelySDK"
###############################################
# Debug/Info commands
###############################################
info: info-sdks info-project-OptimizelySDK info-project-iOSDemo
info-project-%:
xcodebuild -list -project ./$*/$*.xcodeproj/
info-sdks:
xcodebuild -showsdks
clean:
@rm -rf OptimizelySDK/build/
@rm -rf ${RETAIL_OUTPUT_DIR}
@rm -rf ./OptimizelyRetail-SDK.zip
@rm -rf ./help
@git clean -fX
help:
@echo ""
@echo "make build-docs - builds documentation "
@echo "make info - dumps info about Optimizely's projects and xcodec"
@echo "make clean - clean out the current directory"
@echo ""