I have a C program that uses libgcrypt . I put this string in the builder to install the libraries for Centos 7:
yum -y install json-c-devel expat-devel libpcap-devel flex-devel automake libtool bison libuv-devel openssl-devel libgcrypt-devel
and no problem come out.
Unfortunately, the compilation of the code terminate with an error caused by a macro cannot be found:
error: 'GCRY_CIPHER_MODE_GCM' undeclared (first use in this function)
The macro is inside the libgcrypt for sure, so I really don't understand how cannot be found at all.
If I compile the same code in Debian, it works well and the macro is resolved properly.
PS My system is Debian 8 and I use docker for Centos 7
CentOS-7
uses libgcrypt
and libgcrypt-devel
version 1.5 (patched), which seems to not include GCRY_CIPHER_MODE_GCM
declaration.
Looking at the git commits, it seems to have been available in 1.6+.
On a newer version, you would see a line in /usr/include/gcrypt.h
, like the following:
GCRY_CIPHER_MODE_GCM = 9, /* Galois Counter Mode. */
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.