aboutsummaryrefslogtreecommitdiff
path: root/toolchain
AgeCommit message (Collapse)Author
2021-04-07Document the advanced APK packaging optionsVolker Krause
2021-04-07Add a way to pass additional arguments to androiddeployqtVolker Krause
We need this to pass the --release option for binary factory release builds. An alternative approach would be to set that here automatically depending on the CMake build type. Since that however ends up producing unsigned and thus not immediately usable APKs (or would need a whole set of extra arguments for proper signing) I'm not sure whether that's most convenient for local use.
2021-02-01Remove fastlane metadata generation from a given APKVolker Krause
This is no longer needed now that the metadata happens as part of the build process rather than afterwards on the signing system. This allows us to simplify the code here a bit.
2021-01-30Support the new Appstream file extension as wellVolker Krause
2021-01-20Consider Appstream donation URLs for creating F-Droid metadataVolker Krause
Those occur for example in Marble.
2020-12-28Consider local fastlane image assetsVolker Krause
This adds support for image assets not represented in the appstream data, such as the banner image for the F-Droid app, and it allows to override appstream screenshots by local ones. The latter is e.g. used by KTrip which provides Android-specific screenshots that way.
2020-12-24Preserve the rich-text subset supported by F-DroidVolker Krause
This should improve the alignment issues currently seen in bullet point lists that we use frequently in the description text.
2020-12-20bump required cmake version for Android.cmakeJohnny Jazeix
BUG: 424392
2020-12-19Automatically detect plugin lib deps on AndroidGabriel Souza Franco
This makes use of the CMake 3.19 DEFER command to list all MODULE targets after processing the toplevel CMakeLists. This allows us to collect required dependencies of all plugins without changes to the application. For example, this will fix Okular not including Poppler because it is only linked from the plugin, thus not being able to actually read PDFs.
2020-12-13Fix errors in python code, found by pylama in a strict CIDavid Faure
2020-12-10Check if file exists before removing the fastlane archiveVolker Krause
Locally unlink() seems to work just fine on non-existent files, but on binary factory that seems to be different for some reason.
2020-12-10Clean image folder and archive file before downloading/generating thoseVolker Krause
This matters when reusing output folders (as binary factory does for example), as we then retain outdated screenshots and just keep adding files to an already existing fastlane archive.
2020-12-08Retain screenshot order from the appstream fileVolker Krause
Also, check for the HTTP status code, so we don't end up with 404 error messages in image files here.
2020-12-05Don't fail if we haven't found any categoriesVolker Krause
This should fix the Okular build failure on binary factory.
2020-12-04Fix category extraction from desktop filesVolker Krause
This broke the builds for apps not having categories in their appstream files.
2020-12-01Add fastlane metadata generation for Android buildsVolker Krause
This is currently done on the signing machines as part of the F-Droid nightly pipeline, but should rather happen as part of the build process in the future. Compared to the binary factory script this has a few extensions already: - Besides recovering information from APKs we can now consume appdata files directly, or scan the entire source dir. - Screenshots from appdata files are downloaded. - The 'x-test' language is ignored. - Donation and translation information are added. - Add links to the source code repository, if we can determine that. The result is put into a single archive per APK, so we can easily transfer that to the signing machine via Jenkins alongside the APK.
2020-11-01Make androiddeployqt find libraries and QML plugins without installationv5.76.0-rc1v5.76.0Volker Krause
This matters for libraries in the same repository as the application that also have an AAR that needs to be integrated, as well as QML plugins. For this to work we need to consider the build directory as a search prefix, and produce the exact directory layout there that androiddeployqt expects. For libraries this is then almost transparent for the application build system, the only thing that needs to be taken care of manually is putting the corresponding -android-dependencies.xml file into the right place in the build dir as well. A macro wrapping that might be an option to centralize that logic here as well in the future. For QML plugins this is transparent if you have them set up to work without installation already anyway, otherwise that setup has to be done for this to work. Example: https://invent.kde.org/pim/itinerary/-/merge_requests/28 https://invent.kde.org/frameworks/knotifications/-/merge_requests/12 would presumably also need this (not tested yet).
2020-10-21Include option to use LLVM for users with Qt < 5.14Sharaf Zaman
When NDK r20+ is used along with Qt5.12, APK generation fails because of the layout change in newer NDK. This patch introduces a new variable USE_LLVM, when this is set for older Qt versions, androiddeployqt uses LLVM's tools.
2020-09-20Fix configuring with pthread on Android 32 bitGabriel Souza Franco
2020-09-16Fix find_library on Android with NDK < 22Gabriel Souza Franco
2020-09-16Explicitly sort Android version listsGabriel Souza Franco
Also document --android-platform parameter
2020-09-16Store Android {min,target,compile}Sdk in variablesGabriel Souza Franco
Also pass along these values to androiddeployqt
2020-06-22Deal with Qt's CMake code modifying CMAKE_SHARED_LIBRARY_SUFFIXVolker Krause
Qt adds the Android ABI to the suffix there unconditionally, without also adjusting CMAKE_FIND_LIBRARY_SUFFIXES accordingly, breaking find_library() for things built that way. Unfortunately we can't just set this in our toolchain file, as CMAKE_FIND_LIBRARY_SUFFIXES is overwritten by CMake after evaluating the toolchain file. So we need to use the variable_watch hack for this here, thanks to Aleix for the idea. With this, find_library() works for both suffixed and un-suffixed libraries again, such as Poppler built with or without Qt support.
2020-06-14extra-cmake-modules: Convert to SPDX license statementsAndreas Cord-Landwehr
2020-05-19[android] Use newer Qt version in examplev5.71.0-rc3v5.71.0-rc2v5.71.0-rc1v5.71.0Nicolas Fella
2020-05-11[android] Allow specifying APK install locationNicolas Fella
Summary: This allows `make create-apk` to directly write the APK to /output instead of the cp-with-prefix step in /opt/helpers/create-apk. It's also useful for manual development builds where one would need to copy it to some output location manually or for CI setups that expect the output in a certain location. If ANDROID_APK_INSTALL_DIR is not set the current behaviour is kept. Reviewers: #frameworks, #android, apol, vkrause Reviewed By: #android, apol Subscribers: kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D29631
2020-04-29android: include the architecture on the apk namev5.70.0-rc1v5.70.0Aleix Pol
Summary: Makes them easier to use afterwards. Test Plan: Tested locally Reviewers: #android, #frameworks, nicolasfella Reviewed By: nicolasfella Subscribers: vkrause, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D29079
2020-03-03Support NDK r20 and Qt 5.14Volker Krause
Summary: This changes from using the toolchain file provided by CMake to using the one provided by the NDK, as even recent CMake can't build successfully with r20. However this is a rather invasive change, the interface and variable names differ. The Qt 5.14 changes are less risky, as most of this is parallel to the support for older versions. Test Plan: Local builds with 5.14/r20, 5.14/r18 work, the Docker SDK isn't tested yet, and there's some remaining issues with 5.13 and older NDKs I don't fully understand yet. The resulting apks with 5.14 install, and work for QQC2 content, but fail to start Kirigami apps. Reviewers: apol Reviewed By: apol Subscribers: flherne, apol, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Maniphest Tasks: T12520 Differential Revision: https://phabricator.kde.org/D26749
2020-01-04[android] Fix apk install targetv5.66.0-rc1v5.66.0Nicolas Fella
Summary: The APK output path changed at some point Test Plan: can do make install-apk-appname again Reviewers: apol Reviewed By: apol Subscribers: kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D26402
2019-07-29android: Allow overriding ANDROID_ARCH and ANDROID_ARCH_ABI as envvarsv5.61.0-rc1v5.61.0Aleix Pol
2019-07-08Fix type names casingAleix Pol
Summary: It's supposed to be uppercase, cmake was warning about it. Test Plan: Now it builds as well, but cmake doesn't complain. Reviewers: #frameworks, #android, vkrause Reviewed By: #android, vkrause Subscribers: kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D22317
2019-04-17Bug fix: find c++ stl using regexv5.58.0-rc1v5.58.0Sharaf Zaman
Summary: Find C++ shared lib path using regex. This change makes finding path independent of the order in which it was added by cmake. Reviewers: apol Reviewed By: apol Subscribers: kde-buildsystem, kde-frameworks-devel Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D20558
2019-04-15Detect duplicate ANDROID_EXTRA_LIBS and minor bug fixSharaf Zaman
Summary: Don't include same dependency twice, one which was found from `readelf` in `specifydependencies.cmake` and other in `ANDROID_EXTRA_LIBS`. Bug fix: find stl was dependent on the order in which libc++ was added, now it is independent. Test Plan: * add the same dependency in ANDROID_EXTRA_LIBS Reviewers: apol, vkrause Reviewed By: apol Subscribers: kde-buildsystem, kde-frameworks-devel Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D20509
2019-02-26Android: Reflect on using clang nowv5.56.0-rc1v5.56.0Aleix Pol
2019-02-15Update Android toolchain files to realityVolker Krause
Summary: - NDK r18 does not ship GCC anymore, it's only clang now - same for STL, there's only libc++ there - API level 14 is not supported either anymore, the minimum supported by the current NDK is 16 - The minimum supported API level by KF5 right now is 21 though, so use that as the default Reviewers: apol Reviewed By: apol Subscribers: apol, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D19016
2019-01-09Use more https in linksFriedrich W. H. Kossebau
2018-11-19Android: improve clang supportAleix Pol
Summary: Infer the toolchain we are using through cmake's detection of ranlib instead of asking the user to fill it. It's only used in androiddeployqt and cmake expects it to be version "clang" for clang builds while androiddeployqt expects it to be "4.9". Reviewers: #build_system, #android, vkrause Reviewed By: #android, vkrause Subscribers: kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D16930
2018-09-29Android: Allow passing a relative path as the apk dirAleix Pol
Summary: This way the project can generate automatically its own manifest file. GCompris is using it to set the version. Test Plan: Built GCompris without a warning saying the apkdir isn't found Reviewers: #frameworks, #gcompris, jjazeix Reviewed By: #gcompris, jjazeix Subscribers: jjazeix, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D15643
2018-09-27Android: Properly offer a fallback to applications that don't have a manifestAleix Pol
The variable name was wrong, not much to see here.
2018-09-24Fix Android builds using cmake 3.12.1Aleix Pol
Summary: Only extract the the stl shared object without the rest of libraries. Test Plan: Built gcompris Reviewers: #frameworks, vkrause Reviewed By: vkrause Subscribers: kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D15685
2018-08-26Change documentation to reflect the real toolchain CMake nameBenjamin Port
Reviewers: apol, alexeymin Reviewed By: alexeymin Subscribers: alexeymin, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D15084
2018-08-02Android: Don't hardcode a random version of the Android SDKAleix Pol
Summary: Just default to whichever is installed Test Plan: Built kalgebra Reviewers: #frameworks, vkrause Reviewed By: vkrause Subscribers: alexeymin, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D14544
2018-07-18Fix variable definition checkAleix Pol
Summary: We'd check if the variable's value is defined, which is wrong and prevented us from properly initialising using these deprecated variables. It would also ignore the value we're passing to the actually right variable when using it. Test Plan: Built kstars which needs -DCMAKE_ANDROID_API=24 Reviewers: #frameworks, vkrause Reviewed By: vkrause Subscribers: kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D14187
2018-07-04Android: Make it possible to override a target's APK directoryv5.48.0-rc1v5.48.0Aleix Pol
Summary: Some projects such as marble do some operations with the APK directory before building. This allows us the project to copy the apk directory over to the build directory and do whatever it pleases. Test Plan: Built Marble Reviewers: #frameworks, vkrause Reviewed By: vkrause Subscribers: vkrause, kde-frameworks-devel, kde-buildsystem Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D13403
2018-05-31Android toolchain: allow to specify extra libs manuallyv5.47.0-rc1v5.47.0Alexey Minnekhanov
Summary: Add new variable ANDROID_EXTRA_LIBS, which can contain list of full paths to libs to include in resulting APK file. This can be used to include plugins that are not directly liked to executable, for example OpenSSL libs for QtNetwork SSL/HTTPS support. Test Plan: Build project with -DANDROID_EXTRA_LIBS="/path/to/lib.so;/path/to/other_lib.so". Build without it. In both cases verify APK contents. Reviewers: apol Reviewed By: apol Subscribers: kde-buildsystem, kde-frameworks-devel Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D13198
2018-05-15Android: fix typoAleix Pol
2018-05-14Android: Don't define qml-import-paths if it's emptyAleix Pol
Otherwise androiddeployqt fails like it's failing now for kirigami https://binary-factory.kde.org/view/Android/job/KirigamiGallery_android/48/console
2018-04-17Android: fix dumb mistakesAleix Pol
Use the variable we just created to look up Qt5. Remove debug warning.
2018-04-17Android: Make sure variable is defined before using itAleix Pol
2018-04-13Make it possible to build several apk out of a projectAleix Pol
Summary: Refactor the apk-generating code into a separate function, in views of eventually even make it a module. It also changes so that if no APK dir is specified, a generic dummy one is used. Useful for proofs of concept. Test Plan: Built kate, got kate and kwrite apks Reviewers: #frameworks, #build_system, vkrause Reviewed By: vkrause Subscribers: vkrause Tags: #frameworks, #build_system Differential Revision: https://phabricator.kde.org/D12150