0
我正在嘗試安裝ruby-ldap,但它不起作用。在Debian中安裝ruby-ldap時出錯
嘗試安裝libsasl2-dev和libldap-dev沒有幫助。
試過apt-get install ruby-ldap
寶石忽略它。
嘗試刪除/var/lib/gems/1.9.1/gems/ruby-ldap*
& /var/lib/gems/1.9.1/cache/ruby-ldap*
重新安裝並沒有幫助。
任何人都有類似的問題?
# gem install ruby-ldap
Fetching: ruby-ldap-0.9.12.gem (100%)
Building native extensions. This could take a while...
ERROR: Error installing ruby-ldap:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
--with-openldap2
checking for ldap.h... yes
checking for lber.h... yes
checking for ldap_ssl.h... no
checking for openssl/ssl.h... yes
checking for openssl/crypto.h... yes
checking for main() in -lcrypto... yes
checking for main() in -lssl... yes
checking for main() in -lnsl... yes
checking for main() in -lpthread... yes
checking for main() in -lresolv... yes
checking for main() in -llber... yes
checking for main() in -lldap_r... yes
checking for main() in -lldap... yes
checking for ldap_init() in ldap.h... yes
checking for ldap_set_option()... yes
checking for ldap_get_option()... yes
checking for ldap_start_tls_s()... yes
checking for ldap_memfree()... yes
checking for ldap_perror()... yes
checking for ldap_sort_entries()... yes
checking for ldapssl_init()... no
checking for ldap_sslinit()... no
checking for ldap_sasl_bind_s()... yes
checking for ldap_compare_s()... yes
checking for ldap_add_ext_s()... yes
checking for ldap_compare_ext_s()... yes
checking for ldap_delete_ext_s()... yes
checking for ldap_modify_ext_s()... yes
checking for ldap_search_ext_s()... yes
checking for ldap_unbind_ext_s()... yes
checking for ldap_sasl_interactive_bind_s()... yes
creating Makefile
make
compiling saslconn.c
saslconn.c: In function ‘rb_ldap_conn_sasl_bind’:
saslconn.c:178:7: error: format not a string literal and no format arguments [-Werror=format-security]
saslconn.c:200:7: error: format not a string literal and no format arguments [-Werror=format-security]
cc1: some warnings being treated as errors
make: *** [saslconn.o] Error 1
是的,它是aparenty [this](http://wiki.debian.org/Hardening#DEB_BUILD_HARDENING_FORMAT_.28gcc.2Fg.2B-.2B-_-Wformat_-Wformat-security_-Werror.3Dformat-security。 29)是雷森。非常感謝!! – aza