X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=minitube.pro;h=e75a41dc0e9dd8ee802a4680110f946b53e618a4;hb=be5ee6ccd9b29c9d5ca59e4a3d4adf53bac6bc8d;hp=42d8808643c44910068dbdfac6cd08478f665608;hpb=994e6e5e95196b0e36c680b1fd496f12d71739c9;p=minitube diff --git a/minitube.pro b/minitube.pro index 42d8808..e75a41d 100644 --- a/minitube.pro +++ b/minitube.pro @@ -1,6 +1,7 @@ -CONFIG += release +CONFIG += c++17 exceptions_off rtti_off optimize_full object_parallel_to_source + TEMPLATE = app -VERSION = 2.5.2 +VERSION = 3.6.1 DEFINES += APP_VERSION="$$VERSION" APP_NAME = Minitube @@ -9,17 +10,21 @@ DEFINES += APP_NAME="$$APP_NAME" APP_UNIX_NAME = minitube DEFINES += APP_UNIX_NAME="$$APP_UNIX_NAME" -DEFINES += APP_PHONON -DEFINES += APP_PHONON_SEEK -DEFINES += APP_SNAPSHOT -DEFINES += APP_YT3 - message(Building $${APP_NAME} $${VERSION}) message(Qt $$[QT_VERSION] in $$[QT_INSTALL_PREFIX]) -DEFINES *= QT_NO_DEBUG_OUTPUT -DEFINES *= QT_USE_QSTRINGBUILDER -DEFINES *= QT_STRICT_ITERATORS +DEFINES += APP_SNAPSHOT + +CONFIG -= debug_and_release +CONFIG(debug, debug|release): { + message(Building for debug) +} +CONFIG(release, debug|release): { + message(Building for release) + DEFINES *= QT_NO_DEBUG_OUTPUT +} + +DEFINES *= QT_USE_QSTRINGBUILDER QT_STRICT_ITERATORS QT_DEPRECATED_WARNINGS !contains(DEFINES, APP_GOOGLE_API_KEY=.+) { warning("You need to specify a Google API Key, refer to the README.md file for details") @@ -27,26 +32,31 @@ DEFINES *= QT_STRICT_ITERATORS TARGET = $${APP_UNIX_NAME} -QT += network sql script -qt:greaterThan(QT_MAJOR_VERSION, 4) { - contains(QT, gui): QT *= widgets -} +QT += widgets network sql qml + +include(lib/http/http.pri) +include(lib/idle/idle.pri) + +DEFINES += MEDIA_MPV +include(lib/media/media.pri) include(src/qtsingleapplication/qtsingleapplication.pri) +include(src/invidious/invidious.pri) +include(src/ytjs/ytjs.pri) + +INCLUDEPATH += $$PWD/src HEADERS += src/video.h \ - src/searchlineedit.h \ + src/messagebar.h \ src/spacer.h \ src/constants.h \ src/playlistitemdelegate.h \ - src/networkaccess.h \ + src/updateutils.h \ + src/videoapi.h \ src/videomimedata.h \ - src/global.h \ - src/updatechecker.h \ src/searchparams.h \ src/minisplitter.h \ src/loadingwidget.h \ - src/videoareawidget.h \ src/autocomplete.h \ src/videodefinition.h \ src/fontutils.h \ @@ -74,12 +84,12 @@ HEADERS += src/video.h \ src/view.h \ src/playlistmodel.h \ src/videosource.h \ + src/waitingspinnerwidget.h \ src/ytsearch.h \ src/ytstandardfeed.h \ src/standardfeedsview.h \ src/ytregions.h \ src/ytcategories.h \ - src/ytfeedreader.h \ src/ytsuggester.h \ src/videosourcewidget.h \ src/regionsview.h \ @@ -104,22 +114,25 @@ HEADERS += src/video.h \ src/ytchannel.h \ src/yt3.h \ src/paginatedvideosource.h \ - src/compatibility/qurlqueryhelper.h \ - src/compatibility/pathsservice.h \ src/searchwidget.h \ - src/exlineedit.h \ - src/channellistview.h + src/channellistview.h \ + src/httputils.h \ + src/appwidget.h \ + src/clickablelabel.h \ + src/ytvideo.h \ + src/toolbarmenu.h \ + src/sharetoolbar.h \ + src/videoarea.h \ + src/searchlineedit.h SOURCES += src/main.cpp \ - src/searchlineedit.cpp \ + src/messagebar.cpp \ src/spacer.cpp \ + src/updateutils.cpp \ src/video.cpp \ src/videomimedata.cpp \ - src/updatechecker.cpp \ - src/networkaccess.cpp \ src/searchparams.cpp \ src/minisplitter.cpp \ src/loadingwidget.cpp \ - src/videoareawidget.cpp \ src/autocomplete.cpp \ src/videodefinition.cpp \ src/constants.cpp \ @@ -147,12 +160,12 @@ SOURCES += src/main.cpp \ src/playlistitemdelegate.cpp \ src/playlistmodel.cpp \ src/videosource.cpp \ + src/waitingspinnerwidget.cpp \ src/ytsearch.cpp \ src/ytstandardfeed.cpp \ src/standardfeedsview.cpp \ src/ytregions.cpp \ src/ytcategories.cpp \ - src/ytfeedreader.cpp \ src/ytsuggester.cpp \ src/videosourcewidget.cpp \ src/regionsview.cpp \ @@ -177,10 +190,19 @@ SOURCES += src/main.cpp \ src/ytchannel.cpp \ src/yt3.cpp \ src/paginatedvideosource.cpp \ - src/compatibility/pathsservice.cpp \ - src/exlineedit.cpp \ - src/channellistview.cpp + src/channellistview.cpp \ + src/httputils.cpp \ + src/appwidget.cpp \ + src/clickablelabel.cpp \ + src/ytvideo.cpp \ + src/toolbarmenu.cpp \ + src/sharetoolbar.cpp \ + src/videoarea.cpp \ + src/searchlineedit.cpp + RESOURCES += resources.qrc +RESOURCES += $$files(icons/*.png, true) + DESTDIR = build/target/ OBJECTS_DIR = build/obj/ MOC_DIR = build/moc/ @@ -189,32 +211,32 @@ RCC_DIR = build/rcc/ # Tell Qt Linguist that we use UTF-8 strings in our sources CODECFORTR = UTF-8 CODECFORSRC = UTF-8 + include(locale/locale.pri) # deploy DISTFILES += CHANGES COPYING unix:!mac { DEFINES += APP_LINUX - qt:greaterThan(QT_MAJOR_VERSION, 4) { - LIBS += -lphonon4qt5 - INCLUDEPATH += /usr/include/phonon4qt5 - } else { - QT += phonon - INCLUDEPATH += /usr/include/phonon - } QT += dbus HEADERS += src/gnomeglobalshortcutbackend.h SOURCES += src/gnomeglobalshortcutbackend.cpp + isEmpty(PREFIX):PREFIX = /usr + BINDIR = $$PREFIX/bin INSTALLS += target target.path = $$BINDIR + DATADIR = $$PREFIX/share PKGDATADIR = $$DATADIR/minitube DEFINES += DATADIR=\\\"$$DATADIR\\\" \ PKGDATADIR=\\\"$$PKGDATADIR\\\" + INSTALLS += translations \ + sounds \ desktop \ + appdata \ iconsvg \ icon16 \ icon22 \ @@ -226,8 +248,12 @@ unix:!mac { icon512 translations.path = $$PKGDATADIR translations.files += $$DESTDIR/locale + sounds.path = $$PKGDATADIR + sounds.files += sounds/ desktop.path = $$DATADIR/applications desktop.files += minitube.desktop + appdata.path = $$DATADIR/appdata + appdata.files += minitube.appdata.xml iconsvg.path = $$DATADIR/icons/hicolor/scalable/apps iconsvg.files += data/minitube.svg icon16.path = $$DATADIR/icons/hicolor/16x16/apps @@ -247,7 +273,15 @@ unix:!mac { icon512.path = $$DATADIR/icons/hicolor/512x512/apps icon512.files += data/512x512/minitube.png } + mac|win32|contains(DEFINES, APP_UBUNTU):include(local/local.pri) -OTHER_FILES += \ - sounds/snapshot.wav +!contains(DEFINES, APP_MAC_STORE) { + # DEFINES += UPDATER_NO_SPARKLE + include(lib/updater/updater.pri) +} + +message(CONFIG: $$CONFIG) +message(DEFINES: $$DEFINES) +message(QMAKE_CXXFLAGS: $$QMAKE_CXXFLAGS) +message(QMAKE_LFLAGS: $$QMAKE_LFLAGS)