记录undefined reference to `SSLv3_client_method‘错误笔记

libcurl.a(libcurl_la-openssl.o): in function `ossl_connect_step1':

openssl.c:(.text+0x3ca8): undefined reference to `SSLv3_client_method'

我个人环境原因:编译选项指定了某个openssl目录,此目录下有libcrypto.a libssl.a

解决方法:删除这些-Lxxxx目录编译选项。

libcurl.a(libcurl_la-openssl.o): undefined reference to symbol 'X509_LOOKUP_file@@OPENSSL_1_1_0'

/usr/bin/ld: /usr/lib64/libcrypto.so.1.1: error adding symbols: DSO missing from command line

解决方法:增加 -lssl -lcrypto

以下的错误也是增加 -lssl -lcrypto

libcurl.a(libcurl_la-openssl.o): in function `Curl_ossl_shutdown':

openssl.c:(.text+0x182c): undefined reference to `SSL_free'

/usr/bin/ld: openssl.c:(.text+0x186c): undefined reference to `SSL_read'

/usr/bin/ld: openssl.c:(.text+0x187c): undefined reference to `SSL_get_error'

/usr/bin/ld: openssl.c:(.text+0x18c4): undefined reference to `SSL_get_shutdown'

/usr/bin/ld: openssl.c:(.text+0x1980): undefined reference to `SSL_shutdown'

/usr/bin/ld: ../../../linux/../os_public//Lib//libcurl.a(libcurl_la-openssl.o): in function `servercert':

openssl.c:(.text+0x1a78): undefined reference to `SSL_get_peer_certificate'

/usr/bin/ld: openssl.c:(.text+0x1e8c): undefined reference to `PEM_read_bio_X509'

/usr/bin/ld: openssl.c:(.text+0x1ee0): undefined reference to `SSL_get_verify_result'

/usr/bin/ld: openssl.c:(.text+0x1f1c): undefined reference to `X509_verify_cert_error_string'

/usr/bin/ld: openssl.c:(.text+0x201c): undefined reference to `SSL_get_peer_cert_chain'

/usr/bin/ld: openssl.c:(.text+0x24c0): undefined reference to `SSL_ctrl'

/usr/bin/ld: openssl.c:(.text+0x24e8): undefined reference to `OCSP_response_status'

/usr/bin/ld: openssl.c:(.text+0x24f8): undefined reference to `OCSP_response_get1_basic'

/usr/bin/ld: openssl.c:(.text+0x2510): undefined reference to `SSL_get_peer_cert_chain'

/usr/bin/ld: openssl.c:(.text+0x2520): undefined reference to `SSL_CTX_get_cert_store'

/usr/bin/ld: openssl.c:(.text+0x2534): undefined reference to `OCSP_basic_verify'

/usr/bin/ld: openssl.c:(.text+0x2560): undefined reference to `OCSP_resp_count'

/usr/bin/ld: openssl.c:(.text+0x2574): undefined reference to `OCSP_resp_get0'

/usr/bin/ld: openssl.c:(.text+0x2588): undefined reference to `OCSP_single_get0_status'

/usr/bin/ld: openssl.c:(.text+0x259c): undefined reference to `OCSP_check_validity'

/usr/bin/ld: openssl.c:(.text+0x25a8): undefined reference to `OCSP_cert_status_str'

/usr/bin/ld: openssl.c:(.text+0x29c8): undefined reference to `PEM_write_bio_X509'

/usr/bin/ld: openssl.c:(.text+0x2f3c): undefined reference to `OCSP_response_status_str'

/usr/bin/ld: openssl.c:(.text+0x303c): undefined reference to `X509_verify_cert_error_string'

/usr/bin/ld: openssl.c:(.text+0x306c): undefined reference to `OCSP_crl_reason_str'

/usr/bin/ld: ../../../linux/../os_public//Lib//libcurl.a(libcurl_la-openssl.o): in function `ossl_connect_step2':

openssl.c:(.text+0x3244): undefined reference to `SSL_connect'

/usr/bin/ld: openssl.c:(.text+0x325c): undefined reference to `SSL_get_error'

/usr/bin/ld: openssl.c:(.text+0x32c8): undefined reference to `SSL_get_verify_result'

/usr/bin/ld: openssl.c:(.text+0x337c): undefined reference to `SSL_version'

