From 1c9694f8d50b1236d2e4f2acbe23f972da36e437 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Wed, 26 Oct 2022 12:10:57 +0200 Subject: core: New global flags "inst-type". * src/gpgme.c (gpgme_set_global_flag): Add flag "inst-type". * src/w32-util.c (_gpgme_set_get_inst_type): New. (INST_TYPE_GPG4WIN_DIR): New. (INST_TYPE_GPGDESK_DIR): New. (_gpgme_get_gpgconf_path): Implement this flag. Replace fixed strings by the macros. * src/posix-util.c (_gpgme_set_get_inst_type): New dummy. -- This is intended for use by Kleopatra to reliable find the expected GnuPG installation. --- src/posix-util.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/posix-util.c') diff --git a/src/posix-util.c b/src/posix-util.c index cf066d69..2d0ce329 100644 --- a/src/posix-util.c +++ b/src/posix-util.c @@ -79,6 +79,15 @@ _gpgme_set_override_inst_dir (const char *dir) return 0; } +/* Dummy function - see w32-util.c for the actual code. */ +int +_gpgme_set_get_inst_type (const char *value) +{ + (void)value; + return 0; /* Posix installation type is fixed. */ +} + + /* Find an executable program in the colon seperated paths. */ static char * walk_path_str (const char *path_str, const char *pgm) -- cgit v1.2.3