Home GnuPG

New function gpgrt_fconcat.

Description

New function gpgrt_fconcat.

* src/w32-utils.c: New.
* src/init.c (_gpg_err_init, DllMain): Call new init function.
* src/visibility.c (gpgrt_fconcat): New.
* src/gpg-error.h.in (gpgrt_fconcat): New prototype.
(GPGRT_FCONCAT_ABS): New.
(GPGRT_FCONCAT_TILDE): New.
(GPGRT_FCONCAT_SYSCONF): New.
* src/gpg-error.def.in (gpgrt_fconcat): New.
* src/gpg-error.vers: (gpgrt_fconcat): New.
* src/stringutils.c (_gpgrt_vfnameconcat): Repalce want-abs but a new
flags arg.  Change to support GPGRT_FCONCAT_SYSCONF.  Fix tilde
expansion under Windows to use CISDL_PROFILE instead of $HOME.  Adjust
all callers.
* src/gpg-error.c (main): New command "fconcat".

This function allows to get the sysconfig directory in a portable way.
On Windows this is CISDL_COMMON_APPDATA\GNU\etc. On Unix this is the
directory specified at the configure run.

This patch also changes the behaviour of tilde expansion in Windows
which was not well defined. It does now use CISDL_PROFILE instead of
the HOME envvar which is uncommon under Windows. Note that under
Windows "~user/foo" is still not defined. Tilde expansion is not done
when GPGRT_FCONCAT_SYSCONF is used.

Details

Provenance
wernerAuthored on Tue, Dec 9, 11:46 AM
Parents
rEa2a752fe21cc: po: Update Portuguese Translation.
Branches
Unknown
Tags
Unknown
Tasks
T7894: libgcrypt, scute, gpgrt/argparse, gnupg/dirmngr: Hard-coded /etc