2015-08-26  Werner Koch  <wk@gnupg.org>

	Release 1.6.0.
	* configure.ac: Set LT version to C25/A14/R0.

	Make use of GPGRT macros is available.
	* src/gpgme.h.in (_GPGME_INLINE): Define using GPGRT_INLINE if
	possible.  Fix problem with -Wundef by adding an extra "defined()".
	(_GPGME_GCC_VERSION): Define using GPGRT_ macro if possible.

2015-08-25  Werner Koch  <wk@gnupg.org>

	Avoid -Wundef warnings if gpgme.h is used by g++.
	* src/gpgme.h.in (_GPGME_INLINE): Move definition into the
	extern-C-scope.

	Add configure option --enable-build-timestamp.
	* configure.ac (BUILD_TIMESTAMP): Set to "<none>" by default.

2015-08-25  Daiki Ueno  <ueno@gnu.org>

	Relax ttyname_r error checks.
	* src/engine-assuan.c (llass_new): Don't treat ttyname_r error as
	fatal.
	* src/engine-g13.c (g13_new): Likewise.
	* src/engine-gpg.c (gpg_new): Likewise.
	* src/engine-gpgsm.c (gpgsm_new): Likewise.
	* src/engine-uiserver.c (uiserver_new): Likewise.

2015-08-25  Werner Koch  <wk@gnupg.org>

	Cleanup layout of gpgme.h.
	* src/gpgme.h.in: Reorder prototypes.  Chnage some comments.

	Improve error return by checking the FAILURE status.
	* src/gpgme.h.in (GPGME_STATUS_FAILURE): New.
	* src/status-table.c (FAILURE): New.
	* src/op-support.c (_gpgme_parse_failure): New.
	* src/passphrase.c (_gpgme_passphrase_status_handler): Forward FAILURE
	status line to the status callback.

	* src/decrypt.c (op_data_t): Add field failure_code.
	(_gpgme_decrypt_status_handler): Parse that code and act upon it on EOF.
	* src/encrypt.c (op_data_t): Add field failure_code.
	(_gpgme_encrypt_status_handler): Parse that code and act upon it on EOF.
	* src/genkey.c (op_data_t): Add field failure_code.
	(genkey_status_handler): Parse that code and act upon it on EOF.
	* src/passwd.c (op_data_t): Add field failure_code.
	(passwd_status_handler): Parse that code and act upon it on EOF.
	* src/sign.c (op_data_t): Add field failure_code.
	(_gpgme_sign_status_handler): Parse that code and act upon it on EOF.
	* src/verify.c (op_data_t): Add field failure_code.
	(_gpgme_verify_status_handler): Parse that code and act upon it on EOF.

	tests: Allow using run-sign to test loopback pinentry problems.
	* tests/run-sign.c: Add options --status and --loopback.

2015-08-24  Werner Koch  <wk@gnupg.org>

	Call status_cb for an ERROR status seen in the passphrase handler.
	* src/passphrase.c (_gpgme_passphrase_status_handler): Call status_cb.

	w32: Look for gpgconf in the new GnuPG 2.1 install dir.
	* src/w32-util.c (_gpgme_get_gpgconf_path): Try another location of
	gpgconf.exe.

	w32: Expect gpgme-w32spawn.exe only in the gpgme installation dir.
	* src/w32-util.c (find_program_at_standard_place): Remove.
	(_gpgme_get_gpg_path): Make the search order more explicit.
	(_gpgme_get_gpgconf_path): Ditto.
	(_gpgme_get_w32spawn_path): Search only in the inst_dir.

	w32: Print the installation directory in debug mode.
	* src/debug.c (debug_init) [W32]: Show libgpgme installation dir.

	Add an export secret key feature.
	* src/gpgme.h.in (GPGME_EXPORT_MODE_SECRET): New.
	(GPGME_EXPORT_MODE_RAW): New.
	(GPGME_EXPORT_MODE_PKCS12): New.
	* src/export.c (export_start, export_ext_start): Allow new flags.
	* src/engine-gpg.c (export_common): Support secret key export.
	* src/engine-gpgsm.c (gpgsm_export, gpgsm_export_ext): Ditto.

	* src/gpgme-tool.c (cmd_export): Add options --secret, --raw,
	and --pkcs12.
	* tests/run-export.c (main): Likewise.

2015-08-16  Ben Kibbey  <bjk@luxsci.net>

	Parse INQUIRE_MAXLEN in the passphrase callback.
	* src/passphrase.c (_gpgme_passphrase_status_handler): Parse
	GPGME_STATUS_INQUIRE_MAXLEN.
	* src/passphrase.c (_gpgme_passphrase_command_handler): Send the
	INQUIRE_MAXLEN status message.

	Fix gpgme_{get,set}_status_cb to match documentation.
	* doc/gpgme.texi: Minor fixes.
	* src/gpgme.c (gpgme_get_status_cb): Set return variables to NULL and
	check for a valid ctx pointer.

	Parse the INQUIRE_MAXLEN status message.
	* src/gpgme.h.in: (gpgme_status_code_t): Add INQUIRE_MAXLEN.
	* src/status-table.c (status_table_s): Ditto.
	* src/genkey.c (genkey_status_handler): Parse INQUIRE_MAXLEN.
	* src/decrypt.c (_gpgme_decrypt_status_handler): Ditto.
	* src/sign.c (_gpgme_sign_status_handler): Ditto.

	This status message informs the client of the maximum length of an
	inquired line. It is sent from gpg and forwarded to the client via
	gpgme_status_cb_t.

	Add gpgme_set/get_status_cb().
	* src/gpgme.h.in (gpgme_set_status_cb): New.
	(gpgme_get_status_cb): New.
	(gpgme_status_cb_t): New.
	* src/gpgme.c (gpgme_set_status_cb): New.
	(gpgme_get_status_cb): New.
	* src/context.h (status_cb): New.
	(status_cb_value): New.
	* src/gpgme.def: Export new symbols.
	* src/libgpgme.vers: Ditto.
	* doc/gpgme.texi: Document these new functions.

	Make use of user passphrase handler during genkey.
	* src/genkey.c (genkey_start): set engine passphrase command handler.

