X-Git-Url: http://git.maemo.org/git/?a=blobdiff_plain;f=application%2Fapplication.pro;h=b3d2db7b9f6ed52c2d1c4c433d86ce479b4f7426;hb=f34df1d300d71147a35e53df7be382f65ea37df0;hp=8ddececbee13243987937e6033c0ee4b66df46fa;hpb=5b01e69cee4785bbd628448d2ac1870228502b89;p=quandoparte diff --git a/application/application.pro b/application/application.pro old mode 100644 new mode 100755 index 8ddecec..b3d2db7 --- a/application/application.pro +++ b/application/application.pro @@ -4,20 +4,50 @@ # #------------------------------------------------- -VERSION = 0.4.80 +VERSION = 0.5.1 +USE_RESOURCES = 0 -QT += webkit network +QT += network +CONFIG += qt +#CONFIG += link_pkgconfig +lessThan(QT_MAJOR_VERSION, 5) { + QT += webkit + CONFIG += webkit mobility + MOBILITY = location +} else { + QT += qml quick concurrent location webkitwidgets webkit +} + +contains(MEEGO_EDITION, harmattan) { + CONFIG += harmattan +} + +sailfish { + PLATFORM = sailfish + DEFINES += TARGET_PLATFORM_SAILFISH + # enable booster +packagesExist(qdeclarative-boostable) { + message("Building with qdeclarative-boostable support") + DEFINES += HAS_BOOSTER + PKGCONFIG += qdeclarative-boostable +} else { + warning("qdeclarative-boostable not available; startup times will be slower") +} + QMAKE_LFLAGS += -pie -rdynamic + PLATFORM_SOURCES = view.cpp + PLATFORM_HEADERS = view.h view_qt5.h +} harmattan { QT += declarative PLATFORM = harmattan DEFINES += TARGET_PLATFORM_HARMATTAN # enable booster CONFIG += qdeclarative-boostable - QMAKE_CXXFLAGS += -fPIC -fvisibility=hidden -fvisibility-inlines-hidden + QMAKE_CXXFLAGS += -fPIC -fvisibility=hidden -fvisibility-inlines-hidden -Wno-psabi QMAKE_LFLAGS += -pie -rdynamic PLATFORM_SOURCES = view.cpp - PLATFORM_HEADERS = view.h + PLATFORM_HEADERS = view.h view_qt4.h } maemo5 { QT += maemo5 @@ -36,14 +66,7 @@ maemo5 { settingsdialog.h \ stationview.h } -symbian { - QT += declarative - DEFINES += TARGET_PLATFORM_SYMBIAN - PLATFORM = symbian - PLATFORM_SOURCES = view.cpp - PLATFORM_HEADERS = view.h -} -!harmattan:!maemo5:!symbian { +!sailfish:!harmattan:!maemo5 { PLATFORM = desktop DEFINES += TARGET_PLATFORM_DESKTOP PLATFORM_SOURCES = view.cpp @@ -51,19 +74,22 @@ symbian { message(Compiling For: $$PLATFORM) message(Platform Sources: $$PLATFORM_SOURCES) +message(Qt Version: $$QT_MAJOR_VERSION"."$$QT_MINOR_VERSION) message(Qt Modules Used: $$QT) message(Building version: $$VERSION) -CONFIG += qt webkit mobility -MOBILITY = location - TARGET = quandoparte TEMPLATE = app VERSION_STRING = '\\"$${VERSION}\\"' DEFINES += QP_VERSION=\"$${VERSION_STRING}\" +contains(USE_RESOURCES, 1) { + DEFINES += USE_RESOURCES=1 + CONFIG += resources +} + !debug { -# DEFINES += QT_NO_DEBUG_OUTPUT + DEFINES += QT_NO_DEBUG_OUTPUT } TRANSLATIONS = resources/i18n/quandoparte_it.ts @@ -75,7 +101,8 @@ SOURCES += \ stationlistproxymodel.cpp \ settings.cpp \ dataprovider.cpp \ - stationschedule.cpp + stationschedulemodel.cpp \ + stationscheduleitem.cpp HEADERS += \ $$PLATFORM_HEADERS \ @@ -83,25 +110,41 @@ HEADERS += \ stationlistproxymodel.h \ settings.h \ dataprovider.h \ - stationschedule.h + stationschedulemodel.h \ + stationscheduleitem.h FORMS += \ settingsdialog.ui \ stationlistview.ui -symbian { - TARGET.UID3 = 0xe30fb688 - # TARGET.CAPABILITY += - TARGET.EPOCSTACKSIZE = 0x14000 - TARGET.EPOCHEAPSIZE = 0x020000 0x800000 -} +QMLSOURCES = \ + resources/harmattan/qml/main.qml \ + resources/harmattan/qml/StationListPage.qml \ + resources/harmattan/qml/StationPage.qml \ + resources/harmattan/qml/SearchBar.qml \ + resources/harmattan/qml/PageHeader.qml \ + resources/harmattan/qml/PageHeader.js \ + resources/harmattan/qml/uiconstants.js \ + resources/harmattan/qml/StationListPage.js \ + resources/harmattan/qml/AboutPage.qml \ + resources/harmattan/qml/InfoBar.qml \ + resources/harmattan/qml/DroppedShadow.qml \ + resources/harmattan/qml/DelayIndicator.qml \ + resources/harmattan/qml/StationScheduleDelegate.qml \ + resources/sailfish/qml/main.qml \ + resources/sailfish/qml/pages/StationListPage.qml \ + resources/sailfish/qml/pages/StationPage.qml OTHER_FILES += \ + resources/sailfish/applications/quandoparte.desktop \ resources/harmattan/applications/quandoparte.desktop \ resources/fremantle/applications/quandoparte.desktop \ icons/48x48/quandoparte.png \ icons/64x64/quandoparte.png \ + icons/80x80/quandoparte.png \ icons/scalable/quandoparte.svg \ + icons/sailfish/90x90/quandoparte.svg \ + icons/sailfish/scalable/quandoparte.svg \ icons/quandoparte.png \ resources/quandoparte.css \ resources/arrivals.css \ @@ -110,54 +153,63 @@ OTHER_FILES += \ resources/stations/stations.qpl \ resources/stations/generatelist.xq \ resources/stations/generateunclassifiedlist.xq \ - resources/harmattan/qml/main.qml \ - resources/harmattan/qml/StationListPage.qml \ - resources/harmattan/qml/StationPage.qml \ - resources/harmattan/qml/SearchBar.qml \ - resources/harmattan/qml/PageHeader.qml \ - resources/harmattan/qml/uiconstants.js \ - resources/harmattan/qml/StationListPage.js \ - resources/harmattan/qml/AboutPage.qml - -unix { - isEmpty(PREFIX) { - maemo5 { - PREFIX=/opt/usr - } else { - PREFIX=/usr/local - } - } + $$QMLSOURCES \ + resources/sailfish/qml/StationListPage.qml + +isEmpty(PREFIX) { maemo5 { - DESKTOPDIR=/usr/share/applications/hildon - } else { - DESKTOPDIR=$$PREFIX/share/applications + PREFIX=/opt/usr } - - BINDIR=$$PREFIX/bin + harmattan { + PREFIX=/opt/$${TARGET} + } + sailfish { + PREFIX=/usr + } + !maemo5:!harmattan:!sailfish { + PREFIX=/usr/local + } +} +maemo5 { + DESKTOPDIR=/usr/share/applications/hildon +} +harmattan { + DESKTOPDIR=/usr/share/applications +} +sailfish { + DESKTOPDIR=$$PREFIX/share/applications +} +desktop { + DESKTOPDIR=$$PREFIX/share/applications +} +BINDIR=$$PREFIX/bin +contains(USE_RESOURCES, 1) { + DATADIR=":" +} else { DATADIR=$$PREFIX/share/apps/$${TARGET} - DEFINES += DATADIR=\\\"$$DATADIR\\\" PKGDATADIR=\\\"$$PKGDATADIR\\\" } +DEFINES += DATADIR=\\\"$${DATADIR}\\\" PKGDATADIR=\\\"$${PKGDATADIR}\\\" message(Installing to prefix $$PREFIX) +message(Executable to $$BINDIR) +message(Desktop file to $$DESKTOPDIR) +message(Data to $$DATADIR) +message(Extra defines $$DEFINES) -unix:!symbian { - target.path = $$BINDIR - INSTALLS += target -} +target.path = $$BINDIR +INSTALLS += target -unix:!symbian { +unix:sailfish { desktopfile.files = resources/$$PLATFORM/applications/$${TARGET}.desktop desktopfile.path = $$DESKTOPDIR INSTALLS += desktopfile } -unix:!symbian { - css.files = resources/$${TARGET}.css resources/arrivals.css resources/departures.css +unix:sailfish { i18n.files = $$replace(TRANSLATIONS, .ts, .qm) stations.files = resources/stations/stations.qpl i18n.path = $$DATADIR/i18n - css.path = $$DATADIR/css stations.path = $$DATADIR/stations icon48.files = icons/48x48/$${TARGET}.png @@ -169,15 +221,51 @@ unix:!symbian { iconscalable.path = /usr/share/icons/hicolor/scalable/apps INSTALLS += icon48 - INSTALLS += icon64 INSTALLS += iconscalable - INSTALLS += css INSTALLS += i18n INSTALLS += stations } +maemo5 { + css.files = resources/$${TARGET}.css resources/arrivals.css resources/departures.css + css.path = $$DATADIR/css + !contains(USE_RESOURCES, 1) { + INSTALLS += css + } +} + +sailfish { + icon90.files = icons/sailfish/90x90/$${TARGET}.png + icon90.path = /usr/share/icons/hicolor/meegotouch/apps + INSTALLS += icon90 +} harmattan { - qml.files = resources/harmattan/qml/*.qml resources/harmattan/qml/*.js - qml.path = $$DATADIR/qml - INSTALLS += qml + icon80.files = icons/80x80/$${TARGET}.png + icon80.path = /usr/share/icons/hicolor/meegotouch/apps + INSTALLS += icon80 +} + +!contains(USE_RESOURCES, 1) { + sailfish { + qml.files = resources/sailfish/qml/*.qml \ + resources/sailfish/qml/*.js \ + resources/sailfish/qml/pages \ + resources/sailfish/qml/cover + qml.path = $$DATADIR/qml + INSTALLS += qml + } + harmattan { + qml.files = resources/harmattan/qml/*.qml resources/harmattan/qml/*.js + qml.path = $$DATADIR/qml + INSTALLS += qml + } +} + +contains(USE_RESOURCES, 1) { + RESOURCES += \ + quandoparte.qrc +} + +hack_to_fix_translations { + SOURCES += $$QMLSOURCES }