redsocks icon indicating copy to clipboard operation
redsocks copied to clipboard

Build: encrypt.h:92:18: error: field ‘evp’ has incomplete type

Open aTanW opened this issue 1 year ago • 2 comments

During build this error appeared. I missed library or where to look ?

aTanW avatar Jul 04 '24 09:07 aTanW

You have two choices:

  • Do not compile with shadowsocks and https-connect protocols support
  • Compile with old openssl versions, like 1.0.2u

semigodking avatar Jul 13 '24 03:07 semigodking

You have two choices:

  • Do not compile with shadowsocks and https-connect protocols support
  • Compile with old openssl versions, like 1.0.2u

Compile with OpenSSL by default. To compile with PolarSSL, run 'make USE_CRYPTO_POLARSSL=true' instead. cc -fPIC -O3 -D_BSD_SOURCE -D_DEFAULT_SOURCE -Wall -std=c99 -D_XOPEN_SOURCE=600 -DUSE_CRYPTO_OPENSSL -o redsocks2 parser.o main.o redsocks.o log.o direct.o ipcache.o autoproxy.o encrypt.o shadowsocks.o http-connect.o socks4.o socks5.o http-relay.o base.o base64.o md5.o http-auth.o utils.o redudp.o socks5-udp.o shadowsocks-udp.o tcpdns.o gen/version.o -levent -lssl -lcrypto -ldl /usr/bin/ld: main.o: in function main': main.c:(.text.startup+0xcc): undefined reference to SSL_library_init' /usr/bin/ld: main.c:(.text.startup+0xd0): undefined reference to ERR_load_crypto_strings' /usr/bin/ld: main.c:(.text.startup+0xd4): undefined reference to SSL_load_error_strings' /usr/bin/ld: main.c:(.text.startup+0xd8): undefined reference to OPENSSL_add_all_algorithms_noconf' /usr/bin/ld: main.c:(.text.startup+0x4c0): undefined reference to EVP_cleanup' /usr/bin/ld: main.c:(.text.startup+0x4c4): undefined reference to ERR_free_strings' /usr/bin/ld: redsocks.o:(.data.rel+0x30): undefined reference to https_connect_subsys' /usr/bin/ld: encrypt.o: in function ss_encrypt': encrypt.c:(.text+0x41c): undefined reference to EVP_CIPHER_CTX_cleanup' /usr/bin/ld: encrypt.o: in function ss_decrypt': encrypt.c:(.text+0x58c): undefined reference to EVP_CIPHER_CTX_cleanup' /usr/bin/ld: encrypt.o: in function enc_ctx_init': encrypt.c:(.text+0x638): undefined reference to EVP_CIPHER_CTX_init' /usr/bin/ld: encrypt.c:(.text+0x6c8): undefined reference to EVP_CIPHER_CTX_cleanup' /usr/bin/ld: encrypt.o: in function enc_ctx_free': encrypt.c:(.text+0x6f0): undefined reference to EVP_CIPHER_CTX_cleanup' /usr/bin/ld: encrypt.o: in function enc_init': encrypt.c:(.text+0x2350): undefined reference to OPENSSL_add_all_algorithms_noconf' /usr/bin/ld: utils.o: in function red_connect_relay_ssl': utils.c:(.text+0x4ac): undefined reference to bufferevent_openssl_filter_new' collect2: error: ld returned 1 exit status make: *** [Makefile:153: redsocks2] Error 1`

I meet this error when make in debian with openssl version 1.0.2u, I can't "make".

KotVnn avatar Jul 15 '24 15:07 KotVnn