Line | |
---|
1 | |
---|
2 | bindir = @bindir@ |
---|
3 | datadir = @datadir@ |
---|
4 | datarootdir = @datarootdir@ |
---|
5 | exec_prefix = @exec_prefix@ |
---|
6 | includedir = @includedir@ |
---|
7 | libdir = @libdir@ |
---|
8 | mandir = @mandir@ |
---|
9 | prefix = @prefix@ |
---|
10 | srcdir = @srcdir@ |
---|
11 | |
---|
12 | INSTALL = @INSTALL@ |
---|
13 | INSTALL_PROGRAM = ${INSTALL} -m 755 |
---|
14 | INSTALL_DATA = ${INSTALL} -m 644 |
---|
15 | INSTALL_SCRIPT = ${INSTALL} -m 644 |
---|
16 | RM = rm -f |
---|
17 | VPATH = $(srcdir) |
---|
18 | |
---|
19 | PYTHON = @PYTHON@ |
---|
20 | PYTHON_FLAGS = --library-dirs=$(libdir):../../src/core \ |
---|
21 | --include-dirs=$(srcdir)/../../src/core:$(includedir) |
---|
22 | PYTHON_SITE_PACKAGES = @PYTHON_SITE_PACKAGES@ |
---|
23 | |
---|
24 | # |
---|
25 | # Python distutils doesn't handle VPATH correctly. So copy the sources |
---|
26 | # into a temporary directory. |
---|
27 | # |
---|
28 | ifneq($(PYTHON_SITE_PACKAGES),) |
---|
29 | MODULE_BUILD = build_module |
---|
30 | MODULE_INSTALL = install_module |
---|
31 | MODULE_CLEAN = clean_module |
---|
32 | endif |
---|
33 | |
---|
34 | all: $(MODULE_BUILD) |
---|
35 | |
---|
36 | build_module: copy_sources |
---|
37 | $(PYTHON) setup.py build_ext $(PYTHON_FLAGS) build |
---|
38 | |
---|
39 | copy_sources: |
---|
40 | $(RM) -r build/tmp |
---|
41 | $(INSTALL) -d build/tmp |
---|
42 | $(INSTALL_DATA) $(srcdir)/Rappture/*.cc build/tmp |
---|
43 | |
---|
44 | install: $(MODULE_INSTALL) |
---|
45 | |
---|
46 | install_module: |
---|
47 | $(PYTHON) setup.py install --prefix=$(prefix) |
---|
48 | |
---|
49 | clean: $(MODULE_CLEAN) |
---|
50 | |
---|
51 | clean_module: |
---|
52 | $(PYTHON) setup.py clean |
---|
53 | $(RM) -rf build |
---|
54 | |
---|
55 | distclean: clean |
---|
Note: See
TracBrowser
for help on using the repository browser.