2015-08-12  Ben Kibbey  <bjk@luxsci.net>

	Also check the return code in gpg_sign().
	* src/engine-gpg.c (gpg_sign): Check return value from start().

2015-08-11  Ben Kibbey  <bjk@luxsci.net>

	Check the return value when starting gpg.
	* src/engine-gpg.c (gpg_decrypt, gpg_delete, gpg_passwd): Check return
	value of start().

2015-07-31  Andre Heinecke  <aheinecke@intevation.de>

	Add offline mode support for CMS keylisting.
	* doc/gpgme.texi: Document offline mode.
	* src/context.h (gpgme_context): Add offline.
	* src/engine-backend.h (keylist, keylist_ext): Add engine_flags.
	* src/engine.c, src/engine.h (_gpgme_engine_op_keylist): Ditto.
	  (_gpgme_engine_op_keylist_ext): Ditto.
	* src/engine.h (GPGME_ENGINE_FLAG_OFFLINE): New.
	* src/engine-gpg.c (gpg_keylist, gpg_keylist_ext): Ditto.
	* src/engine-gpgsm.c (gpgsm_keylist): Handle engine_flags.
	  (gpgsm_keylist_ext): Ditto.
	* src/gpgme.c (gpgme_set_offline, gpgme_get_offline): New.
	* src/gpgme.def (gpgme_set_offline, gpgme_get_offline): New.
	* src/gpgme.h.in (gpgme_set_offline, gpgme_get_offline): New.
	* src/libgpgme.vers (gpgme_set_offline, gpgme_get_offline): New.
	* src/keylist.c (gpgme_op_keylist_start): Set offline flag.
	  (gpgme_op_keylist_ext_start): Ditto.
	* tests/run-keylist.c (show_usage, main): Add offline argument.

2015-07-23  Peter Wu  <peter@lekensteyn.nl>

	build: ignore scissor line for the commit-msg hook.
	* build-aux/git-hooks/commit-msg: Stop processing more lines when the
	  scissor line is encountered.

2015-07-23  Werner Koch  <wk@gnupg.org>

	Add option --lib-version to gpgme-tool.
	* src/gpgme-tool.c (options, parse_options):  Add --lib-version
	(CMD_LIBVERSION): New.
	(main): Implement.

2015-06-08  Werner Koch  <wk@gnupg.org>

	Release 1.5.5.

	Fix regression with gpgsm 2.0 due to "OPTION with-secret".
	* src/engine-gpgsm.c (gpgsm_assuan_simple_command): Do not terminate
	on a status lines.

	tests: Add option --secret to run-keylist.

	Fix compiler warnings about unused value in TRACE macros.
	* src/debug.h: Change macros to not have a literal 0 as last
	expression of the comma operator.
	* src/debug.c (_gpgme_debug_frame_end): Return 0.
	(_gpgme_debug): Return 0.

	Fix test suite for GnuPG 2.1 which uses pubring.kbx.
	* tests/gpgsm/final.test: New.
	* tests/gpgsm/initial.test: New.
	* tests/gpg/start-stop-agent: Move to ../.
	* tests/gpgsm/Makefile.am (TESTS_ENVIRONMENT): Export top_srcdir.
	(TESTS): Add intial.test and final.test.
	(AM_LDFLAGS): Add -no-install.
	(clean-local): Use start-stop-agent
	(initial.test): Add dependency.
	* tests/gpg/Makefile.am (top_srcdir): Export top_srcdir.
	(AM_LDFLAGS): Add -no-install.
	(check-local): Depend on pubring-stamp instead of pubring.gpg.
	(initial.test): Depend on check-local.
	(./pubring-gpg): Replace by rule for ./pubring-stamp.

2015-06-05  Matthew Barnes  <mbarnes@redhat.com>

	Set GPGME_SIGSUM_KEY_REVOKED also for gpg.
	* src/verify.c (calc_sig_summary): Handle GPG_ERR_CERT_REVOKED.

2015-06-05  Werner Koch  <wk@gnupg.org>

	Fix segv for userids with a backslash.
	* src/engine-gpg.c (gpg_keylist_preprocess): Increment SRC for a
	backslash.

2015-04-13  Werner Koch  <wk@gnupg.org>

	Release 1.5.4.

	w32: Use -static-libgcc to avoid linking to libgcc_s_sjlj-1.dll.
	* src/Makefile.am (extra_ltoptions): New.
	(libgpgme_la_LDFLAGS): Use it.
	(libgpgme_pthread_la_LDFLAGS): Ditto.
	(libgpgme_glib_la_LDFLAGS): Ditto.

2015-03-16  Werner Koch  <wk@gnupg.org>

	Fix potential crash in trace macro.
	* src/signers.c (gpgme_signers_add): Avoid deref of a NULL KEY in the
	trace macro.
	* src/engine-spawn.c (engspawn_release): Remove always true condition.
	* src/engine-gpg.c (gpg_release): Ditto.

	Fix one byte too short malloc.
	* src/engine-spawn.c (add_data): Fix malloc

2015-01-30  Werner Koch  <wk@gnupg.org>

	Switch to automake 1.14 and update  build-aux files.

2014-12-11  Werner Koch  <wk@gnupg.org>

	Release 1.5.3.
	* configure.ac: Set LT version to C24/A13/R2.

2014-12-08  Werner Koch  <wk@gnupg.org>

	Return an error for some export key operations.
	* src/context.h (OPDATA_EXPORT): New.
	* src/export.c (op_data_t): New.
	(release_op_data): New.
	(parse_error): New.
	(export_status_handler): New.
	(export_start, export_ext_start): Prepare op_data.
	(gpgme_op_export_ext, gpgme_op_export_keys): Return an error from the
	status handler.

