-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
36 lines (27 loc) · 1.07 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
EDM_BUILD_DIR ?= build
EDM_BUILD_CONFIG ?= release
EDM_GPU ?= OFF
all: $(EDM_BUILD_DIR)/CMakeCache.txt plugin test cli gbench install
$(EDM_BUILD_DIR)/CMakeCache.txt:
cmake -B $(EDM_BUILD_DIR) -S . -DCMAKE_BUILD_TYPE=$(EDM_BUILD_CONFIG) -DEDM_WITH_ARRAYFIRE=$(EDM_GPU)
.PHONY: plugin
plugin: $(EDM_BUILD_DIR)/CMakeCache.txt
cmake --build $(EDM_BUILD_DIR) --config $(EDM_BUILD_CONFIG) --parallel 12 --target edm_plugin
.PHONY: cli
cli: $(EDM_BUILD_DIR)/CMakeCache.txt
cmake --build $(EDM_BUILD_DIR) --config $(EDM_BUILD_CONFIG) --parallel 12 --target edm_cli
.PHONY: gbench
gbench: $(EDM_BUILD_DIR)/CMakeCache.txt
cmake --build $(EDM_BUILD_DIR) --config $(EDM_BUILD_CONFIG) --parallel 12 --target gbench
.PHONY: test
test: $(EDM_BUILD_DIR)/CMakeCache.txt
cmake --build $(EDM_BUILD_DIR) --config $(EDM_BUILD_CONFIG) --parallel 12 --target edm_test
.PHONY: install
install:
cmake --build $(EDM_BUILD_DIR) --config $(EDM_BUILD_CONFIG) --parallel 12 --target install
.PHONY: clean
clean:
rm -rf $(EDM_BUILD_DIR)
.PHONY: format
format:
cmake --build $(EDM_BUILD_DIR) --target format