-
Notifications
You must be signed in to change notification settings - Fork 1
/
leviosa.pro
282 lines (248 loc) · 9.08 KB
/
leviosa.pro
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
QT += quick svg network sql concurrent
CONFIG += c++11
DEV_LIBS_PATH = /Users/anton.titkov/DevLibs
# Android specifics
android {
QT += androidextras
DISTFILES += \
android/AndroidManifest.xml \
android/gradle/wrapper/gradle-wrapper.jar \
android/gradlew \
android/res/values/libs.xml \
android/build.gradle \
android/gradle/wrapper/gradle-wrapper.properties \
android/src/com/atlascoder/
# EspTouch backport
HEADERS += esptouch/EspTouchTaskAndroid.h
SOURCES += esptouch/EspTouchTaskAndroid.cpp
ANDROID_PACKAGE_SOURCE_DIR = $$PWD/android
# AWS libs
AWS = $$DEV_LIBS_PATH/aws-sdk-cpp/android/aws-cpp-sdk
LIBS += \
-L$$AWS-iam -laws-cpp-sdk-iam \
-L$$AWS-iot -laws-cpp-sdk-iot \
-L$$AWS-cognito-idp -laws-cpp-sdk-cognito-idp \
-L$$AWS-cognito-sync -laws-cpp-sdk-cognito-sync \
-L$$AWS-access-management -laws-cpp-sdk-access-management \
-L$$AWS-cognito-identity -laws-cpp-sdk-cognito-identity \
-L$$AWS-identity-management -laws-cpp-sdk-identity-management \
-L$$AWS-logs -laws-cpp-sdk-logs \
-L$$AWS-core -laws-cpp-sdk-core \
-L$$DEV_LIBS_PATH/aws-sdk-cpp/android/external/curl/lib -lcurl \
-L$$DEV_LIBS_PATH/aws-sdk-cpp/android/external/openssl/lib -lssl -lcrypto \
INCLUDEPATH += \
Users/anton.titkov/DevLibs/aws-sdk-cpp/android/external/openssl/include
# Crypto++
INCLUDEPATH += $$DEV_LIBS_PATH/cryptopp/android/include
LIBS += -L$$DEV_LIBS_PATH/cryptopp/android/lib -lcryptopp
ANDROID_EXTRA_LIBS = \
$$PWD/android/libs/openssl/libcrypto.so \
$$PWD/android/libs/openssl/libssl.so
}
# iOS specifics
ios {
app_launch_images.files = $$PWD/ios/SplashScreen.xib $$PWD/ios/leviosa-logo.png
QMAKE_BUNDLE_DATA = app_launch_images
QMAKE_INFO_PLIST = $$PWD/ios/Info.plist
PRODUCT_BUNDLE_IDENTIFIER = ZA64J3S592.com.leviosashades.app
# EspTouch backport
SC_IOS = $$PWD/../../esptouch-qt-ios
# Backports to native NetworkReachability and ESPTouch components
OBJECTIVE_HEADERS += \
$$PWD/ios/src/Reachability.h \
$$PWD/ios/src/ReachabiltyListener.h \
$$SC_IOS/ESPDataCode.h \
$$SC_IOS/ESPDatumCode.h \
$$SC_IOS/ESPGuideCode.h \
$$SC_IOS/ESPTouchGenerator.h \
$$SC_IOS/ESPTouchResult.h \
$$SC_IOS/ESPTouchTaskParameter.h \
$$SC_IOS/ESPUDPSocketClient.h \
$$SC_IOS/ESPUDPSocketServer.h \
$$SC_IOS/ESPVersionMacro.h \
$$SC_IOS/ESP_ByteUtil.h \
$$SC_IOS/ESP_CRC8.h \
$$SC_IOS/ESP_NetUtil.h \
$$SC_IOS/ESP_WifiUtil.h \
$$SC_IOS/ESPTouchTask.h \
$$SC_IOS/ESPTouchDelegate.h \
$$SC_IOS/ESPTouchHolder.h
OBJECTIVE_SOURCES += \
$$PWD/ios/src/Reachability.mm \
$$PWD/ios/src/ReachabilityListener.mm \
$$SC_IOS/ESPDataCode.mm \
$$SC_IOS/ESPDatumCode.mm \
$$SC_IOS/ESPGuideCode.mm \
$$SC_IOS/ESPTouchGenerator.mm \
$$SC_IOS/ESPTouchResult.mm \
$$SC_IOS/ESPTouchTaskParameter.mm \
$$SC_IOS/ESPUDPSocketClient.mm \
$$SC_IOS/ESPUDPSocketServer.mm \
$$SC_IOS/ESP_ByteUtil.mm \
$$SC_IOS/ESP_CRC8.mm \
$$SC_IOS/ESP_NetUtil.mm \
$$SC_IOS/ESP_WifiUtil.mm \
$$SC_IOS/ESPTouchTask.mm \
$$SC_IOS/ESPTouchHolder.mm
HEADERS += esptouch/EspTouchTaskIOS.h
SOURCES += esptouch/EspTouchTaskIOS.cpp
LIBS += -framework SystemConfiguration
# AWS
AWS = $$DEV_LIBS_PATH/aws-sdk-cpp/xcode/aws-cpp-sdk
ASX = Release-iphoneos
LIBS += \
-L$$AWS-core/$$ASX -laws-cpp-sdk-core \
-L$$AWS-iam/$$ASX -laws-cpp-sdk-iam \
-L$$AWS-access-management/$$ASX -laws-cpp-sdk-access-management \
-L$$AWS-cognito-identity/$$ASX -laws-cpp-sdk-cognito-identity \
-L$$AWS-iot/$$ASX -laws-cpp-sdk-iot \
-L$$AWS-cognito-idp/$$ASX -laws-cpp-sdk-cognito-idp \
-L$$AWS-cognito-sync/$$ASX -laws-cpp-sdk-cognito-sync \
-L$$AWS-identity-management/$$ASX -laws-cpp-sdk-identity-management \
-L$$DEV_LIBS_PATH/libcurl/lib -lcurl
# Crypto++
INCLUDEPATH += $$DEV_LIBS_PATH/cryptopp/ios/include
LIBS += -L$$DEV_LIBS_PATH/cryptopp/ios -lcryptopp
}
# macOS specifics
macos {
AWS = $$DEV_LIBS_PATH/aws-sdk-cpp/host/aws-cpp-sdk
LIBS += \
-L$$AWS-core -laws-cpp-sdk-core \
-L$$AWS-iam -laws-cpp-sdk-iam \
-L$$AWS-access-management -laws-cpp-sdk-access-management \
-L$$AWS-cognito-identity -laws-cpp-sdk-cognito-identity \
-L$$AWS-iot -laws-cpp-sdk-iot \
-L$$AWS-cognito-idp -laws-cpp-sdk-cognito-idp \
-L$$AWS-cognito-sync -laws-cpp-sdk-cognito-sync \
-L$$AWS-identity-management -laws-cpp-sdk-identity-management \
-lcurl
#import Crypto++ lib
INCLUDEPATH += $$DEV_LIBS_PATH/cryptopp/build-host/include
LIBS += -L$$DEV_LIBS_PATH/cryptopp/build-host/lib -lcryptopp
}
# AWS headers same for all platforms
AWS_H = $$DEV_LIBS_PATH/aws-sdk-cpp/src/aws-sdk-cpp/aws-cpp-sdk
INCLUDEPATH += $$AWS_H-core/include \
$$AWS_H-logs/include \
$$AWS_H-iam/include \
$$AWS_H-access-management/include \
$$AWS_H-cognito-identity/include \
$$AWS_H-cognito-idp/include \
$$AWS_H-iot/include \
$$AWS_H-cognito-sync/include \
$$AWS_H-identity-management/include
SOURCES += \
EspTouchSetup.cpp \
core/WanAPI.cpp \
core/User.cpp \
core/UserDAO.cpp \
aws/CognitoSyncAPI.cpp \
aws/ClientConfig.cpp \
CurrentUser.cpp \
aws/AuthRequest.cpp \
UserData.cpp \
main.cpp \
core/ControllerConfig.cpp \
core/ControllerAPI.cpp \
aws/CognitoSyncCommand.cpp \
aws/ControllerThing.cpp \
core/ControllerHTTPClient.cpp \
aws/PersistentCredentialsProviderSQL.cpp \
core/CredentialsDAO.cpp \
aws/AwsApi.cpp \
aws/CognitoCredentialsProvider.cpp \
aws/IdToken.cpp \
aws/Jwt.cpp \
core/LocalCache.cpp \
core/LocalCache.tpp \
CognitoSyncTests.cpp \
core/CognitoSyncDAO.cpp \
core/Location.cpp \
core/Controller.cpp \
core/ShadeGroup.cpp \
core/ShadeGroupModel.cpp \
core/DatabaseManager.cpp \
core/LocationModel.cpp \
core/Positioned.cpp \
core/Schedule.cpp \
core/Shade.cpp \
NetworkMonitor.cpp \
UserData.tpp \
core/ZoneModel.cpp \
core/ControllerConnectionsManager.cpp \
core/LocationsModel.cpp \
core/TimeZoneModel.cpp \
core/ControllerSSDP.cpp \
core/ControllerSchedule.cpp \
core/LicenseDAO.cpp \
AlertBox.cpp \
ReplyTimeout.cpp
# own codebase
HEADERS += \
EspTouchSetup.h \
core/WanAPI.h \
core/User.h \
core/UserDAO.h \
aws/CognitoSyncAPI.h \
aws/ClientConfig.h \
CurrentUser.h \
aws/AuthRequest.h \
UserData.h \
core/Syncable.h \
core/ControllerConfig.h \
NAM.h \
core/ControllerHTTPClient.h \
core/ControllerAPI.h \
core/timeaux.h \
aws/CognitoSyncCommand.h \
aws/ControllerThing.h \
aws/PersistentCredentialsProviderSQL.h \
core/CredentialsDAO.h \
aws/AwsApi.h \
aws/CognitoCredentialsProvider.h \
aws/IdToken.h \
aws/Jwt.h \
core/LocalCache.h \
CognitoSyncTests.h \
core/CognitoSyncDAO.h \
core/Jsonized.h \
core/Location.h \
core/Controller.h \
core/ShadeGroup.h \
core/ShadeGroupModel.h \
core/DatabaseManager.h \
core/LocationModel.h \
core/Positioned.h \
core/Schedule.h \
core/Shade.h \
NetworkMonitor.h \
core/ZoneModel.h \
core/ControllerConnectionsManager.h \
core/LocationsModel.h \
core/TimeZoneModel.h \
core/ControllerSSDP.h \
core/ControllerSchedule.h \
core/LicenseDAO.h \
AlertBox.h \
ReplyTimeout.h
# Boost lib for multiprecision ints
INCLUDEPATH += $$DEV_LIBS_PATH/boost-cpp
# The following define makes your compiler emit warnings if you use
# any feature of Qt which as been marked deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
# You can also make your code fail to compile if you use deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
RESOURCES += qml.qrc
# Additional import path used to resolve QML modules in Qt Creator's code model
#QML_IMPORT_PATH = styles
# Additional import path used to resolve QML modules just for Qt Quick Designer
QML_DESIGNER_IMPORT_PATH =
# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target