2014-11-21  Werner Koch  <wk@gnupg.org>

	Release 1.5.2.
	* configure.ac: Set LT version to C24/A13/R1.

	Update the previous commit.
	* src/sign.c (gpgme_op_sign_result): Reformat and take care of failed
	malloc.

2014-11-21  Ben Kibbey  <bjk@luxsci.net>

	Fix returning new signatures when there are none.
	* src/sign.c (gpgme_op_sign_result): Test that invalid and valid
	signatures add up to gpgme_signers_count().

2014-11-06  Werner Koch  <wk@gnupg.org>

	Improve the debug output a bit.
	* src/debug.h (TRACE_ERR): Include the line number in the output.

2014-10-02  Werner Koch  <wk@gnupg.org>

	build: Implement SYSROOT feature.
	* configure.ac: Document SYSROOT.
	* m4/gpg-error.m4: Update from libgpg-error master.
	* src/gpgme.m4: Implement SYSROOT stuff.

2014-09-24  Werner Koch  <wk@gnupg.org>

	tests: Delay some test file extraction until "make check".
	* tests/gpg/Makefile.am (all-local): Change to check-local.
	* tests/gpgsm/Makefile.am (all-local): Ditto.

2014-09-24  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>

	Clean up gpgme's tests/gpg when gpg2.1 is available.
	* tests/gpg/Makefile.am: Clean up .gpg-v21-migrated

2014-08-12  Werner Koch  <wk@gnupg.org>

	gpgme-tool: Print fingerprint and keyid with keyservers.
	* src/gpgme-tool.c (cmd_keylist): Print keyid.  Print FPR only if
	available.

	Handle modern keyserver output which may emit the fingerprint.
	* src/engine-gpg.c (read_colon_line): Split preprocessed lines.
	(gpg_keylist_preprocess): Limit keyid field and print fingerprint.

	gpgme-tool: Install gpgme-tool.
	* src/Makefile.am (bin_PROGRAMS): New.  Add gpgme-tools.
	(noinst_PROGRAMS): Remove.

	gpgme-tool: Fix segv for external key listing.
	* src/gpgme-tool.c (result_xml_escape): Allow for DATA being NULL.

2014-07-30  Werner Koch  <wk@gnupg.org>

	Release 1.5.1.
	* configure.ac: Change LT version to C24/A13/R0.

	Fix possible realloc overflow for gpgsm and uiserver engines.
	* src/engine-gpgsm.c (status_handler):
	* src/engine-uiserver.c (status_handler):

2014-06-26  Werner Koch  <wk@gnupg.org>

	w32: Get IOSPAWN flag back in sync with spawn helper.
	* src/gpgme-w32spawn.c: Include priv-io.h.

2014-06-10  Werner Koch  <wk@gnupg.org>

	Add new reason codes to the INV_RECP status code.
	* src/op-support.c (_gpgme_parse_inv_recp): Add codes 13 and 14.

2014-06-04  Werner Koch  <wk@gnupg.org>

	Add new keylist mode GPGME_KEYLIST_MODE_WITH_SECRET.
	* src/gpgme.h.in (GPGME_KEYLIST_MODE_WITH_SECRET): New.
	* src/engine-gpg.c (gpg_keylist_build_options): Handle new mode.
	* src/engine-gpgsm.c (gpgsm_keylist, gpgsm_keylist_ext): Ditto.
	* src/keylist.c (parse_sec_field15): Add arg key and take care of
	--with-secret output.

	* src/gpgme-tool.c (gt_get_keylist_mode, cmd_keylist_mode): Add
	"with_secret".  Print card info and and secret flag for subkeys.

2014-05-21  Werner Koch  <wk@gnupg.org>

	Release 1.5.0.
	* configure.ac: Change LT version to C22/A11/R0.

2014-05-13  Werner Koch  <wk@gnupg.org>

	Add 6 new GPGME_STATUS_ codes.
	* src/status-table.c: Also add missing DECRYPTION_INFO entry.

2014-05-08  Werner Koch  <wk@gnupg.org>

	Add field CURVE to the key info.
	* src/gpgme.h.in (struct _gpgme_subkey): Add field CURVE.
	* src/key.c (gpgme_key_unref): Free CURVE.
	* src/keylist.c (keylist_colon_handler): Set CURVE.

	* src/gpgme.c (gpgme_release): For failsafe reasons reset engine and
	engine info after freeing.

	Fix a memory access and a double slash bug.
	* src/engine-spawn.c (engspawn_start): Allocate space for list
	terminator.
	* src/posix-util.c (walk_path): Fix trailing slash detection.

	Map public key algos returned by gpg to gpgme values.
	* src/conversion.c (_gpgme_map_pk_algo): New.
	* src/decrypt.c (parse_enc_to): Add arg PROTOCOL and map pubkey algo.
	(_gpgme_decrypt_status_handler): Map pubkey algo.
	* src/keylist.c (keylist_colon_handler): Map pubkey algo.
	* src/sign.c (parse_sig_created): Add arg PROTOCOL and map pubkey
	algo.
	* src/verify.c (parse_new_sig): Ditto.
	(parse_valid_sig): Ditto.

	* src/gpgme.h.in (GPGME_PK_ECC): New.
	(GPGME_MD_SHA224): New.
	* src/gpgme.c (gpgme_pubkey_algo_name): Add GPGME_PK_ECC case.
	(gpgme_hash_algo_name): Add GPGME_MD_SHA224.

	Add GPGME_ENCRYPT_NO_COMPRESS flag.
	* src/gpgme.h.in (GPGME_ENCRYPT_NO_COMPRESS): New.
	* src/engine-gpg.c (gpg_encrypt, gpg_encrypt_sign): Implement it.
	* src/gpgme-tool.c (_cmd_sign_encrypt): Add option --no-compress.

