Age | Commit message (Collapse) | Author |
|
Since KDEInstallDirs6 explicitly sets KDE_INSTALL_DIRS_NO_DEPRECATED to
false.
|
|
Fixes a number of unit tests that rely on Qt in some form when using Qt6.
|
|
With this we are no longer skipping a bunch of tests when using Qt6.
This likely still misses forwarding the Qt option to the CMake calls of
the actual tests, but that's for a subsequent change.
|
|
To avoid ambiguity with ECMQmlModule.cmake.
To preserve backward compatibility, we keep a version around of
ECMQMLModules.cmake that warns a user of it being moved and includes the
new file.
|
|
This contains some helper functions to make it easier to create QML
modules through CMake. It takes care of several things that currently
need to be done manually.
It adds four tests for the four primary ways that it can be used,
either as shared/static library and with or without C++ plugin.
|
|
|
|
Ensures that the files
* are re-created by build rule when accidentally deleted in the build dir
* are not getting new timestamps on every cmake run, even when content
has not changed
|
|
When creating a library or executable, several source files are combined
into a binary artifact that has an outbound license of its own. This test
generator allows to check if the combined source files are compatible
with the desired outbound license.
Requirements for using these tests:
- input source files must contain the SPDX-License-Information tag
- python3 must be available
- the "reuse spdx" tool must be available
|
|
Summary:
It serves as a replacement for `kdbusaddons_generate_dbus_service_file`.
An application can be a DBus-activated service just fine without using KDBusAddons.
Moreover, this new module uses named arguments for future-proofing, and adds support for specifying a `SystemdService`.
It also cleans up the confusion on what the "path" is about: Rather than requiring to specify executable and path separately, we just extract the executable file name on Windows, if necessary.
Usage:
```
ecm_generate_dbus_service_file(NAME org.kde.kded5
EXECUTABLE ${KDE_INSTALL_FULL_BINDIR}/kded5
SYSTEMD_SERVICE plasma-kded)
```
Test Plan:
* Was able to generate a kded service file
* Was able to generate a kded service file with `SystemdUnit`
* Verified that it moaned when executable wasn't an absolute path
* Untested on Windwos
Reviewers: #frameworks, davidedmundson, kossebau, kfunk, habacker
Subscribers: kde-frameworks-devel, kde-buildsystem
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D29051
|
|
Summary:
This, as the name suggests, configures a file and installs it.
It's not very complicated but it's a repeated pattern in plasma that
gets quite messy dealing with temporary files.
Test Plan: Used in a project
Reviewers: #build_system
Subscribers: apol, kossebau, pino, kde-frameworks-devel, kde-buildsystem
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D28355
|
|
|
|
Summary:
Not passing CMAKE_INSTALL_PREFIX is a weird thing to do. The test shows
"Installing in ." and some values like KDE_INSTALL_FULL_EXECROOTDIR
become "/" which is considered relative on Windows.
The test that passes /usr to CMAKE_INSTALL_PREFIX actually passes on
Windows. Pass /tmp to the other test, remove the test without prefix.
Test Plan: Passes on Linux, not tested on Windows, CI will do that
Reviewers: kossebau, apol, cgiboudeaux
Reviewed By: apol
Subscribers: kde-frameworks-devel, kde-buildsystem
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D28409
|
|
Summary:
Generates additional macros in the export header which can be used for
fine-grained disabling of warnings & visibility as well as excluding from
the build.
Reviewers: #frameworks, #build_system
Subscribers: chehrlic, dfaure, cgiboudeaux, kde-frameworks-devel, kde-buildsystem
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D23789
|
|
|
|
BUG: 389519
|
|
Summary:
We were using a link.txt file that cmake used to generate, on newer cmake
versions it doesn't anymore.
Instead use readelf, much like androiddeployqt does, to extract the
depenencies.
Catch: It relies on having all the binaries being at the same subdirectory,
which is the default in ECM since not long ago.
Test Plan: Build kirigamigallery with it
Reviewers: #frameworks, #build_system, aacid
Reviewed By: aacid
Subscribers: mart
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D8173
|
|
Summary:
Allows to check if a module is available on the system and sets it as a
runtime dependency.
This is useful for projects so that they can specify their qml dependencies
easily and packagers and developers get to see what's missing by looking
at the cmake output.
Reviewers: #build_system, #frameworks, sitter
Reviewed By: sitter
Subscribers: dfaure, aacid
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D7094
|
|
Summary:
Enables generation of QCH files during a normal build,
for documenting the public API of a library.
These macros are especially done with release builds in mind,
so distributed packages (like from Linux distributions) can
include QCH files matching the version of the library and will be
also automatically updated on new versions of the libary.
Next to that these macros also support linking between different
QCH files, so a subclass from another library for which there also
is a QCH file installed will be linked to the entry in that other
QCH file.
This inter-QCH linking is especially useful for libraries extending Qt,
where many of the used types are from Qt libraries. The macros
come with the needed information for Qt libraries prepared, so the
used Qt libraries just need to be listed in the LINK_QCHS argument
by target names, like Qt5Core_QCH or Qt5Widgets_QCH.
This should be a nice supplement to online services like api.kde.org,
like Qt's own QCH files are to doc.qt.io,
While QCH files from an abstract POV could be seen similar to code
libraries, being components with links to lookup symbols/entries in
other QCH files, so the rules and code should be done with similar
concepts, currently CMake's target system seems bound to executable
code creation. So things like "file(EXPORT ...)" could sadly not be
reused, as custom targets are not supported with that.
Thus a custom macro had to be created for now. Also could I not find
a way to use namespaces like KF5::, for more consistent target naming.
The patch also adds two variables to KDEInstallDirs.cmake for
controlling where the QCH (and respective doxygen tag files) are
installed. The QTQCHDIR variant allows to install QCH files for
Qt-extending libraries into the same folder where Qt's own QCH
files are, so Qt Assistant & other QCH viewer pick up them automatically
to add them to the default help file collection.
The QCHDIR variant would provide a neutral, but central installation
location. Neutral, as it never "pollutes" the Qt system dirs with files
possibly unrelated to Qt-based development (e.g. when simply using qthelp
tools for documentation), and central, to help with finding available QCH
files for manually adding/loading them into a viewer, given there is no
official way currently to register the availability of QCH files on
installing.
Open questions:
a) target system for exporting/importing done in a sane way?
Better name pattern for the QCH targets than xxx_QCH
(see the targets created for Qt, like Qt5Core_QCH)?
b) sharing metadata with kapidox
Initially I placed these macros into the kapidox module, as this seems the
logic place. And would match what kdoctools does for user manuals.
Just, that would create a build dependency on kapidox which complicates usage
a little. Having these macros in ECM delivers them with no extra effort
needed.
The data in metainfo.yaml is partially duplicated with the data feed into
the macros. How to deduplicate that is still open. Especially with the need
to not depend on external data sources like identify.kde.org.
Issues:
* doxygen versions before 1.8.13 are broken and miss to include some files
with generated QCH (https://bugzilla.gnome.org/show_bug.cgi?id=773693)
* Qt Assistant often only built with QTextBrowser, while doxygen uses lots
of HTML5 (incl. hardcoded JavaScript)
(https://bugzilla.gnome.org/show_bug.cgi?id=773715),
needs e.g. distributions to use QtWebKit to work, upcoming Qt versions
might soon also have QtWebEngine based help viewer
(https://codereview.qt-project.org/#/c/111559/)
* inter-QCH links do not work in KDevelop currently
(see https://bugs.kde.org/show_bug.cgi?id=372747) if installed as
separate QCH files
More details/background info at
https://frinring.wordpress.com/2016/09/27/adding-api-dox-generation-to-the-build-by-cmake-macros/
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D2854
|
|
Set KDE_INSTALL_USE_QT_SYS_PATHS explicitely to FALSE, to avoid
it defaulting to TRUE if Qt is also installed to the /usr prefix
|
|
Summary: It turns out it's more complex than it looks, it's always better to have tests.
Reviewers: sitter, aacid
Reviewed By: sitter
Subscribers: #frameworks, #build_system
Tags: #frameworks, #build_system
Differential Revision: https://phabricator.kde.org/D5352
|
|
|
|
|
|
It should be optional.
|
|
This can be used by KF5 libraries to generate python 2 and 3 bindings.
|
|
REVIEW: 128780
|
|
Needed for many unit tests to add them to APK files.
REVIEW: 128175
|
|
REVIEW: 126711
|
|
templates are very useful as teaching tool in order to make
a minimal application that uses a certain framework.
templates in the KAppTemplate repository will always get forgotten
(plus kapptemplate is not really necessary as they work in kdevelop as well)
An ideal situation would be frameworks having templates in their own repos
with templates of barebone apps using the main framework features.
In order to do that, the cmake stuff needed in order to correctly install
a template needs to be ported to a place avaiable to all frameworks
REVIEW:126185
|
|
It should now be easier to read, and more featureful. Among other
tweaks, we now print a summary of dependencies and build options, and
the documentation is generated with more sensible breadcrumbs and
builds properly with Sphinx 1.3.
REVIEW: 126075
|
|
This is based on commit 6745bd7e4796560959bb67e33b7c7f86f96a5a94 (and
the subsequent fix-up commits).
|
|
This broke the build for projects which used ecm_create_qm_loader in
unusual ways. A better approach is coming, but won't be in e-c-m 5.16.
This reverts commit 009c480413910e8c1a18f4d1420f4a517ea606e6.
CCBUG: 346188
CCMAIL: release-team@kde.org
CCMAIL: kde-buildsystem@kde.org
|
|
BUG: 346188
REVIEW: 123726
|
|
This makes life a bit easier for developers who use the categorised
logging in Qt5 in the common case - rather than creating two new files,
and remembering to put in the #ifdef for the default verbosity settings
in Qt 5.4, they can just add a couple of lines to their CMakeLists.txt.
REVIEW: 124595
|
|
REVIEW: 123722
|
|
REVIEW: 121646
|
|
REVIEW: 121646
|
|
Creating variables whose names start with CMAKE_ is a bad idea for
modules distributed outside CMake itself. Since the module is called
KDEInstallDirs, having a KDE_INSTALL_ prefix for the variables is clear
and intuitive.
Both CMAKE_INSTALL_* variables and the older KDELibs4-compatible
variables are provided, unless KDE_INSTALL_DIRS_NO_DEPRECATED is set to
TRUE before the module is included. Even then, the CMAKE_INSTALL_*
variables provided by the GNUInstallDirs module will still be set and
understood (for compatibility with that module), unless
KDE_INSTALL_DIRS_NO_CMAKE_VARIABLES is set to TRUE.
REVIEW: 121646
|
|
When installing to /usr, we should use /etc for configuration. Using
/usr/etc does not make sense.
REVIEW: 120246
|
|
KDE modules cannot assume the normal ECM modules are in the CMake module
path, and CMAKE_INSTALL_IMPORTS_INSTALL_DIR / QTQUICKIMPORTSDIR was not
set correctly. Also, ECMQueryQmake.cmake used a deprecated CMake command
(exec_program).
|
|
A new module has been introduced to generate pkgconfig files from
cmake projects.
REVIEW: 119798
|
|
Setting the language for ECM's project() call to C had unanticipated
side-effects - notably that the installed version file required the
architecture to match the one used at build time.
Instead, we make the tests a sub-project, setting up C as the language
there (since most of the tests do use C, albeit slightly indirectly).
REVIEW: 118498
|
|
Move the detailed testing of KDEInstallDirs from ExecuteKDEModules to a
subdir of KDEInstallDirsTest. This is where you would expect to find it,
and it also makes sure that other KDE modules are not affecting the
test.
This also makes the KDEInstallDirs/not_cache_variable regression test
work the same way as the other tests, doing a double-configure and
build. While not stricly necessary to catch the original issue, it does
ensure that the problem does not appear when reconfiguring either.
|
|
REVIEW: 118127
|
|
ecm_create_qm_from_po_files() was actually not very useful in practice.
So that is deprecated, to be removed before ECM 1.0.
Instead, the ECMPoQmTools provides several useful functions:
ecm_create_qm_loader() (which already existed in
ECMCreateQmFromPoFiles), ecm_process_po_files_as_qm() (which has the
same signature as gettext_process_po_files() from the FindGettext
module) and ecm_install_po_files_as_qm(), which is a convenience
function mostly for the benefit of KDE Frameworks (although potentially
useful for whatever other projects have the unusual requirement of a
Gettext translation workflow but no Gettext usage in the code).
NB: some clean-up to the documentation was done by Alex Merry
<alex.merry@kde.org> as part of this commit.
REVIEW: 117823
|
|
Find module tests now use find_package(), and there is a version for
when CMAKE_MODULE_PATH is set and a version for when
ecm_use_find_modules() is used.
KDE modules are also now tested.
REVIEW 117658
|
|
When CMake policy CMP0048 (CMake 3.0) is set to NEW, the project()
command is meant to manage the project's version variables. We therefore
do not set the PROJECT_VERSION variables in this case.
To make sure projects do not have to specify their version in multiple
places, this also allows the keyword "PROJECT" to be passed to
ecm_setup_version instead of an actual version number. In this case, the
version passed to project() will be used.
REVIEW: 117619
|
|
This requires the icon files to be specified (which is better than
globbing, because the build system will then be able to tell when files
are added or removed and re-run CMake).
It also removes the theme name from the filename pattern: the old code
used a shorthand theme name for a small number of themes, and didn't
allow any other themes. Extending this to arbitrary themes could cause
problems with themes that have numbers or hyphens (or whatever other
delimiter character was used) in their names. Most users are likely to
just want to install to a single theme anyway (based on a random
sampling of users of kde4_install_icons), so that is what the new syntax
requires.
The old syntax still works and behaves as before.
ecm_update_iconcache is renamed to _ecm_update_iconcache - it was never
documented as public API anyway.
REVIEW: 117617
|
|
ecm_generate_headers() now allows/forces the caller to collect the paths
of the generated headers, so that they can be passed to the install
command. This avoids issues of unexpected files being in the CamelCase
includes directory, both from previous builds and because of
case-insensitive file systems.
MODULE_NAME is removed, as it is no longer desirable or necessary.
Instead, the headers are placed directly in the output directory
(usually CMAKE_CURRENT_BUILD_DIR).
Overall, this makes ecm_generate_headers() behave much more like other
file generation macros (like the Qt ones).
The old syntax is still supported for now, to make the porting effort
easier.
REVIEW: 115765
|
|
-add test ExecuteAllModules, which is the same as FindModulesExecuteAll in CMake: include (and execute) all *cmake files, to make sure they are not completely broken
Alex
|