]>
Commit | Line | Data |
---|---|---|
3e170ce0 | 1 | include ../Makefile.common |
6d2010ae | 2 | |
39236c6e | 3 | OBJROOT?=$(shell /bin/pwd) |
6d2010ae | 4 | |
fe8ab488 | 5 | CC:=$(shell xcrun -sdk "$(SDKROOT)" -find cc) |
6d2010ae | 6 | |
39236c6e A |
7 | ifdef RC_ARCHS |
8 | ARCHS:=$(RC_ARCHS) | |
9 | else | |
10 | ifeq "$(Embedded)" "YES" | |
fe8ab488 | 11 | ARCHS:=armv7 armv7s arm64 |
39236c6e A |
12 | else |
13 | ARCHS:=x86_64 i386 | |
14 | endif | |
15 | endif | |
16 | ||
39236c6e A |
17 | DSTROOT?=$(shell /bin/pwd) |
18 | ||
3e170ce0 | 19 | CFLAGS:=$(patsubst %, -arch %,$(ARCHS)) -g -Wall -Os -isysroot $(SDKROOT) -I$(SDKROOT)/System/Library/Frameworks/System.framework/PrivateHeaders |
39236c6e A |
20 | |
21 | all: $(DSTROOT)/jitter | |
22 | ||
23 | $(OBJROOT)/timer_jitter.o: timer_jitter.c | |
6d2010ae A |
24 | $(CC) -c -o $@ $< $(CFLAGS) |
25 | ||
39236c6e | 26 | $(OBJROOT)/cpu_number.o: cpu_number.s |
6d2010ae A |
27 | $(CC) -c -o $@ $< $(CFLAGS) |
28 | ||
39236c6e | 29 | $(DSTROOT)/jitter: $(OBJROOT)/timer_jitter.o $(OBJROOT)/cpu_number.o |
6d2010ae | 30 | $(CC) -o $@ $^ $(CFLAGS) |
39236c6e A |
31 | |
32 | clean: | |
33 | rm -f $(DSTROOT)/jitter $(OBJROOT)/*.o |