I'd like to request (again) that libgcrypt provide a .pc file to make it easier
to link with libgcrypt. Checking for libgcrypt using the custom m4 file provided
by libgcrypt is harder than necessary: when libgcrypt-devel is not installed,
the macro is not defined, so it is necessary to wrap the call to
AM_PATH_LIBGCRYPT() in an m4_ifdef macro. If this is not done, the user will get
cryptic error messages.
In comparison, using pkg-config has the following advantages:
- if libgcrypt-devel is not installed, pkg-config provides a nice error message
without further work
- invocation of PKG_CHECK_MODULES() is shorter than AM_PATH_LIBGCRYPT()
- most other libraries support pkg-config, and things are easier when everything
follows the same pattern.
In the changelog, Moritz Schulte wrote that "we do not want to support a second,
foreign configuration system". Although I understand the sentiment, this is just
one file, trivial and not requiring any maintenance, and would make life easier
for projects using libgcrypt.