forked from BlueBrain/Brion
-
Notifications
You must be signed in to change notification settings - Fork 0
/
GNUmakefile
64 lines (44 loc) · 1.19 KB
/
GNUmakefile
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
#!gmake
.PHONY: debug release clean clobber package debuginst releaseinst cmake_make install test
ifeq ($(wildcard Makefile), Makefile)
all:
$(MAKE) -f Makefile $(MAKECMDGOALS)
install:
$(MAKE) -f Makefile $(MAKECMDGOALS)
clean:
$(MAKE) -f Makefile $(MAKECMDGOALS)
test:
$(MAKE) -f Makefile $(MAKECMDGOALS)
package:
$(MAKE) -f Makefile $(MAKECMDGOALS)
.DEFAULT:
$(MAKE) -f Makefile $(MAKECMDGOALS)
else
all: install
install: Debug/Makefile Release/Makefile
@$(MAKE) -C Debug install
@$(MAKE) -C Release install
clean:
@-$(MAKE) -C Debug clean
@-$(MAKE) -C Release clean
test: Debug/Makefile
@$(MAKE) -C Debug test
package: Release/Makefile
@$(MAKE) -C Release clean
@$(MAKE) -C Release package
.DEFAULT: Debug/Makefile Release/Makefile
@$(MAKE) -C Debug $(MAKECMDGOALS)
@$(MAKE) -C Release $(MAKECMDGOALS)
endif
clobber:
rm -rf Debug Release
debug: Debug/Makefile
@$(MAKE) -C Debug
Debug/Makefile:
@mkdir -p Debug
@cd Debug; cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX:PATH=`pwd`/install
release: Release/Makefile
@$(MAKE) -C Release
Release/Makefile:
@mkdir -p Release
@cd Release; cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=`pwd`/install