-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile
59 lines (45 loc) · 1.36 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
# Quick-DER
#
# This Makefile is just a stub: it invokes CMake, which in turn
# generates Makefiles, and then uses those to make the project.
#
# Useful Make parameters at this level are:
# PREFIX=/usr/local
#
# For anything else, do this:
#
# make configure # Basic configure, remember PREFIX!
# ( cd build ; ccmake ) # CMake GUI for build configuration
# ( cd build ; make install ) # Build and install
#
# For building the Python tooling (needed for header generation and tooling)
# see the Python install documentation in python/INSTALL.MD . For simple
# cases (or if you have a suitable PYTHONPATH set in the environment already),
# do this:
#
# make python # Remember to set PREFIX!
#
PREFIX ?= /usr/local
all: compile
build-dir:
@mkdir -p build
configure: _configure build-dir build/CMakeCache.txt
_configure:
@rm -f build/CMakeCache.txt
build/CMakeCache.txt:
( cd build && cmake .. -DCMAKE_INSTALL_PREFIX=$(PREFIX) -DCMAKE_PREFIX_PATH=$(PREFIX) )
compile: build-dir build/CMakeCache.txt
( cd build && $(MAKE) )
install: build-dir
( cd build && $(MAKE) install )
test: build-dir
( cd build && $(MAKE) test )
uninstall: build-dir
( cd build && $(MAKE) uninstall )
clean:
rm -rf build/
package: compile
( cd build && $(MAKE) package )
python: compile install
python setup.py build
python setup.py install --prefix=$(PREFIX)