From f14878b05ee885f1747feab256011b4da72ae778 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Fri, 23 Aug 2019 15:36:18 +0800 Subject: Started to use cURL --- kelakon.pro | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index fb0d403..e0e0d89 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -1,6 +1,15 @@ QT += quickcontrols2 +HEADERS += \ + rtclient.h \ + networkworker.hxx + SOURCES += \ - main.cxx + rtclient.c \ + networkworker.cxx \ + main.cxx RESOURCES += kelakon.qrc + +LIBS += \ + -lcurl -- cgit v1.2.3 From 356fa9d29a53aa0dba28016b932f8042f8d3970a Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Fri, 23 Aug 2019 17:47:20 +0800 Subject: Started using cURL on Android There's a quirk since Clang. It seems the Android search path setting messes up the standard library compilation. So for now, what you do is remove the android-* setting to make Qt compile, even though it would say it cannot find libcurl, and then put the setting back again to link with libcurl. --- kelakon.pro | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index e0e0d89..8f1240f 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -11,5 +11,12 @@ SOURCES += \ RESOURCES += kelakon.qrc +android-* { + INCLUDEPATH += $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/include + LIBS += -L$$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib + ANDROID_EXTRA_LIBS += \ + $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libcurl.so +} + LIBS += \ -lcurl -- cgit v1.2.3 From 06eb4d8c7992def13ad5ca70baba3acda2f35a06 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sat, 24 Aug 2019 14:56:01 +0800 Subject: Simplified qmake syntax --- kelakon.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index 8f1240f..ab6c01c 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -11,7 +11,7 @@ SOURCES += \ RESOURCES += kelakon.qrc -android-* { +android { INCLUDEPATH += $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/include LIBS += -L$$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib ANDROID_EXTRA_LIBS += \ -- cgit v1.2.3 From 393bb95e97f8e53c430fb95926128ad2b683af63 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sat, 24 Aug 2019 18:20:29 +0800 Subject: On Android, include OpenSSL libs --- kelakon.pro | 2 ++ 1 file changed, 2 insertions(+) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index ab6c01c..3ae1497 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -15,6 +15,8 @@ android { INCLUDEPATH += $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/include LIBS += -L$$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib ANDROID_EXTRA_LIBS += \ + $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libcrypto.so \ + $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libssl.so \ $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libcurl.so } -- cgit v1.2.3 From c4d1459599fc312ca4bdd5300d3f00ba24bd2af3 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sat, 24 Aug 2019 21:31:42 +0800 Subject: Made specific Android settings apply on Qt Creator By using the "contains" function, and also just hardcode the toolchain path. --- kelakon.pro | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index 3ae1497..35bc0a9 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -11,13 +11,13 @@ SOURCES += \ RESOURCES += kelakon.qrc -android { - INCLUDEPATH += $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/include - LIBS += -L$$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib +contains(ANDROID_TARGET_ARCH,armeabi-v7a) { + INCLUDEPATH += /usr/local/arm-linux-androideabi/sysroot/usr/include + LIBS += -L/usr/local/arm-linux-androideabi/sysroot/usr/lib ANDROID_EXTRA_LIBS += \ - $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libcrypto.so \ - $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libssl.so \ - $$(ANDROID_STANDALONE_TOOLCHAIN)/usr/lib/libcurl.so + /usr/local/arm-linux-androideabi/sysroot/usr/lib/libcrypto.so \ + /usr/local/arm-linux-androideabi/sysroot/usr/lib/libssl.so \ + /usr/local/arm-linux-androideabi/sysroot/usr/lib/libcurl.so } LIBS += \ -- cgit v1.2.3 From c3abee20a084b3669d648077086105672cee6564 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sun, 25 Aug 2019 09:59:11 +0800 Subject: Managed to differentiate C from C++ compilation --- kelakon.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index 35bc0a9..0892052 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -12,7 +12,7 @@ SOURCES += \ RESOURCES += kelakon.qrc contains(ANDROID_TARGET_ARCH,armeabi-v7a) { - INCLUDEPATH += /usr/local/arm-linux-androideabi/sysroot/usr/include + QMAKE_CFLAGS += -I/usr/local/arm-linux-androideabi/sysroot/usr/include LIBS += -L/usr/local/arm-linux-androideabi/sysroot/usr/lib ANDROID_EXTRA_LIBS += \ /usr/local/arm-linux-androideabi/sysroot/usr/lib/libcrypto.so \ -- cgit v1.2.3 From 6be07cabf768c5bdc11c14a750281e1c7b8b62ec Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sun, 25 Aug 2019 10:51:06 +0800 Subject: ARM64 Android settings for cURL --- kelakon.pro | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index 0892052..61a0b3a 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -11,6 +11,15 @@ SOURCES += \ RESOURCES += kelakon.qrc +contains(ANDROID_TARGET_ARCH,arm64-v8a) { + QMAKE_CFLAGS += -I/usr/local/aarch64-linux-android/sysroot/usr/include + LIBS += -L/usr/local/aarch64-linux-android/sysroot/usr/lib + ANDROID_EXTRA_LIBS += \ + /usr/local/aarch64-linux-android/sysroot/usr/lib/libcrypto.so \ + /usr/local/aarch64-linux-android/sysroot/usr/lib/libssl.so \ + /usr/local/aarch64-linux-android/sysroot/usr/lib/libcurl.so +} + contains(ANDROID_TARGET_ARCH,armeabi-v7a) { QMAKE_CFLAGS += -I/usr/local/arm-linux-androideabi/sysroot/usr/include LIBS += -L/usr/local/arm-linux-androideabi/sysroot/usr/lib -- cgit v1.2.3 From b9bc9d9e391e6567a12182b9f6de355be1f5be1c Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sun, 25 Aug 2019 14:10:59 +0800 Subject: Reordered --- kelakon.pro | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index 61a0b3a..c02a1b7 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -11,6 +11,9 @@ SOURCES += \ RESOURCES += kelakon.qrc +LIBS += \ + -lcurl + contains(ANDROID_TARGET_ARCH,arm64-v8a) { QMAKE_CFLAGS += -I/usr/local/aarch64-linux-android/sysroot/usr/include LIBS += -L/usr/local/aarch64-linux-android/sysroot/usr/lib @@ -28,6 +31,3 @@ contains(ANDROID_TARGET_ARCH,armeabi-v7a) { /usr/local/arm-linux-androideabi/sysroot/usr/lib/libssl.so \ /usr/local/arm-linux-androideabi/sysroot/usr/lib/libcurl.so } - -LIBS += \ - -lcurl -- cgit v1.2.3 From c47e2b615be10861262752742d7aa5b306195d10 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Sun, 25 Aug 2019 17:48:25 +0800 Subject: Capitalised Android app label --- kelakon.pro | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index c02a1b7..c91ba3e 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -31,3 +31,7 @@ contains(ANDROID_TARGET_ARCH,armeabi-v7a) { /usr/local/arm-linux-androideabi/sysroot/usr/lib/libssl.so \ /usr/local/arm-linux-androideabi/sysroot/usr/lib/libcurl.so } + +android { + ANDROID_PACKAGE_SOURCE_DIR = $$PWD/android +} -- cgit v1.2.3 From afdab77790e8db165b43e9ab34cb26313b067856 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Tue, 27 Aug 2019 08:28:24 +0800 Subject: Added rtclient module --- kelakon.pro | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index c91ba3e..db85290 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -1,17 +1,18 @@ QT += quickcontrols2 HEADERS += \ - rtclient.h \ networkworker.hxx SOURCES += \ - rtclient.c \ networkworker.cxx \ main.cxx RESOURCES += kelakon.qrc +INCLUDEPATH += $$PWD/rtclient + LIBS += \ + $$PWD/rtclient/librtclient.a \ -lcurl contains(ANDROID_TARGET_ARCH,arm64-v8a) { -- cgit v1.2.3 From 40db7eb6ec8115342410b45a94f842d06bf63d91 Mon Sep 17 00:00:00 2001 From: Erik Prabowo Kamal Date: Tue, 27 Aug 2019 09:41:35 +0800 Subject: Added the user class to the qmake project --- kelakon.pro | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'kelakon.pro') diff --git a/kelakon.pro b/kelakon.pro index db85290..12dc52d 100644 --- a/kelakon.pro +++ b/kelakon.pro @@ -1,10 +1,12 @@ QT += quickcontrols2 HEADERS += \ - networkworker.hxx + networkworker.hxx \ + user.hxx SOURCES += \ networkworker.cxx \ + user.cxx \ main.cxx RESOURCES += kelakon.qrc -- cgit v1.2.3