2014-04-16  Werner Koch  <wk@gnupg.org>

	w32: Fix another memleak on error.
	* src/w32-io.c (create_reader): free CTX.

2014-04-15  Werner Koch  <wk@gnupg.org>

	w32: Fix memleak in an error code paths.
	* src/w32-io.c (create_writer): Free CTX in cased of bad FD.
	* src/w32-util.c (_gpgme_mkstemp): Free TMPNAME in case of a failed
	mkstemp.

	Fix possible zombie processes.
	* src/posix-io.c (_gpgme_io_waitpid): Protect waitpid agains EINTR.
	(_gpgme_io_dup): Likewise.
	(_gpgme_io_connect): Likewise.

2014-04-10  Werner Koch  <wk@gnupg.org>

	Actually implement flags for gpgme_op_spawn.
	* src/spawn.c (gpgme_op_spawn_start, gpgme_op_spawn): Pass FLAGS dow
	to spawn_start and add FLAGS args along the call path.
	* src/engine-spawn.c (engspawn_start): Hack to automagically provide
	argv[0].

	Add GPGME_PROTOCOL_SPAWN and gpgme_op_spawn.
	* src/gpgme.h.in (GPGME_PROTOCOL_SPAWN): New.
	(GPGME_SPAWN_DETACHED, GPGME_SPAWN_ALLOW_SET_FG): New.
	* src/gpgme.c (gpgme_set_protocol): Add new protocol.
	(gpgme_get_protocol_name): Ditto.
	* src/spawn.c: New.
	* src/libgpgme.vers, src/gpgme.def: Add new public functions.
	* src/engine-spawn.c: New.
	* src/Makefile.am: Add new files.
	* src/engine-backend.h (struct engine_ops): Add OPSPAWN.
	* src/engine.c (engine_ops): Add _gpgme_engine_ops_spawn.
	(gpgme_get_engine_info): Add Spawn to the list of protocols.
	(_gpgme_engine_op_spawn): New.

	* src/gpgme-tool.c (gt_protocol_from_name): Add new protocol.
	(gt_spawn, cmd_spawn): New.

	Add gpgme_get_dirinfo.
	* src/dirinfo.c (gpgme_get_dirinfo): New.
	* tests/t-engine-info.c (main): Print results from that function.

	Make use of internal iospawn flags more flexible.
	* src/priv-io.h (IOSPAWN_FLAG_DETACHED): New. Renumber the others.
	* src/w32-io.c (_gpgme_io_spawn): Use DETACHED_PROCESS process only if
	IOSPAWN_FLAG_DETACHED is given.
	* src/w32-qt-io.cpp (_gpgme_io_spawn): Ditto.
	* src/w32-glib-io.c (_gpgme_io_spawn): Ditto.
	* src/assuan-support.c (my_spawn): Pass IOSPAWN_FLAG_DETACHED flags.
	* src/dirinfo.c (read_gpgconf_dirs): Ditto.
	* src/engine-gpg.c (start): Ditto.
	* src/engine-gpgconf.c (gpgconf_read, gpgconf_write): Ditto.
	* src/version.c (_gpgme_get_program_version): Ditto.

	Make sure a spawned process has all standard fds connected.
	* src/posix-io.c (_gpgme_io_spawn): dup /dev/null also to unsued
	stdout.

2014-03-13  Werner Koch  <wk@gnupg.org>

	Add configure option --enable-fixed-path.
	* configure.ac: Add option --enable-fixed-path.
	(FIXED_SEARCH_PATH): New ac_define.
	* src/posix-util.c (walk_path): Make use of the option.  Remove
	current directory from fallback PATH.

2014-03-11  Werner Koch  <wk@gnupg.org>

	Avoid pointer arithmetic on void pointer.
	* src/gpgme.c (gpgme_io_writen): Use new var buffer.

	Change implementation return type to match the definition.
	* src/gpgme.c (gpgme_get_sub_protocol): Change return type to
	gpgme_protocol_t.

2014-03-05  Daiki Ueno  <ueno@gnu.org>

	doc: Fix documentation of struct data types.
	* gpgme.texi (Key Management): Document is_cardkey and card_number
	members of gpgme_subkey_t.
	(Decrypt): Remove description of the non-existent wrong_key_usage
	member of gpgme_recipient_t.
	(Verify): Document pka_address member of gpgme_signature_t.
	(Creating a Signature): Add missing member names in
	gpgme_new_signature_t.
	(Registering I/O Callbacks): Fix reference of gpgme_io_cbs struct.

2014-02-21  Werner Koch  <wk@gnupg.org>

	Always pass correct name to argv[0].  Ignore GPG_AGENT_INFO for gpg2.
	* src/dirinfo.c (WANT_GPG_ONE_MODE): New.
	(struct dirinfo): Add field "gpg_one_mode".
	(get_gpgconf_item): Set that field and return it if requested.
	(_gpgme_in_gpg_one_mode): New.
	* src/engine-gpg.c (build_argv): Check GPG_AGENT_INFO only in gpg-1
	mode.

	* src/dirinfo.c (_gpgme_get_basename): New.
	* src/engine-g13.c (g13_new): Take argv[0] from the pgmname.
	* src/engine-gpgsm.c (gpgsm_new): Ditto.
	* src/engine-gpg.c (build_argv): Ditto. Add arg PGMNAME.
	(start): Pass PGMNAME to buildargv.

2014-02-12  Werner Koch  <wk@gnupg.org>

	Fix type inconsistency between gpgme.h and gpgme.c.
	* src/gpgme.c (gpgme_set_pinentry_mode): Fix type of MODE.

2014-01-10  Werner Koch  <wk@gnupg.org>

	Use the generic autogen.sh script.
	* autogen.rc: New.
	* Makefile.am (EXTRA_DIST): Add it.
	* autogen.sh: Update from GnuPG.

	* configure.ac (AM_SILENT_RULES): New.

