]> git.sesse.net Git - vlc/blob - modules/gui/qt4/Modules.am
Skeleton for preferences widgets
[vlc] / modules / gui / qt4 / Modules.am
1 # vim:syntax=make
2 ## Howto
3 # For each Q_OBJECT:
4 #   - Add it without extension to TOMOC
5 #   - Add the moc.cpp to BUILT_SOURCES and nodist_SOURCES_qt4
6 #   - Add the cpp to SOURCES_qt4
7 #   - Add the hpp to EXTRA_DIST
8 # For each UI
9 #   - Add it without extension to TOUI
10 #   - Add it to EXTRA_DIST
11
12 AUTOMAKE_OPTIONS = subdir-objects
13
14 TOUI = ui/input_stats
15 UIH := $(TOUI:%=%.h)
16
17 TOMOC = main_interface \
18         dialogs_provider \
19         input_manager \
20         dialogs/playlist \
21         dialogs/streaminfo \
22         components/infopanels \
23         components/preferences_widgets \
24         util/input_slider
25 MOCCPP := $(TOMOC:%=%.moc.cpp)
26
27 nodist_SOURCES_qt4 = \
28                 main_interface.moc.cpp \
29                 dialogs_provider.moc.cpp \
30                 input_manager.moc.cpp \
31                 dialogs/playlist.moc.cpp \
32                 dialogs/streaminfo.moc.cpp \
33                 components/infopanels.moc.cpp \
34                 components/preferences_widgets.moc.cpp \
35                 util/input_slider.moc.cpp
36
37 if ENABLE_QT4
38 BUILT_SOURCES += $(UIH) $(nodist_SOURCES_qt4)
39 endif
40
41
42 $(MOCCPP): %.moc.cpp: %.hpp
43         @echo "$(MOC) $< -> $@"
44         $(MOC) -o $@ $<
45
46 $(UIH): %.h: %.ui
47         $(install_sh) -d ui
48         @echo "$(UIC) $< -> $@"
49         rm -f $@
50         echo "#define Q_(a,b) _(a)" > $@
51         $(UIC) -tr "Q_" $< >> $@
52
53
54 SOURCES_qt4 =   qt4.cpp \
55                 main_interface.cpp \
56                 dialogs_provider.cpp \
57                 input_manager.cpp \
58                 dialogs/playlist.cpp \
59                 dialogs/streaminfo.cpp \
60                 components/infopanels.cpp \
61                 components/preferences_widgets.cpp \
62                 util/input_slider.cpp
63                 $(NULL)
64
65 EXTRA_DIST += \
66         qt4.hpp \
67         main_interface.hpp \
68         dialogs_provider.hpp \
69         input_manager.hpp \
70         dialogs/playlist.hpp \
71         dialogs/streaminfo.hpp \
72         components/infopanels.hpp \
73         components/preferences_widgets.hpp \
74         util/input_slider.hpp \
75         ui/input_stats.ui
76