Age | Commit message (Collapse) | Author |
|
|
|
|
|
Don't export API which has visibility "hidden".
Visibility attributes on variables are ignored, but call the generic
method anyway.
Remove checks for macros which obscure the attributes. Processing the
attribute directly means that is not needed.
|
|
De-duplicate it between variables and functions. The callers already
handle reporting the removal.
|
|
|
|
Fix the anchoring of the regular expression matching to cover the
complete input. This was an oversight and should have no visible
effects except that if new fields are added to a rule database,
existing rules with wildcards will greedily match the new fields.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Clang API is odd.
|
|
|
|
|
|
|
|
Don't prepend a namespace to it as we do otherwise with enum/flags.
|
|
|
|
Only one directory may provide the PyKF5 namespace, so if testing
KAuth, which depends on KCoreAddons, both have to be in the same
directory. That means that the KAuth tests can only be run
post-intallation which doesn't really cause problems.
|
|
Allow modifying the name also.
|
|
Don't process the same function name twice.
|
|
|
|
The KConfig build creates two libraries and they should both be output
in the same place so that they can be tested together.
|
|
It is not appropriate to decorate each forward declaration with the SIP
attribute /External/. That is only needed for forward declarations of
types which are defined in a different module.
Local forward declarations can be omitted from the sip code. In sip
code, a forward declaration followed later by a full class definition is
an error.
Omit forward declarations unless they are decorated with the external
attribute. Introduce a rules database for consumers to decorate them
with the attribute as required.
|
|
Custom rules should be able to deal with lists in these cases. This is
already the case for function parameters.
|
|
|
|
Packagers can execute this script with
cmake -D PYTHON_UMBRELLA_MODULE_FILE=/where/ever/PyKF5/__init__.py -P /path/to/ECM/find-modules/GeneratePythonBindingUmbrellaModule.cmake
Soon, this is likely to do more than create an empty file.
|
|
Use find_package to locate the executable.
|
|
The LLVM project has picked a new version scheme
http://blog.llvm.org/2016/12/llvms-new-versioning-scheme.html
which means that major version numbers will be bumped more regularly,
the minor version will remain at zero, and the patch version will be
bumped. We will have to see how distros respond in terms of file
naming.
|
|
The suffix is used later to run the clang executable in order to
determine the built-in system includes.
|
|
The dist-packages directory which is currently hardcoded is unsuitable
to non-debian package creation. Set the directory to 'site-packages' by
default.
|
|
Currently this is rather simple, allowing only matching typedefs by
name. If we need more later, we can extend the interface. This will
make it possible to add bindings for the K18n framework.
|
|
|
|
Don't use the text 'Parse error' for warnings, which might confuse IDEs.
|
|
The Python logging module uses logging severities with numerical values
which form a sequence in steps of 10. The Clang cindex.Diagnostic
numerical values use a step size of 1, so the two are incompatible.
Introduce a mapping function so that appropriate errors get issued when
attempting to build the bindings. The logging module has one surplus
diagnostic level, but we simply never use it.
BUG: 374801
|
|
The generator expression here looks like it should work, but it does not
set the appropriate flags for compilation. It seems that the
CXX_STANDARD property is not yet populated at the time the generator
expression is evaluated (to be investigated later).
This came to light because users of Qt 5.7+ attempted to generate the
bindings, but they encountered errors. The step of using libclang to
parse the provided headers was actually failing, but that was not
noticed, perhaps because the logging infrastructure in sip_generator
does not emit it (to investigate later).
BUG: 374801
|
|
The Q_DECLARE_TR_FUNCTIONS macro contains a `public:` access specifier,
but the sip_generator just pastes the entire macro name. Adjust the
generator to extract the correct access specifier.
|
|
Note which rule has a modification effect.
|
|
It is unused.
|
|
|
|
|
|
Summary: Cut-and-paste-o from the Python detection code.
Reviewers: #frameworks, skelly, apol
Reviewed By: apol
Subscribers: #buildsystem
Tags: #frameworks, #buildsystem
Differential Revision: https://phabricator.kde.org/D3952
|
|
|
|
This can be used by KF5 libraries to generate python 2 and 3 bindings.
|
|
When sip is executed it is passed one .sip file. However, it uses that
to generate multiple cpp source files, one per class in the sip file.
Buildsystems need to know the outputs of commands, so this does not work
well as the output can't easily be predicted.
So, create a unity build of all files to compile into the python module.
|
|
The ruleset is used to transform or omit artifacts in C++ header files
when determining the SIP content to generate. Some content common to
all Qt-using libraries can be processed by using the rule set present
here. For example, most Q_METATYPE internal declarations should be
discarded.
|
|
These files process C++ headers with libclang and python-clang bindings,
using the AST to generate SIP files for PyQt binding library generation.
The design allows for further extensions which can process other
artifacts found in headers. This iteration of the design is a simple
minimum which suffices to generate headers for KItemModels and some
other libraries.
|
|
FindPoppler wasn't available in ecm < 5.19
CCMAIL:faure@kde.org
|
|
At least Okular and KBibTex include a FindPoppler.cmake module but this one
uses the new ECMFindModuleHelpers and has imported targets.
REVIEW: 126183
|