2014-01-07  Werner Koch  <wk@gnupg.org>

	Make gpgconf engine work again - fixes 02ba35c1.
	* src/gpgconf.c: Remove ENABLE_GPGCONF and move prototypes to ...
	* src/engine-backend.h: ... here.

	Make gpgme_new return a proper error if no engines are installed.
	* src/engine.c (gpgme_get_engine_info): Improve error handling.
	(_gpgme_engine_info_copy): Ditto.
	* src/gpgme.c (gpgme_new): Return error GPG_ERR_NO_ENGINE.

	Print the full PATH in the log if gpg was not found.
	* src/posix-util.c (walk_path): Keep a copy of PATH.

2014-01-06  Werner Koch  <wk@gnupg.org>

	Add global flags disable-gpgconf, gpgconf-name, and gpg-name.
	* src/gpgme.c (gpgme_set_global_flag): Add names "disable-gpgconf",
	"gpgconf-name", and "gpg-name".
	* src/dirinfo.c (_gpgme_dirinfo_disable_gpgconf): New.
	(get_gpgconf_item): Minor debug info change.
	* src/posix-util.c (default_gpg_name, default_gpgconf_name): Add vars.
	(_gpgme_set_default_gpg_name): New.
	(_gpgme_set_default_gpgconf_name): New.
	(_gpgme_get_gpg_path, _gpgme_get_gpgconf_path): Use new vars.
	(walk_path): Add debug output on failure.
	* src/w32-util.c (default_gpg_name, default_gpgconf_name): Add vars.
	(replace_slashes): New.
	(get_basename): New.
	(_gpgme_set_default_gpg_name): New.
	(_gpgme_set_default_gpgconf_name): New.
	(_gpgme_get_gpg_path, _gpgme_get_gpgconf_path): Use new vars.

	* tests/t-engine-info.c (main): Add --verbose and --set-global-flag
	options.

2013-12-27  Werner Koch  <wk@gnupg.org>

	Locate engine names only at runtime and prefer GnuPG-2.
	* configure.ac (NEED_GPG_VERSION, NEED_GPGSM_VERSION)
	(NEED_G13_VERSION, NEED_GPGCONF_VERSION): Remove vars and all related
	checks.  Do not check for any engine version.
	(HAVE_ASSUAN): Remove AM conditional.
	* src/Makefile.am: Remove separate component vars and always build all
	engines but uiserver.
	* src/dirinfo.c (WANT_GPGCONF_NAME): New.
	(struct dirinfo): Add field gpgconf_name.
	(_gpgme_get_default_gpgconf_name): Use WANT_GPGCONF_NAME.
	(get_gpgconf_item): Set gpgconf name and adjust for _gpgme_get_*_path
	now returning a malloced string.
	* src/engine.c (engine_ops): Always init all engines except for
	uiserver.
	* src/posix-util.c (_gpgme_get_gpgsm_path, _gpgme_get_g13_path):
	Remove unused functions.
	(walk_path): New.
	(_gpgme_get_gpg_path, _gpgme_get_gpgconf_path ): Re-implement using
	walk_path.
	* src/w32-util.c (_gpgme_get_gpgsm_path, _gpgme_get_g13_path): Remove
	unused functions.
	(_gpgme_get_gpg_path, _gpgme_get_gpgconf_path): Return a malloced
	string.
	* src/engine-g13.c (g13_get_req_version): Use a hardwired string with
	the required version.  This info belongs into this file.
	* src/engine-gpg.c (gpg_get_req_version): Ditto.
	* src/engine-gpgconf.c (gpgconf_get_req_version): Ditto.
	* src/engine-gpgsm.c (gpgsm_get_req_version): Ditto.
	* tests/t-engine-info.c: Replace now useless test by an info output.
	* tests/gpg/Makefile.am (GPG, GPG_AGENT): Hardwire gpg and gpg-agent.
	* tests/gpgsm/Makefile.am (GPGSM): Hardwire gpgsm.

2013-08-19  Werner Koch  <wk@gnupg.org>

	Document API change for GPGME_EVENT_DONE from 2009.
	* doc/gpgme.texi (I/O Callback Interface): Fix description for the
	event arg.

	Fix possible segv in the gpgme_op_card_edit.
	* src/edit.c (gpgme_op_edit_start, gpgme_op_card_edit_start): Do not
	deref a NULL KEY in TRACE_BEG.

	tests: Fix NULL ptr deref in gpgsm/t-verify.
	* tests/gpgsm/t-verify.c (check_result): Do not dereference a sig or
	sig->fpr if NULL.

2013-08-12  Werner Koch  <wk@gnupg.org>

	Release 1.4.3.
	* configure.ac: Change LT version to C22/A11/R0.

	Make test suite workable with GnuPG 2.1.
	* tests/gpg/start-stop-agent: New.
	* tests/gpg/initial.test: New.
	* tests/gpg/final.test: New.
	* tests/gpg/Makefile.am (c_tests): New.
	(TESTS): Move all to c_tests.  Add initial.test, final.test, and
	c_tests.
	(TESTS_ENVIRONMENT): Add C_ALL=C
	(private_keys): New.
	(EXTRA_DIST): Add new files.
	(./private-keys-v1.d/gpg-sample.stamp): Copy private keys.
	(all-local): Depend on gpg-sample.stamp.
	* tests/gpg/13CBE3758AFE42B5E5E2AE4CED27AFA455E3F87F: New.
	* tests/gpg/13CD0F3BDF24BE53FE192D62F18737256FF6E4FD: New.
	* tests/gpg/76F7E2B35832976B50A27A282D9B87E44577EB66: New.
	* tests/gpg/7A030357C0F253A5BBCD282FFC4E521B37558F5C: New.
	* tests/gpg/A0747D5F9425E6664F4FFBEED20FBCA79FDED2BD: New.

	Improve detection of default gpg by configure.
	* configure.ac: Move test for gpgconf before test for gpg.
	(GPG, GPGSM, G13): Use gpgconf instead of AC_PATH_PROG if possible.

