一直好好的,macos升级后突然出现
Undefined symbols for architecture x86_64:
“_ber_free”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_err2string”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_first_attribute”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_first_entry”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_free_urldesc”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_get_dn”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_get_values_len”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_init”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_memfree”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_msgfree”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_next_attribute”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_next_entry”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_search_s”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_set_option”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_simple_bind_s”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_unbind_s”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_url_parse”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
“_ldap_value_free_len”, referenced from:
_Curl_ldap in libcurl.a(libcurl_la-ldap.o)
ld: symbol(s) not found for architecture x86_64
解决方法
重新编译curl,添加如下:
–disable-ldap --disable-ldaps
所有选项如下:
./configure --disable-shared --without-zlib --disable-ldap --disable-ldaps --with-ssl=/Users/xxx/libs/build/openssl/openssl-OpenSSL_1_0_2l-build/x86_64 --prefix=/Users/xxx/libs/macos-build/out
博客指出macOS升级后出现Undefined symbols for architecture x86_64的编译错误,涉及多个ldap相关符号未找到。解决方法是重新编译curl,添加–disable-ldap --disable-ldaps选项,并给出了完整的编译配置选项。
605

被折叠的 条评论
为什么被折叠?