/usr/bin/ld: openssl.c:(.text+0x33e8): undefined reference to `SSL_get_current_cipher'

/usr/bin/ld: openssl.c:(.text+0x33f0): undefined reference to `SSL_CIPHER_get_name'

/usr/bin/ld: openssl.c:(.text+0x342c): undefined reference to `SSL_get0_alpn_selected'

/usr/bin/ld: openssl.c:(.text+0x359c): undefined reference to `X509_verify_cert_error_string'

/usr/bin/ld: ../../../linux/../os_public//Lib//libcurl.a(libcurl_la-openssl.o): in function `ossl_recv':

openssl.c:(.text+0x3708): undefined reference to `SSL_read'

/usr/bin/ld: openssl.c:(.text+0x373c): undefined reference to `SSL_get_error'

/usr/bin/ld: ../../../linux/../os_public//Lib//libcurl.a(libcurl_la-openssl.o): in function `ossl_connect_step1':

openssl.c:(.text+0x39c0): undefined reference to `TLS_client_method'

/usr/bin/ld: openssl.c:(.text+0x39ec): undefined reference to `SSL_CTX_free'

/usr/bin/ld: openssl.c:(.text+0x39fc): undefined reference to `SSL_CTX_new'

/usr/bin/ld: openssl.c:(.text+0x3a24): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x3a98): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x3ab0): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x3ac8): undefined reference to `SSL_CTX_set_options'

/usr/bin/ld: openssl.c:(.text+0x3b50): undefined reference to `SSL_CTX_set_default_passwd_cb_userdata'

/usr/bin/ld: openssl.c:(.text+0x3b60): undefined reference to `SSL_CTX_set_default_passwd_cb'

/usr/bin/ld: openssl.c:(.text+0x3ca8): undefined reference to `SSLv3_client_method'

/usr/bin/ld: openssl.c:(.text+0x3eac): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x3ef8): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x3f1c): undefined reference to `SSL_CTX_set_next_proto_select_cb'

/usr/bin/ld: openssl.c:(.text+0x3fa8): undefined reference to `SSL_free'

/usr/bin/ld: openssl.c:(.text+0x3fe0): undefined reference to `SSL_CTX_set_ciphersuites'

/usr/bin/ld: openssl.c:(.text+0x4014): undefined reference to `SSL_CTX_set_post_handshake_auth'

/usr/bin/ld: openssl.c:(.text+0x404c): undefined reference to `SSL_CTX_get_cert_store'

/usr/bin/ld: openssl.c:(.text+0x4054): undefined reference to `X509_LOOKUP_file'

/usr/bin/ld: openssl.c:(.text+0x4074): undefined reference to `X509_load_crl_file'

/usr/bin/ld: openssl.c:(.text+0x409c): undefined reference to `SSL_CTX_get_cert_store'

/usr/bin/ld: openssl.c:(.text+0x40f0): undefined reference to `SSL_CTX_set_verify'

/usr/bin/ld: openssl.c:(.text+0x4118): undefined reference to `SSL_CTX_set_keylog_callback'

/usr/bin/ld: openssl.c:(.text+0x4138): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x414c): undefined reference to `SSL_CTX_sess_set_new_cb'

/usr/bin/ld: openssl.c:(.text+0x41a4): undefined reference to `SSL_free'

/usr/bin/ld: openssl.c:(.text+0x41b0): undefined reference to `SSL_new'

/usr/bin/ld: openssl.c:(.text+0x41e8): undefined reference to `SSL_set_connect_state'

/usr/bin/ld: openssl.c:(.text+0x4238): undefined reference to `BIO_f_ssl'

/usr/bin/ld: openssl.c:(.text+0x4268): undefined reference to `SSL_set_bio'

/usr/bin/ld: openssl.c:(.text+0x4290): undefined reference to `SSL_CTX_set_cipher_list'

/usr/bin/ld: openssl.c:(.text+0x4318): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x4334): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x4350): undefined reference to `SSL_CTX_set_msg_callback'

/usr/bin/ld: openssl.c:(.text+0x4368): undefined reference to `SSL_CTX_ctrl'