2013-08-09  Werner Koch  <wk@gnupg.org>

	Add function gpgme_data_identify.
	* src/gpgme.h.in (gpgme_data_type_t): New.
	(gpgme_data_identify): New prototype.
	* src/data-identify.c: New.
	* src/parsetlv.c, src/parsetlv.h: New.  Take from gpa.
	* src/libgpgme.vers, src/gpgme.def: Add gpgme_data_identify.
	* src/gpgme-tool.c (status): Add STATUS_IDENTIFY_RESULT.
	(gt_identify): New.
	(cmd_identify): New.

	(hlp_passwd): Move close to cmd_passwd.

2013-08-02  Werner Koch  <wk@gnupg.org>

	Prefer GnuPG-2 engines over GnuPG-1.
	* src/util.h: Move some prototypes to ...
	* src/sys-util.h: New.
	* src/Makefile.am (main_sources): Add sys-util.h.
	* configure.ac (AH_VERBATIM): Add DIRSEP_C and DIRSEP_S.
	* src/dirinfo.c: Include sys-util.h.
	(WANT_GPG_NAME, WANT_GPGSM_NAME, WANT_G13_NAME)
	(WANT_UISRV_SOCKET): New.
	(dirinfo): Add corresponding fields.
	(parse_output): Add arg COMPONENTS and set new fields.
	(read_gpgconf_dirs): Add arg components and act upon it.
	(get_gpgconf_item): Call read_gpgconf_dirs two times.  Add debug
	output.
	(_gpgme_get_default_gpg_name): New.
	(_gpgme_get_default_gpgsm_name): New.
	(_gpgme_get_default_g13_name): New.
	(_gpgme_get_default_gpgconf_name): New.
	(_gpgme_get_default_uisrv_socket): New.
	* src/engine-gpg.c, src/engine-g13.c, src/engine-gpgconf.c
	* src/engine-gpgsm.c, src/engine-uiserver.c: Change to use
	_gpgme_get_default_ instead of those from sys-util.h.
	* src/posix-util.c (_gpgme_get_gpg_path): Include sys-util.h.
	(_gpgme_get_uiserver_socket_path): Remove.
	* src/w32-util.c (_gpgme_get_gpg_path): Include sys-util.h.
	(_gpgme_get_uiserver_socket_path): Remove.

	w32: Try to locate gpg in the gpgme installation dir.
	* src/w32-util.c (my_hmodule): New.
	(wchar_to_utf8): New.
	(DllMain): New.
	(_gpgme_get_inst_dir): New.
	(find_program_in_dir): New.
	(find_program_in_inst_dir): Add arg INST_DIR.
	(_gpgme_get_gpg_path): Get inst_dir before acquiring the lock.
	(_gpgme_get_gpgconf_path): Ditto.
	(_gpgme_get_g13_path): Ditto.
	(_gpgme_get_w32spawn_path): Ditto.

2013-07-31  Werner Koch  <wk@gnupg.org>

	doc: Add --binary option for the OUTPUT command of an uiserver.

2013-06-18  Werner Koch  <wk@gnupg.org>

	Add function gpgme_signers_count.
	* src/signers.c (gpgme_signers_count): New.
	* src/libgpgme.vers, src/gpgme.def: Add as external symbol.
	* src/gpgme.h.in: Add prototype.

2013-05-28  Werner Koch  <wk@gnupg.org>

	Release 1.4.2.
	* configure.ac: Set LT version to C21/A10/R0.

	Add convenience macro GPGME_PROTOCOL_OPENPGP.
	* src/gpgme.h.in (GPGME_PROTOCOL_OPENPGP): New.

2013-05-23  Werner Koch  <wk@gnupg.org>

	w32: Fix installing of .def file.
	* src/Makefile.am (install-def-file): Create libdir first.

	Fix libtool 2.4.2 to correctly detect .def files.
	* build-aux/ltmain.sh (sed_uncomment_deffile): New.
	(orig_export_symbols): Uncomment def file before testing for EXPORTS.
	* m4/libtool.m4: Do the same for the generated code.

2013-05-22  Werner Koch  <wk@gnupg.org>

	Support --no-encrypt-to also with gpgme_op_encrypt_sign.
	* src/engine-gpg.c (gpg_encrypt_sign): Support the
	GPGME_ENCRYPT_NO_ENCRYPT_TO flag.

2013-05-22  Werner Koch  <wk@gnupg.org>
	    Kyle L. Huff  <g10bts@curetheitch.com>

	Allow symmetric encryption with gpgme_op_encrypt_sign.
	* src/encrypt-sign.c (encrypt_sym_status_handler): New.
	(encrypt_sign_start): Handle recp == NULL case.
	* src/engine-gpg.c (gpg_encrypt_sign): Implement symmetric encryption.
	* tests/gpg/t-encrypt-sign.c (main): Add a test case for this.

2013-05-22  Werner Koch  <wk@gnupg.org>

	gpgme-tool: Allow for symmetric encryption.
	* src/gpgme-tool.c (gt_sign_encrypt): Pass NULL for recp if no
	recipients are given.

	tests: Print auditlog in plain text format.
	* tests/gpgsm/t-verify.c (show_auditlog): Use plain text format.

2013-05-18  Werner Koch  <wk@gnupg.org>

	Improve C++ compatibility of previous patch.
	* src/gpgme.h.in: Move gpgme_sssize_t and gpgme_off_t typedefs into
	the extern "C" scope.

