-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
99 lines (70 loc) · 1.91 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
# server externals Makfile
# stop on error
.SHELLFLAGS = -e
# local externals dir
EXTERN_DIR = externals
# externals extension
UNAME = $(shell uname)
ifeq ($(UNAME), Darwin)
# Mac
EXTERN_EXT = pd_darwin
arch ?= "x86_64 arm64"
ifneq ($(word 2, $(arch)),)
# multiple archs
EXTERN_EXT = d_fat
endif
else ifeq ($(OS), Windows_NT)
# Windows, use Mingw
EXTERN_EXT = dll
else
# Linux or *BSD
EXTERN_EXT = pd_linux
endif
.PHONY: clean clobber \
extern extern-clean extern-clobber \
hoa hoa-depends hoa-clean hoa-clobber \
hrtf hrtf-clean hrtf-clobber \
vbap vbap-clean vbap-clobber
all: extern
clean: extern-clean
clobber: extern-clobber
##### all externals
extern: hoa hrtf vbap
extern-clean: hoa-clean hrtf-clean vbap-clean
extern-clobber: hoa-clobber hrtf-clobber vbap-clobber
### hoa
hoa: hoa-depends zirkhoa.$(EXTERN_EXT)
hoa-depends: $(EXTERN_DIR)/hoa/HoaLibrary-Light/ThirdParty
$(EXTERN_DIR)/hoa/HoaLibrary-Light/ThirdParty:
cd $(EXTERN_DIR)/hoa && git submodule update --init --recursive
zirkhoa.$(EXTERN_EXT):
make -C $(EXTERN_DIR)/hoa arch=$(arch) extension=$(EXTERN_EXT)
cp $(EXTERN_DIR)/hoa/$@ .
cp $(EXTERN_DIR)/hoa/*-help.pd .
hoa-clean:
make -C $(EXTERN_DIR)/hoa clean
hoa-clobber:
rm -f zirkhoa*
### hrtf
hrtf: zirkhrtf~.$(EXTERN_EXT)
zirkhrtf~.$(EXTERN_EXT):
make -C $(EXTERN_DIR)/hrtf arch=$(arch) extension=$(EXTERN_EXT)
cp $(EXTERN_DIR)/hrtf/$@ .
cp $(EXTERN_DIR)/hrtf/*_data.txt .
cp $(EXTERN_DIR)/hrtf/*-help.pd .
hrtf-clean:
make -C $(EXTERN_DIR)/hrtf clean
hrtf-clobber:
rm -f zirkhrtf*
### vbap
vbap: zirkvbap.$(EXTERN_EXT) define_loudspeakers.$(EXTERN_EXT)
zirkvbap.$(EXTERN_EXT):
make -C $(EXTERN_DIR)/vbap arch=$(arch) extension=$(EXTERN_EXT)
cp $(EXTERN_DIR)/vbap/$@ .
cp $(EXTERN_DIR)/vbap/*-help.pd .
define_loudspeakers.$(EXTERN_EXT):
cp $(EXTERN_DIR)/vbap/$@ .
vbap-clean:
make -C $(EXTERN_DIR)/vbap clean
vbap-clobber:
rm -f zirkvbap* define_loudspeakers*