Use liblocation GPS only when built with CONFIG+=armel in Scratchbox
[situare] / src / src.pro
1 # -------------------------------------------------
2 # Project created by QtCreator 2010-03-26T07:57:35
3 # -------------------------------------------------
4 TARGET = ../situare
5 TEMPLATE = app
6 INCLUDEPATH += /usr/include/qjson
7 LIBS += -lqjson
8 RESOURCES += ../images.qrc \
9     ../languages.qrc
10 TRANSLATIONS += ../res/languages/situare_fi.ts
11 SOURCES += main.cpp \
12     ui/mainwindow.cpp \
13     situareservice/situareservice.cpp \
14     situareservice/imagefetcher.cpp \
15     facebookservice/facebookcredentials.cpp \
16     facebookservice/facebookauthentication.cpp \
17     map/mapengine.cpp \
18     map/mapview.cpp \
19     map/mapscene.cpp \
20     map/maptile.cpp \
21     map/mapfetcher.cpp \
22     map/ownlocationitem.cpp \
23     map/baselocationitem.cpp \
24     map/friendlocationitem.cpp \
25     ui/updatelocation/updatelocationdialog.cpp \
26     ui/updatelocation/texteditautoresizer.cpp \
27     ui/friendlistview.cpp \
28     ui/friendlistitem.cpp \
29     user/user.cpp \
30     ui/avatarimage.cpp \
31     engine/engine.cpp \
32     ui/settingsdialog.cpp \
33     ui/logindialog.cpp \
34     map/maptilerequest.cpp \
35     ui/imagebutton.cpp \
36     ui/friendlistpanel.cpp \
37     ui/userinfopanel.cpp \
38     ui/panelsidebar.cpp \
39     ui/panelsliderbar.cpp \
40     map/friendgroupitem.cpp \
41     map/frienditemshandler.cpp \
42     gps/gpsposition.cpp \
43     map/gpslocationitem.cpp \
44     ui/zoombuttonpanel.cpp \
45     ui/userinfo.cpp \
46     ui/sidepanel.cpp \
47     ui/zoombutton.cpp \
48     network/networkaccessmanager.cpp \
49     network/networkhandler.cpp \
50     network/networkcookiejar.cpp \
51     network/networkreply.cpp
52 HEADERS += ui/mainwindow.h \
53     map/mapengine.h \
54     map/mapview.h \
55     map/mapscene.h \
56     map/maptile.h \
57     map/mapfetcher.h \
58     map/mapcommon.h \
59     map/ownlocationitem.h \
60     map/baselocationitem.h \
61     map/friendlocationitem.h \
62     ui/updatelocation/updatelocationdialog.h \
63     ui/updatelocation/texteditautoresizer.h \
64     situareservice/situareservice.h \
65     situareservice/situarecommon.h \
66     situareservice/imagefetcher.h \
67     facebookservice/facebookcredentials.h \
68     facebookservice/facebookauthentication.h \
69     facebookservice/facebookcommon.h \
70     ui/friendlistview.h \
71     ui/friendlistitem.h \
72     user/user.h \
73     ui/avatarimage.h \
74     engine/engine.h \
75     ui/settingsdialog.h \
76     ui/logindialog.h \
77     map/maptilerequest.h \
78     ui/imagebutton.h \
79     ui/friendlistpanel.h \
80     ui/userinfopanel.h \
81     ui/panelcommon.h \
82     ui/panelsidebar.h \
83     ui/panelsliderbar.h \
84     map/friendgroupitem.h \
85     map/frienditemshandler.h \
86     gps/gpsposition.h \
87     map/gpslocationitem.h \
88     gps/gpscommon.h \
89     ui/zoombuttonpanel.h \
90     common.h \
91     ui/userinfo.h \
92     ui/sidepanel.h \
93     ui/zoombutton.h \
94     network/networkaccessmanager.h \
95     network/networkhandler.h \
96     network/networkcookiejar.h \
97     network/networkreply.h
98 QT += network \
99     webkit
100
101 DEFINES += QT_NO_DEBUG_OUTPUT
102
103 simulator {
104     SOURCES += network/networkhandlerprivatestub.cpp \
105                gps/gpspositionprivate.cpp
106     HEADERS += network/networkhandlerprivatestub.h \
107                gps/gpspositionprivate.h
108     QT += maemo5
109     CONFIG += mobility
110     MOBILITY += location
111 } else:maemo5 {
112     armel {
113         DEFINES += ARMEL
114         INCLUDEPATH += /usr/include/glib-2.0 /usr/lib/glib-2.0/include
115         SOURCES += network/networkhandlerprivate.cpp
116         HEADERS += network/networkhandlerprivate.h
117         QT += dbus
118         CONFIG += icd2
119         SOURCES += gps/gpspositionprivateliblocation.cpp \
120                    gps/liblocationwrapper.cpp \
121                    gps/geopositioninfo.cpp \
122                    gps/geocoordinate.cpp
123         HEADERS += gps/gpspositionprivateliblocation.h \
124                    gps/liblocationwrapper.h \
125                    gps/geopositioninfo.h \
126                    gps/geocoordinate.h
127         CONFIG += link_pkgconfig
128     } else {
129         SOURCES += gps/gpspositionprivatestub.cpp \
130                    network/networkhandlerprivatestub.cpp
131         HEADERS += gps/gpspositionprivatestub.h \
132                    network/networkhandlerprivatestub.h
133     }
134
135     QT += maemo5
136
137     PKGCONFIG += glib-2.0 liblocation
138     message([QJson])
139     message(Make sure you have QJson development headers installed)
140     message(add: deb http://repository.maemo.org/extras-devel fremantle free non-free)
141     message(to Scratchbox's sources.list in /etc/apt)
142     message(run: apt-get update)
143     message(install headers with: apt-get install libqjson-dev)
144     message([QtMobility])
145     message(Make sure you have QtMobility development headers installed)
146     message(install headers with: apt-get install libqtm-dev)
147 } else {
148     SOURCES += gps/gpspositionprivatestub.cpp \
149                network/networkhandlerprivatestub.cpp
150     HEADERS += gps/gpspositionprivatestub.h \
151                network/networkhandlerprivatestub.h
152     message(QJson built in)
153     message(Make sure you have QJson development headers installed)
154     message(install headers with: sudo apt-get install libqjson-dev)
155 }
156
157 # -----------------------------------------------------------------
158 # Debian packetizing additions
159 # -----------------------------------------------------------------
160 unix {
161     # VARIABLES
162     isEmpty(PREFIX):PREFIX = /usr
163     BINDIR = $$PREFIX/bin
164     DATADIR = $$PREFIX/share
165     DEFINES += DATADIR=\\\"$$DATADIR\\\" \
166         PKGDATADIR=\\\"$$PKGDATADIR\\\"
167
168     # MAKE INSTALL
169     desktop.path = $$DATADIR/applications/hildon
170     desktop.files += situare.desktop
171     INSTALLS += desktop
172     icon48.path = $$DATADIR/icons/hicolor/48x48/apps
173     icon48.files += ../res/icon/48x48/situare.png
174     INSTALLS += icon48
175     icon64.path = $$DATADIR/icons/hicolor/64x64/apps
176     icon64.files += ../res/icon/64x64/situare.png
177     INSTALLS += icon64
178     target.path = $$BINDIR
179     INSTALLS += target
180 }