annotate Makefile.gen @ 238:d8c3043c00a0

Adjust build system.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 07 May 2018 20:07:39 +0300
parents 54ab3f3e28c0
children 3d3ba5759cac
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
1 ###
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
2 ### Main build file
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
3 ###
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
4
184
87dfca9f704d Move optimization and warning CFLAGS and CXXFLAGS to Makefile.gen
Matti Hamalainen <ccr@tnsp.org>
parents: 157
diff changeset
5 CFLAGS += -O2 -W -Wall -Wextra
208
e6a2658ae096 Enable building via clang++ (tested with 5.0).
Matti Hamalainen <ccr@tnsp.org>
parents: 192
diff changeset
6 CXXFLAGS += -O2 -W -Wall -Wextra -std=c++11
184
87dfca9f704d Move optimization and warning CFLAGS and CXXFLAGS to Makefile.gen
Matti Hamalainen <ccr@tnsp.org>
parents: 157
diff changeset
7
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
8 # Tools
208
e6a2658ae096 Enable building via clang++ (tested with 5.0).
Matti Hamalainen <ccr@tnsp.org>
parents: 192
diff changeset
9 ifneq ($(BINTOOL_PREFIX),)
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
10 CC = $(BINTOOL_PREFIX)gcc
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
11 CXX = $(BINTOOL_PREFIX)g++
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
12 AR = $(BINTOOL_PREFIX)ar
208
e6a2658ae096 Enable building via clang++ (tested with 5.0).
Matti Hamalainen <ccr@tnsp.org>
parents: 192
diff changeset
13 endif
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
14 RANLIB = $(BINTOOL_PREFIX)ranlib
49
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
15 WINDRES = $(BINTOOL_PREFIX)windres
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
16
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
17 INSTALL ?= install
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
18 MKDIR ?= mkdir
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
19 MKDIR_P ?= $(MKDIR) -p
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
20
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
21 # Common defines
234
4a993456df9f Cleanup.
Matti Hamalainen <ccr@tnsp.org>
parents: 233
diff changeset
22 DEFINES += -DQT_DEPRECATED_WARNINGS -DQT_NO_DEBUG \
4a993456df9f Cleanup.
Matti Hamalainen <ccr@tnsp.org>
parents: 233
diff changeset
23 -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_SQL_LIB \
4a993456df9f Cleanup.
Matti Hamalainen <ccr@tnsp.org>
parents: 233
diff changeset
24 -DQT_CORE_LIB
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
25
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
26 # Application stuff
80
c8fd927cd2c4 Restructure the project by placing source code, images into appropriate
Matti Hamalainen <ccr@tnsp.org>
parents: 76
diff changeset
27 APP_IMG=img/
49
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
28 APP_BIN=$(BINPATH)Syntilista$(EXEEXT)
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
29
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
30 APP_HDRS=\
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
31 src/main.h \
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
32 src/ui_viewtransactions.h \
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
33 src/ui_mainwindow.h \
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
34 src/ui_editperson.h \
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
35 src/ui_aboutwindow.h
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
36
237
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
37 APP_OBJS=\
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
38 main.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
39 editperson.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
40 viewtransactions.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
41 sqlmodels.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
42 printing.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
43 resources.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
44 moc_main.o \
54ab3f3e28c0 Split EditPerson and ViewTransactions to separate source files.
Matti Hamalainen <ccr@tnsp.org>
parents: 234
diff changeset
45 runguard.o
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
46
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
47 LOGO_SVG ?= kampuscafe4.svg
192
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
48 LOGO_IMG ?= CafeKampus_logo_FINAL_RGB.png
52
1ac8fdd932b3 More work on build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 50
diff changeset
49 ICON_PNGS = icon-64.png icon-48.png icon-32.png icon-16.png
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
50
231
e90dba0cd12a Implement HTML stuff for about dialog.
Matti Hamalainen <ccr@tnsp.org>
parents: 228
diff changeset
51 APP_RESOURCES += $(addprefix $(APP_IMG),logo.png $(ICON_PNGS)) COPYING.html
56
ac3daf42f781 Rename some files.
Matti Hamalainen <ccr@tnsp.org>
parents: 55
diff changeset
52
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
53 # And target lists
49
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
54 TARGETS = $(APP_BIN)
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
55 NOBUILD_TARGETS += $(OBJPATH) $(BINPATH)
81
810ca71af506 Improve 'clean' target handling.
Matti Hamalainen <ccr@tnsp.org>
parents: 80
diff changeset
56 NOINST_TARGETS +=
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
57 CLEAN_TARGETS += icon.ico src/moc_*.cpp src/ui_*.h
81
810ca71af506 Improve 'clean' target handling.
Matti Hamalainen <ccr@tnsp.org>
parents: 80
diff changeset
58 DISTCLEAN_TARGETS +=
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
59
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
60
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
61 # Version
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
62 APP_VERSION := $(shell cat VERSION)
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
63 comma:= ,
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
64 APP_VERSION_COM := $(subst .,$(comma),$(APP_VERSION))
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
65 CXXFLAGS += -DAPP_VERSION=\"$(APP_VERSION)\"
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
66
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
67
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
68 ###
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
69 ### Target rules
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
70 ###
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
71 all: $(NOBUILD_TARGETS) $(NOINST_TARGETS) $(TARGETS)
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
72
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
73
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
74 moc_predefs.h:
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
75 @echo "" > $(OBJPATH)dummy.cpp
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
76 @$(CXX) $(CXXFLAGS) -dM -E -o $@ $(OBJPATH)dummy.cpp
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
77
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
78 moc_%.cpp: %.h $(QT_MOC_RULES)
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
79 @echo " Qt::MOC $@ $<"
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
80 @$(QT_MOC) $(DEFINES) $(QT_MOC_FLAGS) $(INCPATH) $< -o $@
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
81
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
82 ui_%.h: %.ui
238
d8c3043c00a0 Adjust build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 237
diff changeset
83 @echo " Qt::UIC $@ $<"
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
84 @$(QT_UIC) $(QT_UIC_FLAGS) $< -o $@
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
85
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
86
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
87 $(OBJPATH) $(BINPATH):
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
88 @echo " MKDIR $@"
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
89 @$(MKDIR_P) $@
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
90
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
91 $(OBJPATH)%.o: src/%.cpp src/%.h
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
92 @echo " CXX $@"
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
93 @$(CXX) $(CXXFLAGS) $(DEFINES) $(INCPATH) -c -o $@ $<
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
94
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
95 $(OBJPATH)%.o: src/%.cpp
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
96 @echo " CXX $@"
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
97 @$(CXX) $(CXXFLAGS) $(DEFINES) $(INCPATH) -c -o $@ $<
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
98
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
99
49
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
100
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
101 ###
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
102 ### Windows specific rules
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
103 ###
56
ac3daf42f781 Rename some files.
Matti Hamalainen <ccr@tnsp.org>
parents: 55
diff changeset
104 %.rc: %.rc.in icon.ico VERSION
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
105 @sed -e "s/@APP_VERSION@/$(APP_VERSION)/g;s/@APP_VERSION_COM@/$(APP_VERSION_COM)/g;s#@APP_EXE@#$(notdir $(APP_BIN))#g" < $< > $@
49
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
106
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
107 $(OBJPATH)%.o: src/%.rc
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
108 @echo " WINDRES $<"
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
109 @$(WINDRES) $< -O coff -o $@
49
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
110
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
111
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
112 ###
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
113 ### Application rules
b86eb06070ba More work on buildsystem.
Matti Hamalainen <ccr@tnsp.org>
parents: 48
diff changeset
114 ###
192
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
115 #$(APP_IMG)icon-%.png: $(addprefix $(APP_IMG),$(LOGO_SVG))
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
116 # inkscape --export-area-page -w $(patsubst $(APP_IMG)icon-%.png,%,$@) -h $(patsubst $(APP_IMG)icon-%.png,%,$@) -e "$@" "$<"
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
117
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
118 #$(APP_IMG)logo.png: $(addprefix $(APP_IMG),$(LOGO_SVG))
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
119 # inkscape --export-area-page -w 258 -h 220 -e "$@" "$<"
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
120
192
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
121 $(APP_IMG)icon-%.png: $(addprefix $(APP_IMG),$(LOGO_IMG))
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
122 convert "$<" -scale "$(patsubst $(APP_IMG)icon-%.png,%,$@)x$(patsubst $(APP_IMG)icon-%.png,%,$@)" "$@"
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
123
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
124 $(APP_IMG)logo.png: $(addprefix $(APP_IMG),$(LOGO_IMG))
dfe5e8d7c58a Use the finalized Cafe Kampus logo.
Matti Hamalainen <ccr@tnsp.org>
parents: 184
diff changeset
125 convert "$<" -scale "258x220" "$@"
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
126
80
c8fd927cd2c4 Restructure the project by placing source code, images into appropriate
Matti Hamalainen <ccr@tnsp.org>
parents: 76
diff changeset
127 icon.ico: $(addprefix $(APP_IMG),$(ICON_PNGS))
52
1ac8fdd932b3 More work on build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 50
diff changeset
128 @echo " CONVERT $+ -> $@"
1ac8fdd932b3 More work on build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 50
diff changeset
129 @convert $+ $@
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
130
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
131 src/%.cpp: src/%.qrc $(APP_RESOURCES)
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
132 @echo " Qt:RCC $@ $<"
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
133 @$(QT_RCC) -name "Syntilista" $< -o $@
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
134
233
6a12c82d082e Cleanup build.
Matti Hamalainen <ccr@tnsp.org>
parents: 231
diff changeset
135 $(OBJPATH)main.o: src/main.cpp $(APP_HDRS) VERSION
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
136 @echo " CXX $@"
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
137 @$(CXX) $(CXXFLAGS) $(DEFINES) $(INCPATH) -c -o $@ $<
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
138
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
139
52
1ac8fdd932b3 More work on build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 50
diff changeset
140 $(APP_BIN): $(addprefix $(OBJPATH),$(APP_OBJS)) $(APP_DEP_LIBS) | $(APP_DEPS)
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
141 @echo " LINK $@"
52
1ac8fdd932b3 More work on build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 50
diff changeset
142 @$(CXX) $(LDFLAGS) -o $@ $+ $(APP_LIBS)
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
143
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
144
50
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
145 ###
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
146 ### Special targets
402446a76794 And more build system work.
Matti Hamalainen <ccr@tnsp.org>
parents: 49
diff changeset
147 ###
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
148 clean:
81
810ca71af506 Improve 'clean' target handling.
Matti Hamalainen <ccr@tnsp.org>
parents: 80
diff changeset
149 -$(RM) $(TARGETS) $(NOINST_TARGETS) $(CLEAN_TARGETS) $(OBJPATH)*.o
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
150
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
151 distclean: clean
52
1ac8fdd932b3 More work on build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 50
diff changeset
152 -$(RM) $(DISTCLEAN_TARGETS) *~ core *.core
48
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
153
200ec310660a Begin revamp of the buildsystem, don't use qmake anymore.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
154 .PHONY: clean distclean all