diff options
author | Werner Koch <[email protected]> | 2013-08-01 09:20:48 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2013-08-01 09:20:48 +0000 |
commit | 9ff72e4e7e4f56c241a525479a94ed4c95efc23f (patch) | |
tree | e47ff2811dfa47de64cd73e407f07027c29eab9c /common/logging.h | |
parent | Silence compiler warning about deprecated Libgcrypt symbols (diff) | |
download | gnupg-9ff72e4e7e4f56c241a525479a94ed4c95efc23f.tar.gz gnupg-9ff72e4e7e4f56c241a525479a94ed4c95efc23f.zip |
w32: Add code to support a portable use of GnuPG.
* common/homedir.c (w32_bin_is_bin, w32_portable_app) [W32]: New.
(check_portable_app) [W32]: New.
(standard_homedir, default_homedir) [W32]: Support the portable flag.
(w32_rootdir, w32_commondir) [W32]: Ditto.
(gnupg_bindir, gnupg_cachedir, dirmngr_socket_name) [W32]: Ditto.
* common/logging.h (JNLIB_LOG_NO_REGISTRY): New.
* common/logging.c (no_registry): New variable.
(log_set_prefix, log_get_prefix): Set/get that variable.
(do_logv): Do not check the registry if that variable is set.
--
Beware: This code has not been tested because it is not yet possible
to build GnuPG 2.1 for Windows. However, the code will be the base
for an implementation in 2.0.
A portable use of GnuPG under Windows means that GnuPG uses a home
directory depending on the location of the actual binary. No registry
variables are considered. The portable mode is enabled if in the
installation directory of the the binary "gpgconf.exe" and a
file "gpgconf.ctl" are found. The latter file is empty or consists
only of empty or '#' comment lines.
Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'common/logging.h')
-rw-r--r-- | common/logging.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/common/logging.h b/common/logging.h index 89913e6e5..3b38f7370 100644 --- a/common/logging.h +++ b/common/logging.h @@ -42,6 +42,7 @@ #define JNLIB_LOG_WITH_TIME 2 #define JNLIB_LOG_WITH_PID 4 #define JNLIB_LOG_RUN_DETACHED 256 +#define JNLIB_LOG_NO_REGISTRY 512 int log_get_errorcount (int clear); void log_inc_errorcount (void); |