2014-12-13 19:07:10 +01:00
|
|
|
# The first path is used when the source is being build by packagers (pbuilder/sbuild/etc)
|
|
|
|
# The second path is used when you manually run the configure script in the root folder (eg when using qt creator)
|
|
|
|
exists($$OUT_PWD/../conf.pri) {
|
|
|
|
include($$OUT_PWD/../conf.pri)
|
2018-12-21 11:31:49 +01:00
|
|
|
}
|
|
|
|
else {
|
2014-12-13 19:07:10 +01:00
|
|
|
include(conf.pri)
|
|
|
|
}
|
2010-11-20 18:21:40 +01:00
|
|
|
|
2022-03-26 12:25:43 +01:00
|
|
|
# Custom function
|
|
|
|
# Return Qt translations files as list of paths
|
|
|
|
# It will return .qm files of qt/qtbase that aren't stub files.
|
|
|
|
defineReplace(qbt_get_qt_translations) {
|
|
|
|
# The $$[] syntax queries qmake properties
|
|
|
|
TMP_TRANSLATIONS = $$files($$[QT_INSTALL_TRANSLATIONS]/qt_??.qm)
|
|
|
|
TMP_TRANSLATIONS += $$files($$[QT_INSTALL_TRANSLATIONS]/qt_??_??.qm)
|
|
|
|
TMP_TRANSLATIONS += $$files($$[QT_INSTALL_TRANSLATIONS]/qtbase_??.qm)
|
|
|
|
TMP_TRANSLATIONS += $$files($$[QT_INSTALL_TRANSLATIONS]/qtbase_??_??.qm)
|
|
|
|
|
|
|
|
# Consider files less than 10KB as stub translations
|
|
|
|
for (TRANSLATION, TMP_TRANSLATIONS) {
|
|
|
|
TRANSLATION_SIZE = $$system("stat -f%z $${TRANSLATION}", true, EXIT_STATUS)
|
|
|
|
equals(EXIT_STATUS, 0):!lessThan(TRANSLATION_SIZE, 10240): FINAL_TRANSLATIONS += $${TRANSLATION}
|
|
|
|
}
|
|
|
|
|
|
|
|
return($$FINAL_TRANSLATIONS)
|
|
|
|
}
|
|
|
|
|
2022-03-26 14:14:10 +01:00
|
|
|
QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.15
|
2021-01-04 13:07:23 +01:00
|
|
|
|
2021-11-02 03:41:09 +01:00
|
|
|
DEFINES += _DARWIN_FEATURE_64_BIT_INODE
|
|
|
|
|
2017-08-11 07:37:06 +02:00
|
|
|
LIBS += -framework Carbon -framework IOKit -framework AppKit
|
2015-08-26 19:44:42 +02:00
|
|
|
|
2015-01-18 13:13:06 +01:00
|
|
|
DIST_PATH = ../dist/mac
|
|
|
|
|
2010-11-20 18:21:40 +01:00
|
|
|
document_icon.path = Contents/Resources
|
2015-01-18 13:13:06 +01:00
|
|
|
document_icon.files = $$DIST_PATH/qBitTorrentDocument.icns
|
2010-11-20 18:21:40 +01:00
|
|
|
QMAKE_BUNDLE_DATA += document_icon
|
2012-09-16 09:36:24 +02:00
|
|
|
|
|
|
|
qt_conf.path = Contents/Resources
|
2015-01-18 13:13:06 +01:00
|
|
|
qt_conf.files = $$DIST_PATH/qt.conf
|
2012-09-16 09:36:24 +02:00
|
|
|
QMAKE_BUNDLE_DATA += qt_conf
|
|
|
|
|
2015-01-29 23:57:08 +01:00
|
|
|
qt_translations.path = Contents/translations
|
2022-03-26 12:25:43 +01:00
|
|
|
qt_translations.files = $$qbt_get_qt_translations()
|
2012-09-16 09:36:24 +02:00
|
|
|
QMAKE_BUNDLE_DATA += qt_translations
|
|
|
|
|
2015-01-18 13:13:06 +01:00
|
|
|
ICON = $$DIST_PATH/qbittorrent_mac.icns
|
|
|
|
QMAKE_INFO_PLIST = $$DIST_PATH/Info.plist
|