streambinder / vpnc

IPsec (Cisco/Juniper) VPN concentrator client
https://davidepucci.it/doc/vpnc
GNU General Public License v2.0
37 stars 20 forks source link

Fall back to libgcrypt-config if pkg-config doesn't work #29

Closed xelan closed 2 years ago

xelan commented 2 years ago

During my testing, I found out that the pkg-config method to retrieve the libgcrypt CFLAGS and LIBS does not work in some cases. At least when cross-compiling for OpenWRT on ARM, pkg-config errors with the message

Package libgcrypt was not found in the pkg-config search path. Perhaps you should add the directory containing `libgcrypt.pc' to the PKG_CONFIG_PATH environment variable No package 'libgcrypt' found

As a consequence, vpnc cannot compile due to non-resolvable libgcrypt dependencies and the build fails.

Now, we fall back to the old method of using the libgcrypt-config script if pkg-config cannot retrieve the libgcrypt configurations.

See #23

streambinder commented 2 years ago

Looks good. Merging.

xelan commented 2 years ago

Thanks @streambinder :+1: