add architecture detection

a bit unrelated to feature branch, but I just wanted to build it. ;)
This commit is contained in:
John Gibbon 2020-10-01 13:22:12 +02:00
parent 3149cb38cb
commit 2b228704ef
2 changed files with 6 additions and 3 deletions

View file

@ -34,7 +34,7 @@ const char TDLIB_API_HASH[] = "1234567890abcdef1234567890abcdef";
You get the Telegram API ID and hash as soon as you've registered your own application on [https://my.telegram.org](https://my.telegram.org).
Moreover, you need to have a compiled version of [TDLib](https://github.com/tdlib/td) in the sub-directory `tdlib`. This sub-directory must contain another sub-directory that fits to the target device architecture (e.g. armv7hl, i486). Within this directory, there needs to be a folder called `lib` that contains at least `libtdjson.so`. For armv7hl the relative path would consequently be `tdlib/armv7hl/lib`. Before compiling the project, be sure to set the target architecture in the project file `harbour-fernschreiber.pro` correctly using the variable `TARGET_ARCHITECTURE`. This can most certainly be automated. Pull requests welcome! ;)
Moreover, you need to have a compiled version of [TDLib](https://github.com/tdlib/td) in the sub-directory `tdlib`. This sub-directory must contain another sub-directory that fits to the target device architecture (e.g. armv7hl, i486). Within this directory, there needs to be a folder called `lib` that contains at least `libtdjson.so`. For armv7hl the relative path would consequently be `tdlib/armv7hl/lib`.
## Credits
This project uses

View file

@ -57,8 +57,11 @@ TRANSLATIONS += translations/harbour-fernschreiber-de.ts \
translations/harbour-fernschreiber-pl.ts \
translations/harbour-fernschreiber-zh_CN.ts
# Use armv7hl for most devices and i486 for emulator and Jolla Tablet. Can most certainly be automated... ;)
TARGET_ARCHITECTURE = i486
contains(QT_ARCH, arm) {
TARGET_ARCHITECTURE = armv7hl
} else {
TARGET_ARCHITECTURE = i486
}
INCLUDEPATH += $$PWD/tdlib/include
DEPENDPATH += $$PWD/tdlib/include