aboutsummaryrefslogtreecommitdiffstats
path: root/src (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* Add missing prototype for build tool.Werner Koch2014-06-251-0/+1
| | | | | | | * src/gen-posix-lock-obj.c: Include string.h. -- string.h is required for strerror ().
* New error code GPG_ERR_KEY_DISABLED.Werner Koch2014-06-101-1/+2
|
* Add code GPG_ERR_KEY_ON_CARD.Werner Koch2014-04-151-1/+2
|
* Fix a syscfg/ file name.Werner Koch2014-01-292-2/+2
| | | | | | | | | | * src/syscfg/lock-obj.arm-unknown-linux-androideabi.h: Rename to ... * src/syscfg/lock-obj-pub.arm-unknown-linux-androideabi.h: this. * src/Makefile.am (lock_obj_pub): Fix file name. -- Ooops. A wrong comment in a generated header can make a lot of trouble.
* Fix the name of the file in the comment of the output.Werner Koch2014-01-281-1/+1
| | | | * src/gen-posix-lock-obj.c (main): Chnage comment in created file.
* Add lock info for arm-unknown-linux-androideabi.Werner Koch2014-01-252-2/+23
| | | | | | * src/syscfg/lock-obj.arm-unknown-linux-androideabi.h: New. Provided by Hans-Christoph Steiner. * src/Makefile.am (lock_obj_pub): Add file.
* Make multi-threading flags available via gpg-error-config.Werner Koch2014-01-242-2/+25
| | | | | | | | | | | | | | | | | * m4/threadlib.m4: Set THREADLIB_CPPFLAGS. * src/gpg-error-config.in: Add option --mt. * configure.ac: Add support for the --mt option. * src/gpg-error.m4: Add ac_subst GPG_ERROR_MT_CFLAGS and GPG_ERROR_MT_LIBS. -- Although, libgpg-error does not yet provide an API for multi-thread support, it is useful to add the already available detection to the config script. This allows the latest Libgcrypt to take advantage of this in its regression tests. In particular for the regression tests a gpgrt_thread functions would be useful and eventually added to libgpg-error. The new gpg-error.m4 script should already be used by other packages to be prepared for future updates.
* Allow using gpgrt_lock_init on an unitialized variable.Werner Koch2014-01-243-6/+33
| | | | | | | | | | | | | | | | | | | | | * src/posix-lock.c (gpgrt_lock_init): Detect unitialized lock var. * src/w32-lock.c (gpgrt_lock_init): Ditto. -- gpgrt_lock_init may be used for dynamically allocated locks. For example gpgrt_lock_t *lock = xcalloc (1, sizeof *lock); gpgrt_lock_init (lock); gpgrt_lock_lock (lock); foo (); gpgrt_lock_unlock (lock); gpgrt_lock_destroy (lock); free (lock); This patch actually allows for this. Signed-off-by: Werner Koch <[email protected]>
* Move version number first in the Posix lock-obj.Werner Koch2014-01-173-16/+20
| | | | | | | | | * src/posix-lock-obj.h (_gpgrt_lock_t): Swap VERS and MTX and put MTX into a union. * src/posix-lock.c (gpgrt_lock_lock): Adjust for this change. * src/gen-posix-lock-obj.c (main): Change output accordingly. Signed-off-by: Werner Koch <[email protected]>
* Extend the platform dependent build rules.Werner Koch2014-01-174-44/+135
| | | | | | | | | | | | | | | | | | | | * src/mkheader.c (mk_include_name): New. (include_file): Implement '&' substitution. (try_include_file): New. (write_special): Use try_include_file and syscfg/. (main): Add a new arg. * configure.ac (CROSS_COMPILING): New am_conditional. (HOST_TRIPLET_STRING): New ac_define. * src/gen-posix-lock-obj.c (main): Print the host triplet. * src/w32-lock-obj-pub.in: Move to ... * src/syscfg/lock-obj-pub.mingw32.h: here. * src/Makefile.am (lock_obj_pub): New. (pre_mkheader_cmds): New. (gpg-error.h): Run pre_mkheader_cmds. (parts_of_gpg_error_h, lock-obj-pub.native.h): Do not use when cross-compiling. Signed-off-by: Werner Koch <[email protected]>
* Fix linking for last change on non-ELF platforms.Werner Koch2014-01-161-1/+1
| | | | | | | | | | | | | * src/Makefile.am (libgpg_error_la_LIBADD): Add LIBTHREAD. -- If configure told us to link with -lpthread we need to pass that library to the libgpg-error.la build rule. Which is the right thing to do. Without that we may run into strange errors; for example on AIX pthread_mutex_lock is silently not resolved and thus any use of gpgrt_lock_lock will immediately lead to segv. Signed-off-by: Werner Koch <[email protected]>
* Add gpgrt_lock_ functions.Werner Koch2014-01-1617-21/+843
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/gpg-error.h.in (GPGRT_LOCK_DEFINE): New. (gpgrt_lock_init): New. (gpgrt_lock_lock): New. (gpgrt_lock_unlock): New. (gpgrt_lock_destroy): New. (gpgrt_yield): New. * src/gpg-error.def.in: Add new functions. * m4/lock.m4, m4/threadlib.m4: New. Taken from current gnulib. * configure.ac: Call gl_LOCK. Check size of pthread_mutex_t. Add LIBTHREAD to GPG_ERROR_CONFIG_LIBS. * src/err-codes.h.in (GPG_ERR_INV_LOCK_OBJ): New. * src/gen-posix-lock-obj.c: New. * src/gen-w32-lock-obj.c: New. * src/lock.h, src/thread.h: New. * src/posix-lock-obj.h, src/w32-lock-obj.h: New. * src/posix-lock.c, src/w32-lock.c: New. * src/posix-thread.c, src/w32-thread.c: * src/w32-lock-obj-pub.in: New. * src/mkheader.c (include_file): Support build time include files. (write_special): Add keyword "include:lock-obj". * src/Makefile.am: (posix-lock-obj-pub.in): New rule. (noinst_PROGRAMS): Add gen-*-lock-obj helpers. * tests/t-common.h: New. * tests/t-lock.c: New. * tests/Makefile.am (t_lock_LDADD): Add new test. -- This patch introduces the gpgrt_ functions which will be extended over time to provide a library of commonly used code in GnuPG and Libgcrypt. Having them in a library named libgpg-error is a misnomer but this way we can achieve a smooth upgrade path. In contrasts to other GnuPG libraries, the gpgrt_ functions return a simple gpg_err_code_t and not gpg_error_t. The rationale for this is that a source of error identifier does not make sense here; it is better to use the source of error identifier of the caller. This can easily be achieved in a component by wrapping these function in a gpg_error macro/inline. There is no cross-compiling support for Posix platforms; the gen-posix-lock-obj tool must be run on the target system. Note that the gen-w32-lock-obj tool is not needed at build time but was used to figure out ABI definitions for Windows. Signed-off-by: Werner Koch <[email protected]>
* Improve maintainability by rewriting the mkheader helper.Werner Koch2014-01-145-261/+404
| | | | | | | | | | | | | | | | | * src/mkheader.c: New. Based on the mkheader from Libassuan. * src/mkheader.awk: Remove. * src/errnos.in: Add trailing linefeed. * src/gpg-error.h.in: Change meta include directives for use with mkheader.c. * src/Makefile.am (EXTRA_DIST): Replace mkheader.awk by mkheader.c (BUILT_SOURCES): Remove extra-h.in. (CLEANFILES): Remove extra-h.in. Add mkheader.c. (parts_of_gpg_error_h): New. (extra-h.in): Remove rule. (mkheader): Add rule. (gpg-error.h): Change rule to use mkheader. Signed-off-by: Werner Koch <[email protected]>
* Add GPG_ERR_MAC_ALGO.Werner Koch2013-11-171-1/+1
|
* w32: Fix corrupted string output.Werner Koch2013-07-151-4/+18
| | | | | | | | | * src/w32-gettext.c (get_string): Pass the nul of the utf-8 string to the conversion function but keep TRANSLEN without the nul. -- The bug first occurred on Windows 8 but it is a real thing. Assuming that a malloced buffer is zeroed out is not solid assumptions ;-)
* Remove trailing spaces from w32-gettext.c.Werner Koch2013-07-151-26/+26
| | | | --
* w32: Fix installing of .def file.Werner Koch2013-05-231-0/+1
| | | | | | | * src/Makefile.am (install-def-file): Create libdir first. -- Reported-by: LRN <[email protected]>
* Add GPG_ERR_*CRYPT_CTX* and GPG_ERR_BROKEN_*KEY.Werner Koch2013-04-111-2/+7
| | | | | | | * src/err-codes.h.in (GPG_ERR_NO_CRYPT_CTX): New. (GPG_ERR_WRONG_CRYPT_CTX, GPG_ERR_BAD_CRYPT_CTX): New. (GPG_ERR_CRYPT_CTX_CONFLICT): New. (GPG_ERR_BROKEN_PUBKEY, GPG_ERR_BROKEN_SECKEY): New.
* Add version macros and check function.Werner Koch2013-02-236-25/+159
| | | | | | | | | | | | | | | | | | | * configure.ac (VERSION_NUMBER): New ac_subst. (BUILD_FILEVERSION): Build on all platforms (BUILD_TIMESTAMP): Try to use an ISO string. * src/Makefile.am (extra-h.in): Add new version numbers. * src/versioninfo.rc.in: Update copyright year. * src/version.c: New. (gpg_error_check_version): New API. * src/gpg-error.h.in: Add gpg_error_check_version prototype. * src/gpg-error.def.in: Add gpg_error_check_version * tests/t-version.c: New. * tests/Makefile.am (TESTS): Add t-version.c * src/gpg-error-config.in: s/VERSION/PACKAGE_VERSION/. -- All other GnuPG libraries do this, thus we do it here as well.
* Fix the alias mechanism for --with-libgpg-error-prefix.Werner Koch2013-02-221-4/+5
| | | | | | | | * src/gpg-error.m4: Do not use the no-action branch in AC_ARG_WITH. -- This fixes commit aaa3f534. The bug was that --with-gpg-error-prefix always reset the value from --with-libgpg-error-prefix.
* Switch to the new automagic beta numbering scheme.Werner Koch2012-11-161-4/+4
| | | | | | * configure.ac: Change to a git only revision id setup. (BUILD_FILEVERSION): Use revision id for this. * src/versioninfo.rc.in (FileVersion): Use LT version.
* Add new source id for Libassuan.Werner Koch2012-11-161-2/+3
| | | | * src/err-sources.h.in (GPG_ERR_SOURCE_ASSUAN): New.
* Typo fix.Jordy Provost2012-08-091-1/+1
| | | | * src/err-codes.h.in: Unify uppercase.
* Use CPPFLAGS when generating mkerrcodes.hRafaël Carré2012-06-201-1/+1
| | | | | | * src/Makefile.am (mkerrcodes.h): Use CPPFLAGS. Signed-off-by: Rafaël Carré <[email protected]>
* accept --with-libgpg-error-prefix as well as --with-gpg-error-prefixJim Meyering2011-11-281-2/+12
| | | | | | * src/gpg-error.m4 (AM_PATH_GPG_ERROR): Also accept --with-libgpg-error-prefix=PFX, for consistency with our three library sibling packages.
* gpg-error-config: handle /usr/lib64, /lib64 just like /usr/lib and /libDiego Elio Pettenò2011-09-221-3/+6
| | | | | | | Distributions such as Gentoo Linux use /usr/lib64 for system libraries on multilib setups, so in those cases, ignore the libraries as well. Signed-off-by: Diego Elio Pettenò <[email protected]>
* Add GPG_ERR_AMBIGUOUSWerner Koch2011-08-231-2/+3
|
* Add GPG_ERR_DUP_KEYWerner Koch2011-08-231-1/+2
|
* Extra test for gpg-error-config scriptWerner Koch2011-04-061-1/+2
| | | | | | | | | | If the path to gpg-error-config was explicitly given by the user it may happen that it does not exists but AC_CHECK_TOOL may assume it still exists because it is somewhere in the PATH. The extra check avoids extra sh warnings. Note that we can't use test -x because that is not defined on some old systems.
* Updated error code referencesWerner Koch2011-03-041-7/+6
|
* Make gpg-error-config and gpg-error.m4 more robust.Werner Koch2011-02-232-3/+21
| | | | | | | | | This is done by taking host prefixed config scripts names in account (as suggested by bug#1261) and adding a new config option --host to print a warning if the used config script was not built for the current host. Care has been taken not to mess things up if an old config script without the option is used or if AC_CANONICAL_HOST has not been used.
* Add GPG_ERR_INV_CURVE and GPG_ERR_UNKNOWN_CURVEWerner Koch2011-02-011-7/+9
|
* Add GPG_ERR_NO_KEYSERVERWerner Koch2011-01-061-0/+1
|
* 2010-11-01 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-11-011-1/+3
| | | | | | * src/w32-gettext.c (CreateFileA): Rename to ... (MyCreateFileA): ... this, but provide macro CreateFileA.
* s/abort/TerminateProcess/Werner Koch2010-10-312-2/+4
|
* 2010-10-29 Marcus Brinkmann <[email protected]>Marcus Brinkmann2010-10-292-19/+58
| | | | | | | | | | | | * src/w32-gettext.c: Guard include of <sys/types.h>. Do not include <sys/stat.h>. (CreateFileA) [HAVE_W32CE_SYSTEM]: New wrapper function. (load_domain): Use native Windows API. * src/init.c (TLS_OUT_OF_INDEXES) [HAVE_W32CE_SYSTEM, !TLS_OUT_OF_INDEXES]: Define it. (abort) [!__MINGW32CE__]: Define it.
* Add some code to allow building with MSC.Werner Koch2010-10-284-8/+14
|
* Add comment.Werner Koch2010-10-201-0/+4
|
* Fix for W32CE.Werner Koch2010-10-203-1/+29
|
* Fix initialization of static libsWerner Koch2010-09-163-2/+27
|
* Update pl.po.Werner Koch2010-09-162-3/+9
| | | | | | Updated to gettext 0.1.17 Add a new error code.
* Add new error code.Werner Koch2010-09-022-2/+3
| | | | | Remove comment cruft.
* Require new GPG_ERR_ENABLE_ERRNO_MACROS define to include the strerrorWerner Koch2010-08-191-2/+3
| | | | | define.
* Add gpg_err_deinitlibgpg-error-1.9Werner Koch2010-07-214-5/+62
| | | | | Prepare a new release.
* Add new error code.Werner Koch2010-06-181-1/+2
| | | | | Convert de.po to utf8
* MAp some W32 error codes.Werner Koch2010-04-143-51/+71
|
* Fix type in macro name.Werner Koch2010-03-152-2/+3
| | | | | Set generated header to read-only.
* Add macro to enable gettext macros.Werner Koch2010-03-092-10/+18
|
* Use format_arg attributeWerner Koch2010-03-081-4/+16
|
* Add a mapping for ESPIPE on W32CE.Werner Koch2010-03-012-3/+4
|