forked from modulo-dm/modulo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
41 lines (32 loc) · 898 Bytes
/
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
# By default export all variables
export
.PHONY: install release debug build setup clean
PROJECT ?= 'modulo.xcodeproj'
SCHEME ?= 'modulo'
SYMROOT ?= 'build'
CONFIGURATION ?= 'Debug'
# Build for debugging
debug: build
# Install `modulo` to `/usr/local/bin`
install: release
cp $(SYMROOT)/Release/modulo /usr/local/bin/
# Build for release
release: CONFIGURATION = 'Release'
release: build
# Build modulo
# This will build the `PROJECT` with the given `SCHEME`
# to the `SYMROOT` with a given `CONFIGURATION`
# Defaults for these values are
# `PROJECT` - `modulo.xcodeproj`
# `SCHEME` - `modulo`
# `SYMROOM` - `build`
# `CONFIGURATION` - `Debug`
#
# These can be overwritten via ENV variables.
build: setup
xcodebuild -project $(PROJECT) -scheme $(SCHEME) -configuration $(CONFIGURATION) SYMROOT=$(SYMROOT)
# Setup the environment
setup:
mkdir -p $(SYMROOT)
clean:
rm -rfv $(SYMROOT)