aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* qt,doc: Fix typosikloecker/t7110-nested-bindings-packagesIngo Klöcker2024-06-111-2/+2
| | | | | * lang/qt/README: Fix typos. --
* Unify spelling of the name of the C++ bindings for GpgMEIngo Klöcker2024-06-1111-43/+44
| | | | | | | | | | | | | | | | | | * lang/cpp/README, lang/cpp/src/GpgmeppConfig-w32.cmake.in.in, lang/cpp/src/GpgmeppConfig.cmake.in.in, lang/cpp/src/GpgmeppConfigVersion.cmake.in, lang/cpp/src/Makefile.am, lang/cpp/tests/run-getkey.cpp, lang/cpp/tests/run-keylist.cpp, lang/cpp/tests/run-verify.cpp, lang/cpp/tests/run-wkdlookup.cpp, lang/qt/README: Replace GpgMEpp with GpgME++. * lang/cpp/src/GpgmeppConfig-w32.cmake.in.in, lang/cpp/src/GpgmeppConfig.cmake.in.in, lang/cpp/src/GpgmeppConfigVersion.cmake.in, lang/cpp/src/Makefile.am: Replace GPGME-CL (c&p error) with GpgME++. * lang/cpp/tests/Makefile.am: Replace GPGME with GPGME++. * lang/cpp/tests/run-getkey.cpp, lang/cpp/tests/run-keylist.cpp, lang/cpp/tests/run-verify.cpp: Replace QGpgME (c&p error) with GpgME++. --
* build,python: Support building Python bindings as nested packageIngo Klöcker2024-06-114-23/+50
| | | | | | | | | | | | | | | | | | | | | | * autogen-all.sh (packages): Add lang/python. * configure.ac: Add python to available languages if subdir exists. Add python to nested languages if enabled to generate corresponding make targets. Call configure script of nested python package recursively. * lang/python/configure.ac: Check if Python bindings are built as nested package and set GPGME_CFLAGS and GPGME_LIBS accordingly. * lang/python/setup.py.in: Define some variables where they are used first. Extract library directories from GPGME_LIBS variable similar to the extraction of include directories from GPGME_CFLAGS. Adjust library locations in case of win32 the same way as the include locations. Prefer gpgme.h in the include directories from GPGME_CFLAGS over the one in the prefix, so that the correct gpgme.h is taken in case of nested builds. -- This re-adds the ability to build the Python bindings together with gpgme with a single `configure && make` command (if building from git). GnuPG-bug-id: 7110
* build,qt: Support building Qt bindings as nested package of gpgmeIngo Klöcker2024-06-113-9/+44
| | | | | | | | | | | | | | | | * autogen-all.sh (packages): Add lang/qt. * configure.ac: Add qt to available languages if subdir exists. Add qt to nested languages if enabled to generate corresponding make targets. Call configure script of nested qt package recursively. * lang/qt/configure.ac: Check if qgpgme is built as nested package and set GPGME_CFLAGS, GPGME_LIBS, GPGMEPP_CFLAGS, and GPGMEPP_LIBS accordingly. -- This re-adds the ability to build the Qt bindings together with gpgme with a single `configure && make` command (if building from git). GnuPG-bug-id: 7110
* build,cpp: Support building C++ bindings as nested package of gpgmeIngo Klöcker2024-06-114-7/+164
| | | | | | | | | | | | | | | | | | | | | | | | * Makefile.am: Add variables languages, dist_languages, distcheck_languages, release_languages, sign_release_languages, distclean_languages. Add rules for nested language bindings. (distclean-local, dist-all, distcheck-all, release-all, sign-release-all): New rules. (.PHONY): Add all new rules. * autogen-all.sh: New. * configure.ac: Add cpp to available languages if subdir exists. Add cpp to nested languages if enabled to generate corresponding make targets. Call configure script of nested cpp package recursively. * lang/cpp/configure.ac: Check if gpgmepp is built as nested package and set GPGME_CFLAGS and GPGME_LIBS accordingly. -- This re-adds the ability to build the C++ bindings together with gpgme with a single `configure && make` command (if building from git). It also adds make targets for running dist, distcheck, release and sign-release for gpgme and all enabled nested languages with a single make command. GnuPG-bug-id: 7110
* build,python: Separate Python bindings from gpgmeIngo Klöcker2024-06-1150-139/+28005
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac: Remove "python" from available_languages and from default_languages. Remove checks for SWIG and available Python versions. Remove substitution of PYTHONS. Remove generation of files in lang/python. * lang/Makefile.am (DIST_SUBDIRS): Remove python. * lang/python/.gitignore, lang/python/AUTHORS, lang/python/COPYING, lang/python/COPYING.LESSER, lang/python/ChangeLog, lang/python/INSTALL, lang/python/NEWS, lang/python/autogen.rc, lang/python/autogen.sh, lang/python/configure.ac: New. * lang/python/Makefile.am (EXTRA_DIST): Add autogen.sh, autogen.rc. copystamp: Remove symbolic linking of gpgme's internal data.h header and of gpgme's config.h file. CLEANFILES: Remove cleaning of config.h and data.h. (RELEASE_ARCHIVE_SUFFIX, ACLOCAL_AMFLAGS, dist-hook, distcheck-hook, .PHONY, gen_start_date, gen-ChangeLog, RELEASE_NAME, release, sign-release): New (copied from top-level Makefile.am). * lang/python/build-aux/compile, lang/python/build-aux/config.guess, lang/python/build-aux/config.sub, lang/python/build-aux/depcomp, lang/python/build-aux/install-sh, lang/python/build-aux/libtool-patch.sed, lang/python/build-aux/ltmain.sh, lang/python/build-aux/missing: New. * m4/ax_pkg_swig.m4: Move to... * lang/python/m4/ax_pkg_swig.m4: ...here. * m4/ax_python_devel.m4: Move to... * lang/python/m4/ax_python_devel.m4: ...here. * m4/python.m4: Move to... * lang/python/m4/python.m4: ...here. * lang/python/m4/gpg-error.m4, lang/python/m4/gpgme.m4, lang/python/m4/libassuan.m4, lang/python/m4/libtool.m4, lang/python/m4/ltoptions.m4, lang/python/m4/ltsugar.m4, lang/python/m4/ltversion.m4, lang/python/m4/lt~obsolete.m4: New. * lang/python/setup.py.in: Remove code for in-tree builds. Initialize libs from @GPGME_LIBS@ instead of @GPGME_CONFIG_LIBS@. Initialize include_dirs and define_macros from @GPGME_CFLAGS@ instead of @GPGME_CONFIG_CFLAGS@. Look for gpgme.h in @prefix@/include and in include_dirs and '/usr/include'. * lang/python/tests/13CBE3758AFE42B5E5E2AE4CED27AFA455E3F87F, lang/python/tests/13CD0F3BDF24BE53FE192D62F18737256FF6E4FD, lang/python/tests/76F7E2B35832976B50A27A282D9B87E44577EB66, lang/python/tests/7A030357C0F253A5BBCD282FFC4E521B37558F5C, lang/python/tests/A0747D5F9425E6664F4FFBEED20FBCA79FDED2BD: New. * lang/python/tests/Makefile.am (test_srcdir): Remove. (TESTS_ENVIRONMENT): Remove adding .libs directory with gpgme library to LD_LIBRARYPATH. (private_keys): Use local copies instead of files from gpgme's tests. (EXTRA_DIST): Add new files. (clean-local): Call local copy of start-stop-agent script. (gpg-sample.stamp): Use local copies of private keys. (pubring-stamp): Use local copies of pubdemo.asc and secdemo.asc. (gpg-agent.conf): Use local copy of pinentry helper. * lang/python/tests/cipher-1.asc, lang/python/tests/cipher-2.asc, lang/python/tests/cipher-3.asc, lang/python/tests/cipher-no-sig.asc, lang/python/tests/pinentry, lang/python/tests/pubdemo.asc, lang/python/tests/pubkey-1.asc, lang/python/tests/secdemo.asc, lang/python/tests/seckey-1.asc, lang/python/tests/start-stop-agent: New. * lang/python/tests/support.py (make_filename): Adapt to changed path of test files. -- This makes building and distributing the Python bindings independent of the sources of gpgme. Many of the new files are copied from gpgme to make the Python bindings a self-contained package. A later commit re-adds the possibility to build the Python bindings as nested package together with gpgme. GnuPG-bug-id: 7110
* build,cpp: Separate C++ bindings from gpgmeIngo Klöcker2024-06-1135-90/+27328
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac: Remove definition and substitution of LIBGPGMEPP_LT_CURRENT, LIBGPGMEPP_LT_AGE, LIBGPGMEPP_LT_REVISION. Remove "cpp" from available_languages and from default_languages. Remove checks for C++ 11 and for support of visibility attribute. Remove substitution of GPGME_CPP_CFLAGS. Remove definition and substitution of GPGMEPP_PKGCONFIG_LIBS, GPGMEPP_PKGCONFIG_CFLAGS, GPGMEPP_PKGCONFIG_HOST. Remove generation of files in lang/cpp. * lang/Makefile.am (DIST_SUBDIRS): Remove cpp. * lang/cpp/.gitignore, lang/cpp/AUTHORS, lang/cpp/COPYING, lang/cpp/COPYING.LESSER, lang/cpp/COPYING.LIB, lang/cpp/ChangeLog, lang/cpp/INSTALL, lang/cpp/NEWS, lang/cpp/autogen.rc, lang/cpp/autogen.sh, lang/cpp/configure.ac: New. * lang/cpp/Makefile.am (EXTRA_DIST): Add autogen.sh, autogen.rc, VERSION. (RELEASE_ARCHIVE_SUFFIX, ACLOCAL_AMFLAGS, dist-hook, distcheck-hook, .PHONY, gen_start_date, gen-ChangeLog, RELEASE_NAME, release, sign-release): New (copied from top-level Makefile.am). * lang/cpp/build-aux/compile, lang/cpp/build-aux/config.guess, lang/cpp/build-aux/config.sub, lang/cpp/build-aux/depcomp, lang/cpp/build-aux/install-sh, lang/cpp/build-aux/libtool-patch.sed, lang/cpp/build-aux/ltmain.sh, lang/cpp/build-aux/missing: New. * m4/ax_cxx_compile_stdcxx.m4: Move to... * lang/cpp/m4/ax_cxx_compile_stdcxx.m4: ...here. * m4/ax_gcc_func_attribute.m4: Move to... * lang/cpp/m4/ax_gcc_func_attribute.m4: ...here. * lang/cpp/m4/gpg-error.m4, lang/cpp/m4/gpgme.m4, lang/cpp/m4/libtool.m4, lang/cpp/m4/ltoptions.m4, lang/cpp/m4/ltsugar.m4, lang/cpp/m4/ltversion.m4, lang/cpp/m4/lt~obsolete.m4: New. * lang/cpp/src/GpgmeppConfig-w32.cmake.in.in, lang/cpp/src/GpgmeppConfig.cmake.in.in: Remove @LIBASSUAN_LIBS@ from INTERFACE_LINK_LIBRARIES of Gpgmepp target. * lang/cpp/src/Makefile.am (AM_CPPFLAGS): Replace include paths of gpgme relative to top_builddir with @GPGME_CFLAGS@. Remove @LIBASSUAN_CFLAGS@. (libgpgmepp_la_LIBADD): Replace relative paths of libgpgme.la with @GPGME_LIBS@. Remove @LIBASSUAN_LIBS@. * lang/cpp/tests/Makefile.am (LDADD): Replace relative paths of libgpgme.la with @GPGME_LIBS@. (AM_CPPFLAGS): Replace include paths of gpgme relative to top_builddir with @GPGME_CFLAGS@. Remove @LIBASSUAN_CFLAGS@. Remove -DTOP_SRCDIR. -- This makes building and distributing GpgME++ independent of the sources of gpgme. Many of the new files are copied from gpgme to make GpgME++ a self-contained package. A later commit re-adds the possibility to build GpgME++ as nested package together with gpgme. GnuPG-bug-id: 7110
* cpp: Don't include config.hIngo Klöcker2024-06-1139-156/+0
| | | | | | | | | * lang/cpp/src/*.cpp, lang/cpp/tests/*.cpp: Remove config.h include. -- The C++ binding sources don't need anything from config.h. GnuPG-bug-id: 7110
* build,qt: Separate Qt bindings from gpgmeIngo Klöcker2024-06-1140-235/+28603
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac: Remove definition and substitution of LIBQGPGME_LT_CURRENT, LIBQGPGME_LT_AGE, LIBQGPGME_LT_REVISION. Remove "qt qt5 qt6" from available_languages. Remove "qt" from default_languages. Remove options --enable-reduce-relocations and --enable-no-direct-extern-access. Remove checks for pkg-config, Qt 5, Qt 6 and C++ 17. Remove adding visibility flag to GPGME_QT5_CFLAGS and GPGME_QT6_CFLAGS. Remove definition of conditionals WANT_QT5 and WANT_QT6. Remove checks for doxygen and dot. Remove generation of files in lang/qt. * lang/Makefile.am (DIST_SUBDIRS): Remove qt. * lang/qt/.gitignore, lang/qt/AUTHORS, lang/qt/COPYING, lang/qt/ChangeLog, lang/qt/INSTALL, lang/qt/NEWS, lang/qt/autogen.rc, lang/qt/autogen.sh, lang/qt/configure.ac: New. * lang/qt/Makefile.am (EXTRA_DIST): Add autogen.sh, autogen.rc, VERSION. (RELEASE_ARCHIVE_SUFFIX, ACLOCAL_AMFLAGS, dist-hook, distcheck-hook, .PHONY, gen_start_date, gen-ChangeLog, RELEASE_NAME, release, sign-release): New (copied from top-level Makefile.am). * lang/qt/build-aux/compile, lang/qt/build-aux/config.guess, lang/qt/build-aux/config.sub, lang/qt/build-aux/depcomp, lang/qt/build-aux/install-sh, lang/qt/build-aux/libtool-patch.sed, lang/qt/build-aux/ltmain.sh, lang/qt/build-aux/missing: New. * lang/qt/doc/Doxyfile.in (INPUT): Update path. * m4/ax_check_compile_flag.m4: Move to... * lang/qt/m4/ax_check_compile_flag.m4: ...here * m4/pkg.m4: Move to... * lang/qt/m4/pkg.m4: ...here * m4/qt5.m4: Move to... * lang/qt/m4/qt5.m4: ...here * m4/qt6.m4: Move to... * lang/qt/m4/qt6.m4: ...here * lang/qt/m4/ax_cxx_compile_stdcxx.m4, lang/qt/m4/ax_gcc_func_attribute.m4, lang/qt/m4/gpg-error.m4, lang/qt/m4/gpgme.m4, lang/qt/m4/gpgmepp.m4, lang/qt/m4/libtool.m4, lang/qt/m4/ltoptions.m4, lang/qt/m4/ltsugar.m4, lang/qt/m4/ltversion.m4, lang/qt/m4/lt~obsolete.m4: New. * lang/qt/src/Makefile.am (AM_CPPFLAGS): Replace include paths of gpgmepp and gpgme relative to top_builddir with @GPGMEPP_CFLAGS@ and @GPGME_CFLAGS@. (libqgpgme_la_LIBADD, libqgpgmeqt6_la_LIBADD): Replace relative paths of libgpgmepp.la and libgpgme.la with @GPGMEPP_LIBS@ and @GPGME_LIBS@. * lang/qt/tests/Makefile.am (EXTRA_DIST): Add new files. (LDADD): Replace relative paths of libgpgmepp.la and libgpgme.la with @GPGMEPP_LIBS@ and @GPGME_LIBS@. (AM_CPPFLAGS): Replace include paths of gpgmepp and gpgme relative to top_builddir with @GPGMEPP_CFLAGS@ and @GPGME_CFLAGS@. (pubring-stamp): Use local copies of pubdemo.asc and secdemo.asc. * lang/qt/tests/pubdemo.asc, lang/qt/tests/secdemo.asc, lang/qt/tests/start-stop-agent: New. -- This makes building and distributing QGpgME independent of the sources of gpgme. Many of the new files are copied from gpgme to make QGpgME a self-contained package. A later commit re-adds the possibility to build QGpgME as nested package together with gpgme. GnuPG-bug-id: 7110
* build: Allow autoheader to be skippedIngo Klöcker2024-06-101-2/+5
| | | | | | | | | | | * autogen.sh: If skip_autoheader is set via autogen.rc then do not run autoheader. -- This makes it possible to skip running autoheader for packages which don't need a config.h header. GnuPG-bug-id: 7110
* build: Make autogen.sh --find-version work for nested packagesIngo Klöcker2024-06-101-3/+17
| | | | | | | | | | | * autogen.sh: If package_subdir is set then look for .git in the root of the package containing the nested package in package_subdir. -- This makes it possible to use autogen.sh --find-version from configure.ac files in nested packages. GnuPG-bug-id: 7110
* qt: Don't include config.hIngo Klöcker2024-06-1096-384/+0
| | | | | | | | | * lang/qt/src/*.cpp, lang/qt/tests/*.cpp: Remove config.h include. -- The Qt binding sources don't need anything from config.h. GnuPG-bug-id: 7110
* cpp: Add pkgconfig file for gpgmeppIngo Klöcker2024-06-103-3/+43
| | | | | | | | | | | | | | * configure.ac: Add substitutions GPGMEPP_PKGCONFIG_LIBS, GPGMEPP_PKGCONFIG_CFLAGS, GPGMEPP_PKGCONFIG_HOST. Apply them. Configure gpgmepp.pc file. * lang/cpp/src/Makefile.am (pkgconfigdir, pkgconfig_DATA): New. (EXTRA_DIST): Add gpgmepp.pc.in. * lang/cpp/src/gpgmepp.pc.in: New. -- This pkgconfig file will be used by qgpgme to find gpgmepp. GnuPG-bug-id: 7110
* qt: Always include C++ binding headers with gpgme++/ prefixIngo Klöcker2024-06-10131-415/+239
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lang/qt/src/Makefile.am, lang/qt/tests/Makefile.am (AM_CPPFLAGS): Add builddir instead of srcdir of C++ bindings as include path. * lang/qt/src/changeexpiryjob.cpp, lang/qt/src/changeexpiryjob.h, lang/qt/src/changeownertrustjob.h, lang/qt/src/dataprovider.cpp, lang/qt/src/dataprovider.h, lang/qt/src/debug.cpp, lang/qt/src/decryptverifyarchivejob.cpp, lang/qt/src/decryptverifyarchivejob.h, lang/qt/src/encryptarchivejob.cpp, lang/qt/src/encryptarchivejob.h, lang/qt/src/encryptjob.h, lang/qt/src/encryptjob_p.h, lang/qt/src/filelistdataprovider.cpp, lang/qt/src/filelistdataprovider.h, lang/qt/src/hierarchicalkeylistjob.h, lang/qt/src/importjob.cpp, lang/qt/src/importjob.h, lang/qt/src/importjob_p.h, lang/qt/src/job.h, lang/qt/src/keyformailboxjob.h, lang/qt/src/keylistjob.h, lang/qt/src/listallkeysjob.h, lang/qt/src/multideletejob.cpp, lang/qt/src/qgpgmeaddexistingsubkeyjob.cpp, lang/qt/src/qgpgmeadduseridjob.cpp, lang/qt/src/qgpgmebackend.cpp, lang/qt/src/qgpgmechangeexpiryjob.cpp, lang/qt/src/qgpgmechangeownertrustjob.cpp, lang/qt/src/qgpgmechangepasswdjob.cpp, lang/qt/src/qgpgmedecryptjob.cpp, lang/qt/src/qgpgmedecryptjob.h, lang/qt/src/qgpgmedecryptverifyarchivejob.cpp, lang/qt/src/qgpgmedecryptverifyarchivejob.h, lang/qt/src/qgpgmedecryptverifyjob.cpp, lang/qt/src/qgpgmedecryptverifyjob.h, lang/qt/src/qgpgmedeletejob.cpp, lang/qt/src/qgpgmedownloadjob.cpp, lang/qt/src/qgpgmeencryptarchivejob.cpp, lang/qt/src/qgpgmeencryptarchivejob.h, lang/qt/src/qgpgmeencryptjob.cpp, lang/qt/src/qgpgmeencryptjob.h, lang/qt/src/qgpgmeexportjob.cpp, lang/qt/src/qgpgmeimportfromkeyserverjob.cpp, lang/qt/src/qgpgmeimportfromkeyserverjob.h, lang/qt/src/qgpgmeimportjob.cpp, lang/qt/src/qgpgmeimportjob.h, lang/qt/src/qgpgmekeyformailboxjob.h, lang/qt/src/qgpgmekeygenerationjob.cpp, lang/qt/src/qgpgmekeygenerationjob.h, lang/qt/src/qgpgmekeylistjob.cpp, lang/qt/src/qgpgmekeylistjob.h, lang/qt/src/qgpgmelistallkeysjob.cpp, lang/qt/src/qgpgmelistallkeysjob.h, lang/qt/src/qgpgmenewcryptoconfig.cpp, lang/qt/src/qgpgmenewcryptoconfig.h, lang/qt/src/qgpgmequickjob.cpp, lang/qt/src/qgpgmereceivekeysjob.h, lang/qt/src/qgpgmerefreshsmimekeysjob.cpp, lang/qt/src/qgpgmerefreshsmimekeysjob.h, lang/qt/src/qgpgmerevokekeyjob.cpp, lang/qt/src/qgpgmesetprimaryuseridjob.cpp, lang/qt/src/qgpgmesignarchivejob.cpp, lang/qt/src/qgpgmesignarchivejob.h, lang/qt/src/qgpgmesignencryptarchivejob.cpp, lang/qt/src/qgpgmesignencryptarchivejob.h, lang/qt/src/qgpgmesignencryptjob.cpp, lang/qt/src/qgpgmesignencryptjob.h, lang/qt/src/qgpgmesignjob.cpp, lang/qt/src/qgpgmesignjob.h, lang/qt/src/qgpgmesignkeyjob.cpp, lang/qt/src/qgpgmetofupolicyjob.cpp, lang/qt/src/qgpgmeverifydetachedjob.cpp, lang/qt/src/qgpgmeverifydetachedjob.h, lang/qt/src/qgpgmeverifyopaquejob.cpp, lang/qt/src/qgpgmeverifyopaquejob.h, lang/qt/src/qgpgmewkdlookupjob.cpp, lang/qt/src/qgpgmewkdrefreshjob.cpp, lang/qt/src/qgpgmewkdrefreshjob.h, lang/qt/src/qgpgmewkspublishjob.cpp, lang/qt/src/quickjob.h, lang/qt/src/signarchivejob.cpp, lang/qt/src/signarchivejob.h, lang/qt/src/signencryptarchivejob.cpp, lang/qt/src/signencryptarchivejob.h, lang/qt/src/signencryptjob.h, lang/qt/src/signencryptjob_p.h, lang/qt/src/signjob.h, lang/qt/src/signjob_p.h, lang/qt/src/threadedjobmixin.cpp, lang/qt/src/threadedjobmixin.h, lang/qt/src/tofupolicyjob.h, lang/qt/src/util.cpp, lang/qt/src/wkdlookupresult.cpp, lang/qt/src/wkdlookupresult.h, lang/qt/src/wkdrefreshjob_p.h, lang/qt/tests/run-decryptverifyarchivejob.cpp, lang/qt/tests/run-decryptverifyjob.cpp, lang/qt/tests/run-encryptarchivejob.cpp, lang/qt/tests/run-encryptjob.cpp, lang/qt/tests/run-exportjob.cpp, lang/qt/tests/run-importjob.cpp, lang/qt/tests/run-keyformailboxjob.cpp, lang/qt/tests/run-receivekeysjob.cpp, lang/qt/tests/run-refreshkeysjob.cpp, lang/qt/tests/run-signarchivejob.cpp, lang/qt/tests/run-signjob.cpp, lang/qt/tests/run-verifydetachedjob.cpp, lang/qt/tests/run-verifyopaquejob.cpp, lang/qt/tests/run-wkdrefreshjob.cpp, lang/qt/tests/t-addexistingsubkey.cpp, lang/qt/tests/t-changeexpiryjob.cpp, lang/qt/tests/t-config.cpp, lang/qt/tests/t-decryptverify.cpp, lang/qt/tests/t-encrypt.cpp, lang/qt/tests/t-import.cpp, lang/qt/tests/t-keylist.cpp, lang/qt/tests/t-keylocate.cpp, lang/qt/tests/t-ownertrust.cpp, lang/qt/tests/t-remarks.cpp, lang/qt/tests/t-revokekey.cpp, lang/qt/tests/t-setprimaryuserid.cpp, lang/qt/tests/t-support.cpp, lang/qt/tests/t-support.h, lang/qt/tests/t-tofuinfo.cpp, lang/qt/tests/t-trustsignatures.cpp, lang/qt/tests/t-various.cpp, lang/qt/tests/t-verify.cpp, lang/qt/tests/t-wkdlookup.cpp, lang/qt/tests/t-wkspublish.cpp: Include GpgME++ headers with gpgme++/ prefix. -- This prepares the Qt bindings for building them separately from the C++ bindings. GnuPG-bug-id: 7110
* build,cpp: Create forwarding headers in a gpgme++ folderIngo Klöcker2024-06-101-1/+12
| | | | | | | | | | | | | | | * lang/cpp/src/Makefile.am (copied_headers): New. (build rule for all copied headers): New. (BUILT_SOURCES): New. (CLEANFILES): Add copied_headers. -- The forwarding headers make it easier to use the headers from the Qt bindings when building them against the built but not installed C++ bindings because we can always include the C++ headers with gpgme++/ prefix. GnuPG-bug-id: 7110
* qt: Align license of some Makefiles with license of other MakefilesIngo Klöcker2024-06-102-24/+26
| | | | | | | | | | * lang/qt/doc/Makefile.am, lang/qt/tests/Makefile.am: Change license from LGPL to GPL. -- Both files are part of QGpgME (as lang/qt/Makefile.am and lang/qt/src/Makefile.am). Hence, they should be licensed as other parts of QGpgME.
* qt: Fix license headers of MakefilesIngo Klöcker2024-06-102-15/+15
| | | | | | | | | | * lang/qt/Makefile.am, lang/qt/src/Makefile.am: Files are part of QGpgme. Fix wrong package name (GPGME-CL -> QGpgME). Replace references to LGPL with references to GPL. -- The files were already licensed under the GPL but the license headers contained multiple (copy&paste?) errors.
* qt: Fix license headers of CMake config filesIngo Klöcker2024-06-106-18/+18
| | | | | | | | | | | | | | | | * lang/qt/src/QGpgmeConfig-w32.cmake.in.in, lang/qt/src/QGpgmeConfig.cmake.in.in, lang/qt/src/QGpgmeConfigVersion.cmake.in: Files are part of QGpgME. Fix copy&paste error (GPGME-CL -> QGpgME). Fix reference to license to check for details. * lang/qt/src/QGpgmeQt6Config-w32.cmake.in.in, lang/qt/src/QGpgmeQt6Config.cmake.in.in, lang/qt/src/QGpgmeQt6ConfigVersion.cmake.in: Files are part of QGpgME. Fix reference to license to check for details. -- The files were already licensed under the GPL but the license headers contained multiple (copy&paste?) errors.
* qt: Fix license headers of dataprovider.*Ingo Klöcker2024-06-102-30/+30
| | | | | | | | | * lang/qt/src/dataprovider.cpp, lang/qt/src/dataprovider.h: Change license header from LGPL to GPL. -- QGpgME is released under the GPL. As part of QGpgME these files (that were originally licensed under the LGPL) are released under the GPL.
* cpp: Remove commented out and disabled codeIngo Klöcker2024-06-102-156/+0
| | | | | | * lang/cpp/src/configuration.cpp: Remove disabled, abandoned code. * lang/cpp/src/context.cpp: Remove commented out, obsolete code. --
* doc: Extend description for GPGME_CREATE_ADSKWerner Koch2024-06-051-1/+4
| | | | --
* core,w32: Pass file names with forward slashes to gpg and gpgtarIngo Klöcker2024-06-043-29/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | src/conversion.c, src/util.h (_gpgme_replace_backslashes): New. src/engine-gpg.c (_add_arg): Add argument file_name. On Windows, replace backslashes in file name arguments with forward slashes. (add_arg_ext, add_arg_with_locp, add_arg, add_arg_pfx, add_gpg_arg, add_gpg_arg_with_value, add_arg_len): Adjust call of _add_arg. (add_file_name_arg, add_file_name_arg_len, add_gpg_arg_with_file_name): New. (add_file_name_arg_or_data): Call add_file_name_arg for file name. (gpg_new): Call add_gpg_arg_with_file_name for home directory. (gpg_decrypt): Call add_file_name_arg for output directory and output file name. (append_args_from_recipients_string): Call add_file_name_arg_len for recipients file name. (gpg_encrypt): Call add_file_name_arg for output file name, base directory and input file name. Call add_gpg_arg_with_file_name to set file name stored in message. (gpg_encrypt_sign): Call add_file_name_arg for output file name, base directory and input file name. Call add_gpg_arg_with_file_name to set file name stored in message. (gpg_sign): Call add_file_name_arg for output file name, base directory and input file name. Call add_gpg_arg_with_file_name to set file name stored in message. (gpg_verify): Call add_file_name_arg for output directory and output file name. -- By passing all file names with forward slashes to gpg and gpgtar we avoid problems caused by the quoting of backslashes. GnuPG-bug-id: 7141
* build,python: Fix make distcheck for Python 3.9+Ingo Klöcker2024-05-291-2/+6
| | | | | | | | | | | * lang/python/Makefile.am (uninstall-local): Remove installed .egg folders. -- Python 3.9+ install the module into a gpg-*.egg folder instead of in "gpg" with accompanying gpg-*.egg-info file. Moreover, Python 3.9+ normalize version numbers, e.g. the version 1.24.0_beta576 is normalized as 1.24.0b576.
* build,python: Remove support for Python 3.4, 3.5, 3.7Ingo Klöcker2024-05-291-2/+1
| | | | | | | | * configure.ac: Don't look for Python 3.4, 3.5, 3.7 anymore. -- This complements the previous commit where those versions where removed from python.m4.
* build,python: Build Python bindings without distutilsBen Greiner2024-05-295-13/+18
| | | | | | | | | | | | | | | | | | | | | * m4/python.m4: Add python3.12 and 3.11 as valid interpreters, remove EOL 3.4, 3.5, 3.7 (keep 3.6 because some distributions still ship and maintain it). * lang/python/Makefile.am (clean-local): Remove dist and gpg.egg-info created by Python 3.9+ on make install. * lang/python/setup.py.in: switch from distutils to setuptools where possible, remove obsolete and deprecated -py3 option of swig, add classifiers up to 3.12, remove 3.4, 3.5, 3.7. * lang/python/doc/src/gpgme-python-howto.org: replace distutils with setuptools * lang/python/examples/howto/advanced/cython/setup.py: replace distutils with setuptools -- This fixes building the Python bindings for Python 3.12 where distutils has been removed. Based on D545
* tests: Add new files to distributionIngo Klöcker2024-05-241-0/+2
| | | | | | | | * tests/json/Makefile.am (EXTRA_DIST): Add files added with f2575b63. -- Fixes-commit: f2575b6313aeb23d867682856f7842704786349e GnuPG-bug-id: 7118
* cpp: Fix includes in public headersIngo Klöcker2024-05-2413-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | * lang/cpp/src/defaultassuantransaction.h, lang/cpp/src/gpgadduserideditinteractor.h, lang/cpp/src/gpgagentgetinfoassuantransaction.h, lang/cpp/src/gpggencardkeyinteractor.h, lang/cpp/src/gpgsetexpirytimeeditinteractor.h, lang/cpp/src/gpgsetownertrusteditinteractor.h, lang/cpp/src/gpgsignkeyeditinteractor.h, lang/cpp/src/interfaces/assuantransaction.h, lang/cpp/src/interfaces/dataprovider.h, lang/cpp/src/interfaces/statusconsumer.h, lang/cpp/src/scdgetinfoassuantransaction.h, lang/cpp/src/statusconsumerassuantransaction.h, lang/cpp/src/trustitem.h: Use #include "foo.h" instead of #include <foo.h> for own headers. -- This fixes the build for projects that include the headers (as intended) with #include <gpgme++/...> and that don't add the gpgme++ subdirectory to the list of include paths for the compiler. GnuPG-bug-id: 7110
* Merge branch 'ikloecker/t7118-revkeys'Ingo Klöcker2024-05-2417-3/+476
|\
| * cpp: Add information about revocation keys to Keyikloecker/t7118-revkeysIngo Klöcker2024-05-215-1/+170
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lang/cpp/src/gpgmefw.h (gpgme_revocation_key_t): New forward declaration. * lang/cpp/src/key.cpp, lang/cpp/src/key.h (class Key): New methods revocationKey, numRevocationKeys, revocationKeys. (class RevocationKey): New. (swap): New overload for RevocationKey. (operator<<): New overload for RevocationKey. * lang/cpp/src/key.cpp (operator<<): Add information about revocation keys to the output stream for Key. * lang/cpp/tests/run-keylist.cpp (main): Don't output Key if nextKey failed, e.g. at the end of the key listing. -- GnuPG-bug-id: 7118
| * json: Add information about revocation keys to key list resultIngo Klöcker2024-05-216-1/+155
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/gpgme-json.c (revocation_key_to_json): New. (key_to_json): Add list of revocation keys. * tests/json/Makefile.am (pubring-stamp): Import new pub key. * tests/json/key-with-revokers.asc: New. * tests/json/t-json.c (tests): Add "t-keylist-revokers". * tests/json/t-keylist-revokers.in.json, tests/json/t-keylist-revokers.in.json: New. -- GnuPG-bug-id: 7118
| * core: Add information about revocation keys to keysIngo Klöcker2024-05-217-1/+151
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/gpgme.h.in (struct _gpgme_revocation_key, gpgme_revocation_key_t): New. (struct _gpgme_key): Add fields 'revkeys', '_last_revkey'. * src/key.c (_gpgme_key_add_rev_key): New. (gpgme_key_unref): Free revkeys. * src/keylist.c (keylist_colon_handler): Parse rvk lines. * src/ops.h (_gpgme_key_add_rev_key): New. * tests/run-keylist.c (main): Print revocation key info. -- GnuPG-bug-id: 7118
* | qt,cpp: Implement adding ADSKs to existing keysTobias Fella2024-05-225-0/+28
| | | | | | | | | | | | | | | | * lang/cpp/src/context.cpp: Add functions for adding ADSKs. * lang/cpp/src/context.h: Ditto. * lang/qt/src/qgpgmequickjob.cpp: Add implementation of ADSK job. * lang/qt/src/qgpgmequickjob.h: Ditto. * lang/qt/src/quickjob.h: Add job for adding ADSKs.
* | core: Implement adding ADSKs through gpgme_createsubkeyTobias Fella2024-05-225-4/+88
|/ | | | | | | | | | | | | | | * src/engine-gpg.c: Add and use function for adding ADSKs. * src/genkey.c: Prevent error due to no status line. * src/gpgme.h.in: Add flag GPGME_CREATE_ADSK * doc/gpgme.texi: Add documentation for ADSKs * tests/run-genkey.c: Add test for adding ADSKs -- This adds the ability to add ADSKs through the gpgme_createsubkey interface. The function must be called with NULL userid, the ADSK fingerprint in algo and the GPGME_CREATE_ADSK flag.
* tests: Fix segv in t-json.cWerner Koch2024-05-211-1/+1
| | | | | * tests/json/t-json.c (test_contains): Avoid calling recusivly with no child.
* tests: Avoid some compiler warnings.Werner Koch2024-05-212-3/+25
| | | | | | | | | | | * tests/gpg/t-support.h (fail_with_syserr): New. (check_data): Use it to avoid compiler warnings. * tests/run-support.h (fail_with_syserr): New. -- I don't think that there is a way to tell gcc that gpgme_err_code_from_errno will never return 0. Thus we better use a different macro.
* qt: Avoid bogus stringop-overread warningIngo Klöcker2024-05-211-2/+1
| | | | | | | | | * lang/qt/src/threadedjobmixin.cpp (_detail::audit_log_as_html): Use QByteArray overload of QString::fromUtf8. -- There's no need to make the code more complicated than necessary. Unless we want to provoke weird compiler warnings. :-)
* qt: Fix warning about missing returnIngo Klöcker2024-05-211-1/+2
| | | | | | | | | * lang/qt/src/qgpgmeexportjob.cpp (ExportJob::exec): Return a value and remove unused argument names. -- ExportJob::exec is never executed because its virtual overload is always used. Therefore it doesn't matter what value we return.
* core: speedup gpgme_get_keyWerner Koch2024-05-213-4/+11
| | | | | | | * src/engine.c (_gpgme_set_engine_info): Change engine_get_version. -- GnuPG-bug-id: 6369
* m4: Update libassuan.m4 from master.NIIBE Yutaka2024-05-171-2/+89
| | | | | | | | * m4/libassuan.m4: Update. -- Signed-off-by: NIIBE Yutaka <[email protected]>
* Require at least libgpg-error 1.47Ingo Klöcker2024-05-161-1/+1
| | | | | | | | | | * configure.ac (NEED_GPG_ERROR_VERSION): Require 1.47. -- Libgpg-error 1.47 has been released more than 1 year ago and we use a new error code defined in this version. GnuPG-bug-id: 6971
* gpgme.m4: Set $host correctly always.NIIBE Yutaka2024-05-161-2/+3
| | | | | | | | | | * src/gpgme.m4 (AM_PATH_GPGME): Add AC_CANONICAL_HOST. -- GnuPG-bug-id: 7114 Reported-by: Andreas Metzler Signed-off-by: NIIBE Yutaka <[email protected]>
* tests: Fix test after changed behavior of gpgme_op_verifyIngo Klöcker2024-05-151-6/+7
| | | | | | | | | | | * tests/gpg/t-verify.c (main): Change assertion of test. -- The change introduced with 1dc44b7c makes gpg abort the verification of a clear-signed message if it encounters garbage following the signed data. We have to adapt the test to this change. GnuPG-bug-id: 6907
* doc: Update use of Autoconf with PKG_CHECK_MODULES.NIIBE Yutaka2024-05-141-4/+10
| | | | | | -- Signed-off-by: NIIBE Yutaka <[email protected]>
* gpgme.m4: Update _AM_PATH_GPGRT_CONFIG macro from gpg-error.m4.NIIBE Yutaka2024-05-141-7/+5
| | | | | | | | * src/gpgme.m4 (_AM_PATH_GPGRT_CONFIG): Update. -- Signed-off-by: NIIBE Yutaka <[email protected]>
* cpp: Handle smart card op failure status messagesIngo Klöcker2024-04-051-0/+36
| | | | | | | | | | | | | | | * lang/cpp/src/editinteractor.cpp (parse_sc_op_failure): New. (CallbackHelper::edit_interactor_callback_impl): Parse failure code on GPGME_STATUS_SC_OP_FAILURE status. (sc_op_failure_to_error): New. -- This converts a SC_OP_FAILURE status message logged by gpg to a corresponding error. Unfortunately, GPG_ERR_BAD_PIN and GPG_ERR_BAD_RESET_CODE are mapped to the same SC_OP_FAILURE code, so that we had to choose one. GnuPG-bug-id: 6971
* Qt: Fix windows build of new jobsAndre Heinecke2024-03-136-7/+7
| | | | | -- See git log for changes.
* core: Check STATUS_FAILURE in import operations.Ingo Klöcker2024-03-111-0/+14
| | | | | | | | * src/import.c (op_data_t): Add failure_code. (_gpgme_import_status_handler): Set it. Return it on EOF. -- GnuPG-bug-id: 7036
* qt: Add function for synchronously executing ExportJobTobias Fella2024-01-223-0/+21
| | | | | | | | | | * lang/qt/src/exportjob: Add exec function. * lang/qt/src/qgpgmeexportjob.cpp: Implement exec function. * lang/qt/src/qgpgmeexportjob.h: Override exec function. -- GnuPG-Bug-Id: 6893
* qt: Remove superfluous virtual overrides and member variablesIngo Klöcker2024-01-1929-145/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lang/qt/src/qgpgmeaddexistingsubkeyjob.cpp (QGpgMEAddExistingSubkeyJob::exec): Remove call of resultHook. * lang/qt/src/qgpgmedecryptjob.cpp (QGpgMEDecryptJob::exec): Remove call of resultHook. (QGpgMEDecryptJob::resultHook): Remove. * lang/qt/src/qgpgmedecryptjob.h (QGpgMEDecryptJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmedecryptverifyjob.cpp (QGpgMEDecryptVerifyJob::exec): Remove call of resultHook. (QGpgMEDecryptVerifyJob::resultHook): Remove. * lang/qt/src/qgpgmedecryptverifyjob.h (QGpgMEDecryptVerifyJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmeencryptjob.cpp (QGpgMEEncryptJob::exec): Remove call of resultHook. (QGpgMEEncryptJob::resultHook): Remove. * lang/qt/src/qgpgmeencryptjob.h (QGpgMEEncryptJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmegpgcardjob.cpp (QGpgMEGpgCardJob::exec): Remove call of resultHook. * lang/qt/src/qgpgmeimportfromkeyserverjob.cpp (QGpgMEImportFromKeyserverJob::exec): Remove call of resultHook. (QGpgMEImportFromKeyserverJob::resultHook): Remove. * lang/qt/src/qgpgmeimportfromkeyserverjob.h (QGpgMEImportFromKeyserverJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmeimportjob.cpp (QGpgMEImportJob::exec): Remove call of resultHook. (QGpgMEImportJob::resultHook): Remove. * lang/qt/src/qgpgmeimportjob.h (QGpgMEImportJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmekeyformailboxjob.cpp (QGpgMEKeyForMailboxJob::exec): Remove call of resultHook. * lang/qt/src/qgpgmekeylistjob.cpp (QGpgMEKeyListJob::QGpgMEKeyListJob): Remove initialization of mResult. (QGpgMEKeyListJob::resultHook): Do not set (removed) mResult. * lang/qt/src/qgpgmekeylistjob.h (QGpgMEKeyListJob): Remove member mResult. * lang/qt/src/qgpgmelistallkeysjob.cpp (QGpgMEListAllKeysJob::QGpgMEListAllKeysJob): Remove initialization of mResult. (QGpgMEListAllKeysJob::exec): Remove call of resultHook. (QGpgMEListAllKeysJob::resultHook): Remove. * lang/qt/src/qgpgmelistallkeysjob.h (QGpgMEListAllKeysJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmereceivekeysjob.cpp (QGpgMEReceiveKeysJob::exec): Remove call of resultHook. (QGpgMEReceiveKeysJob::resultHook): Remove. * lang/qt/src/qgpgmereceivekeysjob.h (QGpgMEReceiveKeysJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmerevokekeyjob.cpp (QGpgMERevokeKeyJob::exec): Remove call of resultHook. * lang/qt/src/qgpgmesignencryptjob.cpp (QGpgMESignEncryptJob::exec): Remove call of resultHook. (QGpgMESignEncryptJob::resultHook): Remove. * lang/qt/src/qgpgmesignencryptjob.h (QGpgMESignEncryptJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmesignjob.cpp (QGpgMESignJob::exec): Remove call of resultHook. (QGpgMESignJob::resultHook): Remove. * lang/qt/src/qgpgmesignjob.h (QGpgMESignJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmeverifydetachedjob.cpp (QGpgMEVerifyDetachedJob::exec): Remove call of resultHook. (QGpgMEVerifyDetachedJob::resultHook): Remove. * lang/qt/src/qgpgmeverifydetachedjob.h (QGpgMEVerifyDetachedJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmeverifyopaquejob.cpp (QGpgMEVerifyOpaqueJob::exec): Remove call of resultHook. (QGpgMEVerifyOpaqueJob::resultHook): Remove. * lang/qt/src/qgpgmeverifyopaquejob.h (QGpgMEVerifyOpaqueJob): Remove resultHook override. Remove member mResult. * lang/qt/src/qgpgmewkdlookupjob.cpp (QGpgMEWKDLookupJob::exec): Remove call of resultHook. -- All overrides of resultHook (except for the one of QGpgMEKeyListJob) are superfluous. All the resultHook overrides do is store the result in a member variable which is then returned in exec() (which just before returning calls resultHook). The member variable the result is stored in is only ever used by exec(). So exec() can simply return the result directly. Some Job subclasses call resultHook without overriding it. That's equally useless because the default implementation of resultHook is empty. The only resultHook override that does anything useful is the one of QGpgMEKeyListJob.
* qt: Remove left-over mentions of showErrorDialogIngo Klöcker2024-01-195-32/+1
| | | | | | | | | | | | | * lang/qt/src/qgpgmedecryptjob.cpp, lang/qt/src/qgpgmeimportfromkeyserverjob.cpp, lang/qt/src/qgpgmeimportjob.cpp: Remove obsolete comment. * lang/qt/src/qgpgmekeylistjob.cpp, lang/qt/src/qgpgmelistallkeysjob.cpp: Remove long obsolete, #if 0'ed out definitions of showErrorDialog. -- Informing the users about errors is the responsibility of the users of the QGpgME Job API since a long time.