Page MenuHome GnuPG

gpgme:python Fix, using pkg-config (not deprecated gpg-error-config and gpgme-config)
Testing, HighPublic


gpg-error-config and gpgme-config are deprecated to prefer pkg-config (or gpgrt-config).

Still in GPGME, python binding build uses them. Let us move to pkg-config, instead.

Event Timeline

gniibe triaged this task as High priority.Sep 15 2022, 5:01 AM
gniibe created this task.

Reviewing the build process, it's just better to use @...VAR...@ by configure (instead of invoke pkg-config again in

gniibe added a project: Restricted Project.Sep 15 2022, 7:00 AM

Pushed the fix.
Note that non-in-tree build never been reliable (using the result of the configure, in tree).
So, I basically don't consider the use case of non-in-tree build.

werner changed the task status from Open to Testing.Sep 22 2022, 10:40 AM
werner removed a project: Restricted Project.


the pushed fix breaks when libgpg-error does not require special CFLAGS, i.e. when @GPG_ERROR_CFLAGS@ expands to an empty string:

running build
gcc: warning: : linker input file unused because linking not done
gcc: error: : linker input file not found: No such file or directory
Using gpgme.h from ../../src/gpgme.h
  File "/usr/lib/python3.10/", line 526, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['gcc', '-E', '', 'python3.10-gpg/include1.h']' returned non-zero exit status 1.

cu Andreas

@gniibe - Thanks for the quick response. It now works for me.
cu Andreas

gniibe mentioned this in Unknown Object (Event).Oct 31 2022, 9:03 AM