2013-05-16  Werner Koch  <wk@gnupg.org>

	Make definition of off_t robust against misbehaving w32 toolchains.
	* configure.ac (NEED__FILE_OFFSET_BITS): Change to define gpgme_off_t
	and gpgme_ssize_t.
	(API__OFF_T, API__SSIZE_T): New ac_subst.
	* src/gpgme.h.in: Replace all ssize_t and off_t by ac_subst macros.
	* src/assuan-support.c, src/ath-pthread.c, src/ath.c, src/ath.h
	* src/data-compat.c, src/data-fd.c, src/data-mem.c, src/data-stream.c
	* src/data-user.c, src/data.c, src/data.h, src/engine-gpgsm.c
	* src/engine-uiserver.c, src/gpgme-tool.c, src/gpgme.c: Replace off_t
	by gpgme_off_t and sszie_t by gpgme_ssize_t.
	* src/ath-pthread.c, src/ath.h: Include gpgme.h.

2013-05-11  Werner Koch  <wk@gnupg.org>

	w32: Change the way the I/O threads are cleaned up.
	* src/w32-io.c (reader_context_s, create_reader)
	(writer_context_s, create_writer): Rename STOPPED to CLOSE_EV.
	(reader, writer): Remove setting of STOPPED.  Wait for CLOSE_EV and
	then release the context.
	(destroy_reader, destroy_writer): Do not wait but set the CLOSE_EV.
	(kill_reader, kill_writer): Remove.
	(_gpgme_io_close): Add code from kill_reader and kill_writer.

2013-05-08  Werner Koch  <wk@gnupg.org>

	Fix hang in socket closing.
	* src/w32-io.c (destroy_reader): Call shutdown.
	(reader): Do not print an error in the shutdown case.

	Improve debug output of the I/O reader and writer.
	* src/w32-io.c (reader, writer): Also print file_sock.

2013-05-06  Werner Koch  <wk@gnupg.org>

	Simplify a debug code function.
	* src/debug.c (_gpgme_debug): Remove static space string.

2013-05-01  Werner Koch  <wk@gnupg.org>

	Release 1.4.1.
	* configure.ac: Bump LT version to C20/A9/R1.

	Disable fd-passing for Apple.
	* configure.ac: Disable fd-passing by default for Apple.

2013-04-30  Werner Koch  <wk@gnupg.org>

	Allow reading of long gpgconf output lines.
	* src/engine-gpgconf.c (gpgconf_read): Rewrite to allow for line
	lengths up to 64k.

2013-04-29  Werner Koch  <wk@gnupg.org>

	Fix for i686-w64-mingw32.
	* configure.ac (NEED__FILE_OFFSET_BITS): Do not define under Windows.

2013-02-26  Werner Koch  <wk@gnupg.org>

	Release 1.4.0.
	* configure.ac: Bump LT version to C20/A9/R0.

	Enable FD passing and thus building of the UI-server.
	* configure.ac: Make --enable-fd-passing the default.
	* src/engine-uiserver.c (_gpgme_engine_ops_uiserver): Syntax fix.

	w32: Hacks for building with 32 bit mingw64.
	* configure.ac (INSERT__TYPEDEFS_FOR_GPGME_H): Add hacks for 32 bit
	mingw64.
	* src/util.h [W32]: Include winsock2.h before windows to make mingw64
	happy.
	* src/w32-util.c (_WIN32_IE): Need to use 5.1 for mingw64.

	Improve missing libgpg-error reporting in configure.
	* configure.ac (NEED_GPG_ERROR_VERSION): New.  Improve reporting for
	missing libgpg-error.

	Change the various version numbers to the new scheme.
	* configure.ac: Rename my_foo variables to mym4_foo variables to make
	clear that they are processed by m4.
	(VERSION_NUMBER): New ac_subst.
	(AH_BOTTOM): Add CRIGHTBLURB macro.
	(BUILD_REVISION, BUILD_FILEVERSION, BUILD_TIMESTAMP): Change them to
	work similar to libgpg-error et al.
	* src/versioninfo.rc.in: Remove use of BUILD_NUMBER and get it in line
	with gpg-error et al.
	* src/version.c (cright_blurb): New.
	(gpgme_check_version_internal): Add magic to display the above
	information.
	* tests/t-version.c (main): Add option --verbose.

	Update GnuPG related m4 files.
	* m4/gpg-error.m4: Update from libgpg-error.
	* m4/libassuan.m4: Update from libassuan.

	Update helper scripts.
	* configure.ac: Use AC_CONFIG_AUX_DIR.  Remove args from
	AM_INIT_AUTOMAKE.  Replace AM_CONFIG_HEADER by AC_CONFIG_HEADER.
	* compile, config.guess, config.sub, depcomp, install-sh, ltmain.sh
	* mkinstalldirs, texinfo.texi: Move to build-aux/ and update from
	gnulib (c042abf).
	* build-aux/mdate-sh, build-aux/missing: Install via automake -a -c.
	Update autogen.sh for changed config dir.
	* autogen.sh: Adjust for scripts dir change.  Update W32 toolprefix
	list.

2013-02-25  Werner Koch  <wk@gnupg.org>

	Remove included gitlog-to-changelog.
	* build-aux/gitlog-to-changelog: Remove.
	* configure.ac (GITLOG_TO_CHANGELOG): Default to just
	gitlog-to-changelog.

2013-02-12  Werner Koch  <wk@gnupg.org>

	Add macro GPGME_VERSION_NUMBER.
	* src/gpgme.h.in (GPGME_VERSION_NUMBER): New.
	* configure.ac (my_version_major, my_version_minor)
	(my_version_micro): New m4 macros.
	(my_version): Build from new m4 macros.
	(VERSION_NUMBER): New ac_subst.

	Add public function gpgme_get_pinentry_mode.
	* src/gpgme.c (gpgme_get_pinentry_mode): New.

