Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mz_crypt_openssl.c:31 3:16: error: field ‘ctx’ has incomplete type #409

Closed
Polynomial-C opened this issue Aug 1, 2019 · 0 comments
Closed
Labels
encryption Encryption/decryption issue fixed Issue or bug has been fixed

Comments

@Polynomial-C
Copy link

This happens when trying to compile with -DMZ_OPENSSL=yes against openssl-1.1.1c:

[ 40%] Building C object CMakeFiles/minizip.dir/mz_crypt_openssl.c.o
/usr/bin/x86_64-pc-linux-gnu-gcc -DHAVE_BZIP2 -DHAVE_CONFIG_H -DHAVE_IMMINTRIN_H -DHAVE_INTTYPES_H -DHAVE_LIMITS_H -DHAVE_LZMA -DHAVE_MEMORY_H -DHAVE_PKCRYPT -DHAVE_STDBOOL_H -DHAVE_STDINT_H -DHAVE_STRINGS_H -DHAVE_STRING_H -DHAVE_WZAES -DHAVE_ZLIB -DLZMA_API_STATIC -DMZ_EXPORTS -D_POSIX_C_SOURCE=200112L -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9 -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma/api -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma/check -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma/common -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma/lz -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma/lzma -I/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/lib/liblzma/rangecoder   -DNDEBUG -march=native -mtune=native -O2 -pipe -fPIC   -W -Wall -std=gnu99 -o CMakeFiles/minizip.dir/mz_crypt_openssl.c.o -c /var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c
/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c:313:16: error: field ‘ctx’ has incomplete type
     HMAC_CTX   ctx;
                ^~~
/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c: In function ‘mz_crypt_hmac_reset’:
/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c:325:5: warning: implicit declaration of function ‘HMAC_CTX_cleanup’; did you mean ‘HMAC_CTX_get_md’? [-Wimplicit-function-declaration]
     HMAC_CTX_cleanup(&hmac->ctx);
     ^~~~~~~~~~~~~~~~
     HMAC_CTX_get_md
/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c: In function ‘mz_crypt_hmac_init’:
/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c:347:5: warning: ‘HMAC_Init’ is deprecated [-Wdeprecated-declarations]
     result = HMAC_Init(&hmac->ctx, key, key_length, evp_md);
     ^~~~~~
In file included from /usr/include/openssl/opensslconf.h:10,
                 from /usr/include/openssl/e_os2.h:13,
                 from /usr/include/openssl/err.h:13,
                 from /var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9/mz_crypt_openssl.c:15:
/usr/include/openssl/hmac.h:30:1: note: declared here
 DEPRECATEDIN_1_1_0(__owur int HMAC_Init(HMAC_CTX *ctx, const void *key, int len,
 ^~~~~~~~~~~~~~~~~~
make[2]: *** [CMakeFiles/minizip.dir/build.make:232: CMakeFiles/minizip.dir/mz_crypt_openssl.c.o] Error 1
make[2]: Leaving directory '/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9-abi_x86_64.amd64'
make[1]: *** [CMakeFiles/Makefile2:76: CMakeFiles/minizip.dir/all] Error 2
make[1]: Leaving directory '/var/tmp/portage/sys-libs/minizip-2.8.9/work/minizip-2.8.9-abi_x86_64.amd64'
make: *** [Makefile:130: all] Error 2
@nmoinvaz nmoinvaz added 2.0 encryption Encryption/decryption issue fixed Issue or bug has been fixed labels Jan 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
encryption Encryption/decryption issue fixed Issue or bug has been fixed
Projects
None yet
Development

No branches or pull requests

2 participants