/usr/bin/ld: openssl.c:(.text+0x43b8): undefined reference to `SSL_CTX_set_alpn_protos'

/usr/bin/ld: openssl.c:(.text+0x4468): undefined reference to `SSL_CTX_set_srp_username'

/usr/bin/ld: openssl.c:(.text+0x4488): undefined reference to `SSL_CTX_set_srp_password'

/usr/bin/ld: openssl.c:(.text+0x44d4): undefined reference to `SSL_CTX_set_cipher_list'

/usr/bin/ld: openssl.c:(.text+0x45a0): undefined reference to `SSL_CTX_load_verify_locations'

/usr/bin/ld: openssl.c:(.text+0x4654): undefined reference to `SSL_set_fd'

/usr/bin/ld: openssl.c:(.text+0x46ac): undefined reference to `SSL_CTX_use_certificate_chain_file'

/usr/bin/ld: openssl.c:(.text+0x4750): undefined reference to `SSL_ctrl'

/usr/bin/ld: openssl.c:(.text+0x479c): undefined reference to `SSL_ctrl'

/usr/bin/ld: openssl.c:(.text+0x47f0): undefined reference to `SSL_set_ex_data'

/usr/bin/ld: openssl.c:(.text+0x4808): undefined reference to `SSL_set_ex_data'

/usr/bin/ld: openssl.c:(.text+0x4844): undefined reference to `SSL_set_session'

/usr/bin/ld: openssl.c:(.text+0x4950): undefined reference to `SSL_CTX_use_certificate_file'

/usr/bin/ld: openssl.c:(.text+0x4a34): undefined reference to `SSL_CTX_get_cert_store'

/usr/bin/ld: openssl.c:(.text+0x4b14): undefined reference to `SSL_CTX_use_PrivateKey_file'

/usr/bin/ld: openssl.c:(.text+0x4b5c): undefined reference to `SSL_new'

/usr/bin/ld: openssl.c:(.text+0x4b68): undefined reference to `SSL_get_certificate'

/usr/bin/ld: openssl.c:(.text+0x4b80): undefined reference to `SSL_get_privatekey'

/usr/bin/ld: openssl.c:(.text+0x4b9c): undefined reference to `SSL_get_privatekey'

/usr/bin/ld: openssl.c:(.text+0x4bb4): undefined reference to `SSL_free'

/usr/bin/ld: openssl.c:(.text+0x4bbc): undefined reference to `SSL_CTX_check_private_key'

/usr/bin/ld: openssl.c:(.text+0x4c0c): undefined reference to `SSL_CTX_use_certificate'

/usr/bin/ld: openssl.c:(.text+0x4d8c): undefined reference to `SSL_CTX_use_PrivateKey'

/usr/bin/ld: openssl.c:(.text+0x4e18): undefined reference to `SSL_CTX_use_certificate'

/usr/bin/ld: openssl.c:(.text+0x4f40): undefined reference to `SSL_CTX_use_PrivateKey'

/usr/bin/ld: openssl.c:(.text+0x4fa0): undefined reference to `SSL_CTX_check_private_key'

/usr/bin/ld: openssl.c:(.text+0x4fc8): undefined reference to `SSL_CTX_add_client_CA'

/usr/bin/ld: openssl.c:(.text+0x4fe0): undefined reference to `SSL_CTX_ctrl'

相关推荐
爱吃青椒不爱吃西红柿‍️18 分钟前
华为ASP与CSP是什么?
服务器·前端·数据库
IT果果日记19 分钟前
ubuntu 安装 conda
linux·ubuntu·conda
Python私教22 分钟前
ubuntu搭建k8s环境详细教程
linux·ubuntu·kubernetes
羑悻的小杀马特35 分钟前
环境变量简介
linux
小陈phd1 小时前
Vscode LinuxC++环境配置
linux·c++·vscode
是阿建吖!1 小时前
【Linux】进程状态
linux·运维
hzyyyyyyyu1 小时前
内网安全隧道搭建-ngrok-frp-nps-sapp
服务器·网络·安全
明明跟你说过2 小时前
Linux中的【tcpdump】:深入介绍与实战使用
linux·运维·测试工具·tcpdump
Komorebi.py3 小时前
【Linux】-学习笔记05
linux·笔记·学习