Home GnuPG
Diffusion GPGME 9de1c96ac3cf

python: do not export HAVE_CXX11 definition

Description

python: do not export HAVE_CXX11 definition

* lang/python/gpgme.i: ignore HAVE_CXX11 in SWIG interface

If there are two distinct builds (a) and (b) of gpgme which both build
python bindings, and build (a) also happens to build the C++ bindings,
then the generated gpg/gpgme.py file from build (a) will not be usable
with the .so generated in build (b), despite them being exactly the
same, and having nothing to do with C++.

In particular, it will fail with:


File "…/gpg/__init__.py", line 99, in <module>
  from . import core
File "…/gpg/core.py", line 10, in <module>
  from . import gpgme
File "…/gpg/gpgme.py", line 152, in <module>
  HAVE_CXX11 = _gpgme.HAVE_CXX11

AttributeError: module 'gpg._gpgme' has no attribute 'HAVE_CXX11'

By asking SWIG to ignore this definition, we stabilize the generated
.py and the .so, ensuring that they are more cleanly interoperable.

Details

Provenance
dkgAuthored on Oct 18 2018, 4:23 AM
Parents
rM12b0b5c8941b: doc: convert more links to equivalent https:// URLs
Branches
Unknown
Tags
Unknown