diff -r b193168bad98 src/Makefile.bootstrap
|
|
|
6 | 6 | |
7 | 7 | # Rule to generate the qmake Makefile for building xxdiff. |
8 | 8 | QMAKE ?= /usr/bin/qmake-qt4 |
| 9 | MAKEDIR ?= . |
9 | 10 | |
10 | 11 | all: Makefile |
11 | 12 | |
… |
… |
|
15 | 16 | export QMAKESPEC=macx-g++ |
16 | 17 | endif |
17 | 18 | |
18 | | Makefile.qmake: xxdiff.pro |
| 19 | Makefile.qmake: $(MAKEDIR)/xxdiff.pro |
19 | 20 | $(QMAKE) -o Makefile.qmake $< |
20 | 21 | |
21 | | Makefile: Makefile.qmake Makefile.extra |
22 | | cat $^ > Makefile |
| 22 | Makefile: Makefile.qmake $(MAKEDIR)/Makefile.extra |
| 23 | echo "MAKEDIR = $(MAKEDIR)" > Makefile |
| 24 | cat $^ >> Makefile |
23 | 25 | |
diff -r b193168bad98 src/Makefile.extra
|
|
|
4 | 4 | # |
5 | 5 | |
6 | 6 | # Extra targets. |
7 | | EXTRA_FILES = version.h doc.h |
| 7 | EXTRA_FILES = version.h $(MAKEDIR)/doc.h |
8 | 8 | |
9 | 9 | .SUFFIXES: .html .txt .h |
10 | 10 | |
… |
… |
|
23 | 23 | # |
24 | 24 | |
25 | 25 | # Automatically generate a simple include file with version number in it. |
26 | | version.h: ../VERSION |
27 | | echo "#define XX_VERSION \"`cat ../VERSION`\"" > $@ |
| 26 | version.h: $(MAKEDIR)/../VERSION |
| 27 | echo "#define XX_VERSION \"`cat $(MAKEDIR)/../VERSION`\"" > $@ |
28 | 28 | |
29 | 29 | # Dependencies for the generated version file. |
30 | 30 | proginfo.o: version.h |
… |
… |
|
41 | 41 | sed -e 's/\"/\\\"/g;s/$$/\\n\\/;1s/^/char text[]=\"/;$$s/\\$$/\"\;/' $< > $@ |
42 | 42 | |
43 | 43 | # Dependencies for the generated documentation file. |
44 | | help.o: doc.h |
45 | | help.obj: doc.h |
| 44 | help.o: $(MAKEDIR)/doc.h |
| 45 | help.obj: $(MAKEDIR)/doc.h |
46 | 46 | |
47 | 47 | # Convert the reStructuredText documentation to html. (this is only used by the |
48 | 48 | # author, directly, manually, not that important for xxdiff packagers.) |
49 | | .txt.html: |
50 | | rst2html.py --output-encoding=iso-8859-1 $< $@ |
| 49 | #.txt.html: |
| 50 | # rst2html.py --output-encoding=iso-8859-1 $< $@ |
51 | 51 | |
52 | 52 | # |
53 | 53 | # clean_extra |
… |
… |
|
60 | 60 | rm -f $(EXTRA_FILES) |
61 | 61 | |
62 | 62 | |
63 | | # Override the qmake we use because the one in the path might be different. |
64 | | QMAKE = $(QTDIR)/bin/qmake |
65 | | |
66 | 63 | |
67 | 64 | # Note: we would need to add this to be correct. Danger! If the Makefile gets |
68 | 65 | # remade, this file does not get appended again to the new makefile! |
69 | 66 | all: Makefile |
70 | 67 | |
71 | | Makefile: xxdiff.pro |
72 | | $(MAKE) -f Makefile.bootstrap Makefile |
| 68 | Makefile: $(MAKEDIR)/xxdiff.pro |
| 69 | $(MAKE) -f $(MAKEDIR)/Makefile.bootstrap Makefile |