GPGME_DEBUG on Android, which makes env vars hard

Hans-Christoph Steiner hans at
Tue Sep 4 19:58:09 CEST 2012

I was just looking at gpgme/debug.c.  Something like
gpgme_set_debug_level(int level) and gpgme_set_debug_log(char*
logfilename) would be perfect.

gpgme_set_debug_level() looks trivial since it would just update the
static var debug_level and would take effect immediately.

gpgme_set_debug_log() would be a little more work since the file opening
logic in debug_init() would have to be changed.

Another idea would be for setting this from a conf file somewhere, but
I'm not sure if there is a gpgme conf file.


On 08/31/2012 04:05 PM, Hans-Christoph Steiner wrote:
> So this kind of thing would be super helpful for me to debug the
> GnuPG-for-Android app, but since Android apps are Java, and they are
> launched from a mysterious non-UNIX process, using environment variables
> is difficult at best.
> I would like to do exactly this:
> GPGME_DEBUG=9:/tmp/gpgme.debug
> Is there anyway to do this in C code?  Like an option to the gpg_engine?
> .hc

More information about the Gnupg-devel mailing list