summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJaromil <jaromil@dyne.org>2011-03-07 18:45:49 (GMT)
committer Jaromil <jaromil@dyne.org>2011-03-07 18:45:49 (GMT)
commitb341c8c8ac98fe385021a3f6a9a06a26ee572b75 (patch)
tree9b32a071f2ada239033fe60fbc8803debc00adff
parent56f08fe5f38616d75be866e44323a9a6b95032bd (diff)
using BUILT_SOURCES to pre-build uic and moc stuff for qt4
-rw-r--r--qt/Makefile.am44
1 files changed, 27 insertions, 17 deletions
diff --git a/qt/Makefile.am b/qt/Makefile.am
index b3ed3c6..faa6376 100644
--- a/qt/Makefile.am
+++ b/qt/Makefile.am
@@ -2,9 +2,9 @@ AM_CXXFLAGS = -I$(top_srcdir)/src/include $(SDL_CFLAGS) \
$(QTGUI_CFLAGS) -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED \
-DPREFIX="\"$(prefix)\"" -DDATADIR="\"$(datadir)\""
-%.h: %.ui
+ui_%.h: %.ui
uic -o $@ $<
-%.cpp: %.ui
+ui_%.cpp: %.ui
uic -o $@ -impl $*.h $<
# This rule lets GNU make create any moc_*.cpp from the equivalent *.h
# You have one .h file, it's called myapp.h. Therefore, here I list
@@ -12,10 +12,24 @@ AM_CXXFLAGS = -I$(top_srcdir)/src/include $(SDL_CFLAGS) \
moc_%.cpp: %.h
moc $< -o $@
-qfreej_ui = ui_qfreej.h
-ui_qfreej.h: ui_qfreej.ui
+ui_qfreej.h:
+ uic -o ui_qfreej.h ui_qfreej.ui
-SOURCES = ui_qfreej.h main.cpp \
+
+BUILT_SOURCES = ui_qfreej.h \
+ moc_qfreej.cpp \
+ moc_QqComboBlit.cpp \
+ moc_QqWidget.cpp \
+ moc_QqComboFilter.cpp \
+ moc_QqFiltersApplied.cpp \
+ moc_QqTabWidget.cpp \
+ moc_Sound.cpp \
+ moc_qJackClient.cpp \
+ moc_qOpacity.cpp \
+ moc_qEncoder.cpp
+
+
+SOURCES = main.cpp \
qfreej.cpp \
QqComboBlit.cpp \
QqWidget.cpp \
@@ -25,21 +39,17 @@ SOURCES = ui_qfreej.h main.cpp \
FakeWindow.cpp \
QqTabWidget.cpp \
Sound.cpp \
- qJackClient.cpp \
+ qJackClient.cpp \
qOpacity.cpp \
- qEncoder.cpp \
- moc_qfreej.cpp \
- moc_QqComboBlit.cpp \
- moc_QqWidget.cpp \
- moc_QqComboFilter.cpp \
- moc_QqFiltersApplied.cpp \
- moc_QqTabWidget.cpp \
- moc_Sound.cpp \
- moc_qJackClient.cpp \
- moc_qOpacity.cpp \
- moc_qEncoder.cpp
+ qEncoder.cpp \
+ $(BUILT_SOURCES)
bin_PROGRAMS = qfreej
qfreej_SOURCES = $(SOURCES)
qfreej_LDADD = -lfreej $(SDL_LIBS) $(QTGUI_LIBS)
+
+clean:
+ rm -f qfreej *.o
+ rm -f moc_*.cpp moc_*.h
+ rm -f ui_*.h \ No newline at end of file