]> git.sur5r.net Git - minitube/blob - minitube.pro
Merge tag 'upstream/2.4'
[minitube] / minitube.pro
1 CONFIG += release
2 TEMPLATE = app
3 VERSION = 2.4
4 DEFINES += APP_VERSION="$$VERSION"
5
6 APP_NAME = Minitube
7 DEFINES += APP_NAME="$$APP_NAME"
8
9 APP_UNIX_NAME = minitube
10 DEFINES += APP_UNIX_NAME="$$APP_UNIX_NAME"
11
12 DEFINES += APP_PHONON
13 DEFINES += APP_PHONON_SEEK
14 DEFINES += APP_SNAPSHOT
15 DEFINES += APP_YT3
16
17 DEFINES *= QT_NO_DEBUG_OUTPUT
18 DEFINES *= QT_USE_QSTRINGBUILDER
19 DEFINES *= QT_STRICT_ITERATORS
20
21 !contains(DEFINES, APP_GOOGLE_API_KEY) {
22     warning("You need to specify a Google API Key, refer to the README.md file for details")
23 }
24
25 TARGET = $${APP_UNIX_NAME}
26
27 QT += network sql script
28 qt:greaterThan(QT_MAJOR_VERSION, 4) {
29     contains(QT, gui): QT *= widgets
30 }
31
32 include(src/qtsingleapplication/qtsingleapplication.pri)
33
34 HEADERS += src/video.h \
35     src/searchlineedit.h \
36     src/urllineedit.h \
37     src/spacer.h \
38     src/constants.h \
39     src/playlistitemdelegate.h \
40     src/networkaccess.h \
41     src/videomimedata.h \
42     src/global.h \
43     src/updatechecker.h \
44     src/searchparams.h \
45     src/minisplitter.h \
46     src/loadingwidget.h \
47     src/videoareawidget.h \
48     src/autocomplete.h \
49     src/videodefinition.h \
50     src/fontutils.h \
51     src/globalshortcuts.h \
52     src/globalshortcutbackend.h \
53     src/downloadmanager.h \
54     src/downloaditem.h \
55     src/downloadview.h \
56     src/downloadmodel.h \
57     src/downloadlistview.h \
58     src/downloadsettings.h \
59     src/suggester.h \
60     src/channelsuggest.h \
61     src/temporary.h \
62     src/segmentedcontrol.h \
63     src/playlistview.h \
64     src/refinesearchwidget.h \
65     src/refinesearchbutton.h \
66     src/sidebarwidget.h \
67     src/homeview.h \
68     src/aboutview.h \
69     src/mainwindow.h \
70     src/mediaview.h \
71     src/searchview.h \
72     src/view.h \
73     src/playlistmodel.h \
74     src/videosource.h \
75     src/ytsearch.h \
76     src/ytstandardfeed.h \
77     src/standardfeedsview.h \
78     src/ytregions.h \
79     src/ytcategories.h \
80     src/ytfeedreader.h \
81     src/ytsuggester.h \
82     src/videosourcewidget.h \
83     src/regionsview.h \
84     src/ytsinglevideosource.h \
85     src/sidebarheader.h \
86     src/iconutils.h \
87     src/diskcache.h \
88     src/gridwidget.h \
89     src/painterutils.h \
90     src/database.h \
91     src/channelaggregator.h \
92     src/channelmodel.h \
93     src/aggregatevideosource.h \
94     src/channelview.h \
95     src/channelitemdelegate.h \
96     src/jsfunctions.h \
97     src/seekslider.h \
98     src/snapshotsettings.h \
99     src/snapshotpreview.h \
100     src/datautils.h \
101     src/yt3listparser.h \
102     src/ytchannel.h \
103     src/yt3.h \
104     src/paginatedvideosource.h
105 SOURCES += src/main.cpp \
106     src/searchlineedit.cpp \
107     src/urllineedit.cpp \
108     src/spacer.cpp \
109     src/video.cpp \
110     src/videomimedata.cpp \
111     src/updatechecker.cpp \
112     src/networkaccess.cpp \
113     src/searchparams.cpp \
114     src/minisplitter.cpp \
115     src/loadingwidget.cpp \
116     src/videoareawidget.cpp \
117     src/autocomplete.cpp \
118     src/videodefinition.cpp \
119     src/constants.cpp \
120     src/fontutils.cpp \
121     src/globalshortcuts.cpp \
122     src/globalshortcutbackend.cpp \
123     src/downloadmanager.cpp \
124     src/downloaditem.cpp \
125     src/downloadview.cpp \
126     src/downloadmodel.cpp \
127     src/downloadlistview.cpp \
128     src/downloadsettings.cpp \
129     src/channelsuggest.cpp \
130     src/temporary.cpp \
131     src/segmentedcontrol.cpp \
132     src/playlistview.cpp \
133     src/refinesearchwidget.cpp \
134     src/refinesearchbutton.cpp \
135     src/sidebarwidget.cpp \
136     src/homeview.cpp \
137     src/mainwindow.cpp \
138     src/mediaview.cpp \
139     src/aboutview.cpp \
140     src/searchview.cpp \
141     src/playlistitemdelegate.cpp \
142     src/playlistmodel.cpp \
143     src/videosource.cpp \
144     src/ytsearch.cpp \
145     src/ytstandardfeed.cpp \
146     src/standardfeedsview.cpp \
147     src/ytregions.cpp \
148     src/ytcategories.cpp \
149     src/ytfeedreader.cpp \
150     src/ytsuggester.cpp \
151     src/videosourcewidget.cpp \
152     src/regionsview.cpp \
153     src/ytsinglevideosource.cpp \
154     src/sidebarheader.cpp \
155     src/iconutils.cpp \
156     src/diskcache.cpp \
157     src/gridwidget.cpp \
158     src/painterutils.cpp \
159     src/database.cpp \
160     src/channelaggregator.cpp \
161     src/channelmodel.cpp \
162     src/aggregatevideosource.cpp \
163     src/channelview.cpp \
164     src/channelitemdelegate.cpp \
165     src/jsfunctions.cpp \
166     src/seekslider.cpp \
167     src/snapshotsettings.cpp \
168     src/snapshotpreview.cpp \
169     src/datautils.cpp \
170     src/yt3listparser.cpp \
171     src/ytchannel.cpp \
172     src/yt3.cpp \
173     src/paginatedvideosource.cpp
174 RESOURCES += resources.qrc
175 DESTDIR = build/target/
176 OBJECTS_DIR = build/obj/
177 MOC_DIR = build/moc/
178 RCC_DIR = build/rcc/
179
180 # Tell Qt Linguist that we use UTF-8 strings in our sources
181 CODECFORTR = UTF-8
182 CODECFORSRC = UTF-8
183 include(locale/locale.pri)
184
185 # deploy
186 DISTFILES += CHANGES COPYING
187 unix:!mac {
188     qt:greaterThan(QT_MAJOR_VERSION, 4) {
189         LIBS += -lphonon4qt5
190         INCLUDEPATH += /usr/include/phonon4qt5
191     } else {
192         QT += phonon
193         INCLUDEPATH += /usr/include/phonon
194     }
195     QT += dbus
196     HEADERS += src/gnomeglobalshortcutbackend.h
197     SOURCES += src/gnomeglobalshortcutbackend.cpp
198     isEmpty(PREFIX):PREFIX = /usr
199     BINDIR = $$PREFIX/bin
200     INSTALLS += target
201     target.path = $$BINDIR
202     DATADIR = $$PREFIX/share
203     PKGDATADIR = $$DATADIR/minitube
204     DEFINES += DATADIR=\\\"$$DATADIR\\\" \
205         PKGDATADIR=\\\"$$PKGDATADIR\\\"
206     INSTALLS += translations \
207         desktop \
208         iconsvg \
209         icon16 \
210         icon22 \
211         icon32 \
212         icon48 \
213         icon64 \
214         icon128 \
215         icon256 \
216         icon512
217     translations.path = $$PKGDATADIR
218     translations.files += $$DESTDIR/locale
219     desktop.path = $$DATADIR/applications
220     desktop.files += minitube.desktop
221     iconsvg.path = $$DATADIR/icons/hicolor/scalable/apps
222     iconsvg.files += data/minitube.svg
223     icon16.path = $$DATADIR/icons/hicolor/16x16/apps
224     icon16.files += data/16x16/minitube.png
225     icon22.path = $$DATADIR/icons/hicolor/22x22/apps
226     icon22.files += data/22x22/minitube.png
227     icon32.path = $$DATADIR/icons/hicolor/32x32/apps
228     icon32.files += data/32x32/minitube.png
229     icon48.path = $$DATADIR/icons/hicolor/48x48/apps
230     icon48.files += data/48x48/minitube.png
231     icon64.path = $$DATADIR/icons/hicolor/64x64/apps
232     icon64.files += data/64x64/minitube.png
233     icon128.path = $$DATADIR/icons/hicolor/128x128/apps
234     icon128.files += data/128x128/minitube.png
235     icon256.path = $$DATADIR/icons/hicolor/256x256/apps
236     icon256.files += data/256x256/minitube.png
237     icon512.path = $$DATADIR/icons/hicolor/512x512/apps
238     icon512.files += data/512x512/minitube.png
239 }
240 mac|win32|contains(DEFINES, APP_UBUNTU):include(local/local.pri)
241
242 OTHER_FILES += \
243     sounds/snapshot.wav