2013-02-07  Werner Koch  <wk@gnupg.org>

	gpgme_tool: Support GPG's new pinentry-mode.
	* src/gpgme-tool.c (log_error): Do not always print the error source.
	(gt_set_pinentry_mode): New.
	(server_passphrase_cb): New.
	(cmd_pinentry_mode): New.
	(register_commands): Add cmd_pinentry_mode.
	(options): Add option --gpg-binary.
	(struct args): Add field gpg-binary.
	(parse_options, main): Implement that option.

	Add public function gpgme_set_pinentry_mode.
	* src/gpgme.c (gpgme_set_pinentry_mode): New.
	* src/gpgme.h.in (gpgme_pinentry_t): New.
	(gpgme_set_pinentry_mode): New.
	* src/context.h (struct gpgme_context): Add field pinentry_mode.
	* src/engine-backend.h (struct engine_ops): Add field
	set_pinentry_mode.
	* src/engine-gpg.c (struct engine_gpg): Add field pinentry_mode.
	(build_argv): Implement pinentry_mode.
	(gpg_set_pinentry_mode): New.
	(_gpgme_engine_ops_gpg): Register gpg_set_pinentry_mode.

	Add public function gpgme_io_writen.
	* src/gpgme.c (gpgme_io_read): New.

2012-11-16  Werner Koch  <wk@gnupg.org>

	Improve parsing of the GIT revision number.
	* configure.ac (git_revision): Use git rev-parse.

	Fix non-portable use of chmod in autogen.sh.
	* autogen.sh: Remove option -c from chmod.

2012-11-15  Werner Koch  <wk@gnupg.org>

	Make _gpgme_encode_percent_string work for memory buffers.
	* src/conversion.c (D_gpgme_encode_percent_string): Remove stray
	semicolon.  Reported by Xi Wang.

2012-10-24  Werner Koch  <wk@gnupg.org>

	Make local variables configure hack more robust.
	* configure.ac (emacs_local_vars_begin): Use extra m4 quoting so that
	newer Emscasen won't take it up as Local Variables for this file.

	Fix ttyname problem on Android.
	* configure.ac: Define macro and conditional HAVE_ANDROID_SYSTEM.
	* m4/gnupg-ttyname.m4: Force use of replacement on Android.
	* src/ttyname_r.c: Ditto.

	tests: Adhere to the docs and call gpgme_check_version.
	* tests/t-engine-info.c: Call gpgme_check_version.

2012-10-19  Werner Koch  <wk@gnupg.org>

	Trace the use of GPG_ERR_INV_ENGINE.
	* src/debug.h: Include "gpgme.h"
	(_gpgme_trace_gpgme_error): New.
	(trace_gpg_error): New macro.  Use it in all files where we return
	GPG_ERR_INV_ENGINE; also "include debug.h" as needed.

	Avoid warning about initialized but not used variable.
	* src/engine-gpgsm.c (gpgsm_set_fd): Do not set DIR if not needed.

2012-10-11  Werner Koch  <wk@gnupg.org>

	gpgme-tool: Use membuf functions to build up strings.
	* src/gpgme-tool.c (clear_membuf, init_membuf, put_membuf)
	(put_membuf_str, get_membuf, peek_membuf): Add membuf functions.
	Take from GnuPG master's common/membuf.[ch] and patch for our use.
	(result_xml_escape): Rewrite using new functions.

	gpgme-tool: Change license from LPGLv2+ to GPLv3+
	* src/gpgme-tool.c: Change license notice.

2012-10-11  W. Trevor King  <wking@tremily.us>

	gpgme-tool: escape special characters in output XML data (<, >, and &).

	src/gpgme-tool.c (result_xml_escape_replacement, result_xml_escape):
	New.
	(result_xml_tag_data): Use result_xml_escape() to escape data.
	(result_add_error): Use unescaped < and >.

	gpgme-tool: Fix chain_id -> chain-id in KEYLIST XML.

	src/gpgme-tool.c (cmd_keylist): Use <chain-id> instead of <chain_id>.

2012-09-28  W. Trevor King  <wking@tremily.us>

	gpgme-tool: Return more detailed XML from KEYLIST.
	src/gpgme-tool.c (cmd_keylist): Convert output from a list of
	to more detailed XML.
	(xml_preamble1, xml_preamble2, xml_end): Make global.
	(result_add_protocol, result_add_validity): New functions for
	generating XML from GPGME types.
	(result_add_string): Treat NULL strings as "".
	(result_xml_tag_data): Make 'data' a 'const char' so we can use the
	value returned by gpgme_get_protocol_name directly.

	gpgme-tool: Initialize input_fd and output_fd.
	* src/gpgme-tool.c (gpgme_server): Initialize input_fd and output_fd.

2012-09-26  Werner Koch  <wk@gnupg.org>

	gpgme-tool: Fix handling of file descriptors.
	* src/gpgme-tool.c (server_reset_fds): Use close/CloseHandle instead
	of the assuan close functions.
	(_cmd_decrypt_verify, _cmd_sign_encrypt, cmd_verify, cmd_import)
	(cmd_export, cmd_genkey, cmd_getauditlog): Use SERVER object instead
	of assuan_get_*_fd functions.

2012-09-25  Werner Koch  <wk@gnupg.org>

	Document contribution rules.
	* doc/HACKING (License policy): New.
	* doc/DCO: New.
	* AUTHORS: Change maintainer address.

	Add gpgme_set_global_flag to help debugging.
	* src/gpgme.c (gpgme_set_global_flag): New.
	* src/gpgme.h.in (gpgme_set_global_flag): New.
	* src/gpgme.def, src/libgpgme.vers: Add new public function.
	* src/debug.c (envvar_override): New.:
	(_gpgme_debug_set_debug_envvar): New.
	(debug_init): Take ENVVAR_OVERRIDE in account.

2012-07-28  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>

	Add two recent contributors.

	Fix sign error in position calculation for mem_seek.
	* data-mem.c (mem_seek): Fix sign error in position calculation.

	Allow null context on gpgme_set_locale.
	* gpgme.c (gpgme_set_locale): Allow CTX to be a null pointer.

2012-07-13  Werner Koch  <wk@gnupg.org>

	Do not include the removed file status-table.h.
	* src/engine-uiserver.c: Remove status-table.h which is not anymore
	built.  Fixes bug#1412.
