十六薙夜血 发表于 2009-02-28 01:04

编译vsftp出现错误,请帮助!非常感谢!

我在solaris10 10/08下面编译vsftp,修改builddefs.h,更改了tcp_wrappers为define,编译后得到如下输出:

bash-3.00# make
gcc -c tcpwrap.c -O2 -Wall -W -Wshadow-idirafter dummyinc
tcpwrap.c:15:20: tcpd.h: 无此文件或目录
tcpwrap.c: In function `vsf_tcp_wrapper_ok':
tcpwrap.c:28: error: storage size of 'req' isn't known
tcpwrap.c:29: warning: implicit declaration of function `request_init'
tcpwrap.c:29: error: `RQ_DAEMON' undeclared (first use in this function)
tcpwrap.c:29: error: (Each undeclared identifier is reported only once
tcpwrap.c:29: error: for each function it appears in.)
tcpwrap.c:29: error: `RQ_FILE' undeclared (first use in this function)
tcpwrap.c:30: warning: implicit declaration of function `fromhost'
tcpwrap.c:31: warning: implicit declaration of function `hosts_access'
tcpwrap.c:28: warning: unused variable `req'
make: *** Error 1


tcpd.h是个什么文件?要怎么得到?请问这是怎么回事啊?非常感谢!

race 发表于 2009-02-28 21:10

版本不匹配,没办法编译

十六薙夜血 发表于 2009-02-28 23:29

感谢楼上帮忙。

我的solaris10 10/08是OEM最大化安装的,所有的软件应该都具备了,可是非常令我吃惊的是,这个问题是如此解决的:

我尝试在系统中打开tcp_wrappers=true,是成功的,而且用telnet简单测试了一下,已经生效的,所以我从来没有怀疑过tcp_wrappers有问题。

但是我今天重新下载了tcp_wrappers,安装,然后再编译,关于tcp_wrappers的错误居然都消失了,但是得到了关于ssl的错误,如下:

bash-3.00# make
gcc -c ssl.c -O2 -Wall -W -Wshadow-idirafter dummyinc
ssl.c:28:25: openssl/err.h: 无此文件或目录
ssl.c:29:26: openssl/rand.h: 无此文件或目录
ssl.c:30:25: openssl/bio.h: 无此文件或目录
ssl.c:34: error: syntax error before '*' token
ssl.c:34: warning: type defaults to `int' in declaration of `get_ssl'
ssl.c:34: warning: data definition has no type or storage class
ssl.c:38: error: syntax error before '*' token
ssl.c:39: error: syntax error before "X509_STORE_CTX"
ssl.c:41: error: syntax error before '*' token
ssl.c: In function `ssl_init':
ssl.c:53: error: `SSL_CTX' undeclared (first use in this function)
ssl.c:53: error: (Each undeclared identifier is reported only once
ssl.c:53: error: for each function it appears in.)
ssl.c:53: error: `p_ctx' undeclared (first use in this function)
ssl.c:56: warning: implicit declaration of function `SSL_library_init'
ssl.c:57: warning: implicit declaration of function `SSL_CTX_new'
ssl.c:57: warning: implicit declaration of function `SSLv23_server_method'
ssl.c:58: error: `NULL' undeclared (first use in this function)
ssl.c:62: error: `SSL_OP_ALL' undeclared (first use in this function)
ssl.c:65: error: `SSL_OP_NO_SSLv2' undeclared (first use in this function)
ssl.c:69: error: `SSL_OP_NO_SSLv3' undeclared (first use in this function)
ssl.c:73: error: `SSL_OP_NO_TLSv1' undeclared (first use in this function)
ssl.c:75: warning: implicit declaration of function `SSL_CTX_set_options'
ssl.c:83: warning: implicit declaration of function `SSL_CTX_use_certificate_chain_file'
ssl.c:87: warning: implicit declaration of function `SSL_CTX_use_PrivateKey_file'
ssl.c:87: error: `X509_FILETYPE_PEM' undeclared (first use in this function)
ssl.c:109: warning: implicit declaration of function `SSL_CTX_set_cipher_list'
ssl.c:113: warning: implicit declaration of function `RAND_status'
ssl.c:119: error: `SSL_VERIFY_PEER' undeclared (first use in this function)
ssl.c:123: error: `SSL_VERIFY_FAIL_IF_NO_PEER_CERT' undeclared (first use in this function)
ssl.c:127: warning: implicit declaration of function `SSL_CTX_set_verify'
ssl.c:130: warning: implicit declaration of function `SSL_CTX_load_verify_locations'
ssl.c: In function `ssl_getline':
ssl.c:234: warning: implicit declaration of function `SSL_read'
ssl.c: In function `ssl_read':
ssl.c:255: error: `SSL' undeclared (first use in this function)
ssl.c:255: error: `p_ssl' undeclared (first use in this function)
ssl.c:259: warning: implicit declaration of function `SSL_get_error'
ssl.c:261: error: `SSL_ERROR_WANT_READ' undeclared (first use in this function)
ssl.c:262: error: `SSL_ERROR_WANT_WRITE' undeclared (first use in this function)
ssl.c:265: warning: implicit declaration of function `SSL_get_shutdown'
ssl.c:265: error: `SSL_RECEIVED_SHUTDOWN' undeclared (first use in this function)
ssl.c: In function `ssl_write':
ssl.c:285: warning: implicit declaration of function `SSL_write'
ssl.c:285: error: `SSL' undeclared (first use in this function)
ssl.c:285: error: syntax error before ')' token
ssl.c:286: error: syntax error before ')' token
ssl.c:288: error: `SSL_ERROR_WANT_READ' undeclared (first use in this function)
ssl.c:289: error: `SSL_ERROR_WANT_WRITE' undeclared (first use in this function)
ssl.c: In function `ssl_write_str':
ssl.c:297: error: `SSL' undeclared (first use in this function)
ssl.c:297: error: syntax error before ')' token
ssl.c: In function `maybe_log_shutdown_state':
ssl.c:316: error: `SSL_SENT_SHUTDOWN' undeclared (first use in this function)
ssl.c:320: error: `SSL_RECEIVED_SHUTDOWN' undeclared (first use in this function)
ssl.c: In function `ssl_data_close':
ssl.c:351: error: `SSL' undeclared (first use in this function)
ssl.c:351: error: `p_ssl' undeclared (first use in this function)
ssl.c:364: warning: implicit declaration of function `SSL_shutdown'
ssl.c:388: warning: implicit declaration of function `SSL_free'
ssl.c:389: error: `NULL' undeclared (first use in this function)
ssl.c: In function `ssl_accept':
ssl.c:401: error: `SSL' undeclared (first use in this function)
ssl.c:401: error: `p_ssl' undeclared (first use in this function)
ssl.c:402: error: `NULL' undeclared (first use in this function)
ssl.c: At top level:
ssl.c:454: error: syntax error before '*' token
ssl.c:456: warning: return type defaults to `int'
ssl.c: In function `get_ssl':
ssl.c:457: error: `SSL' undeclared (first use in this function)
ssl.c:457: error: `p_ssl' undeclared (first use in this function)
ssl.c:457: warning: implicit declaration of function `SSL_new'
ssl.c:458: error: `NULL' undeclared (first use in this function)
ssl.c:467: warning: implicit declaration of function `SSL_set_fd'
ssl.c:477: warning: implicit declaration of function `SSL_accept'
ssl.c:492: warning: implicit declaration of function `SSL_get_cipher_version'
ssl.c:492: warning: initialization makes pointer from integer without a cast
ssl.c:493: error: `SSL_CIPHER' undeclared (first use in this function)
ssl.c:493: error: `p_ssl_cipher' undeclared (first use in this function)
ssl.c:493: warning: implicit declaration of function `SSL_get_current_cipher'
ssl.c:494: warning: implicit declaration of function `SSL_CIPHER_get_name'
ssl.c:494: warning: initialization makes pointer from integer without a cast
ssl.c:495: warning: implicit declaration of function `SSL_session_reused'
ssl.c:496: error: `X509' undeclared (first use in this function)
ssl.c:496: error: `p_ssl_cert' undeclared (first use in this function)
ssl.c:496: warning: implicit declaration of function `SSL_get_peer_certificate'
ssl.c:512: warning: implicit declaration of function `X509_free'
ssl.c: In function `ssl_session_init':
ssl.c:526: error: `SSL' undeclared (first use in this function)
ssl.c:526: error: `p_ssl' undeclared (first use in this function)
ssl.c:527: error: `NULL' undeclared (first use in this function)
ssl.c: At top level:
ssl.c:538: error: syntax error before '*' token
ssl.c: In function `ssl_cert_digest':
ssl.c:540: error: `X509' undeclared (first use in this function)
ssl.c:540: error: `p_cert' undeclared (first use in this function)
ssl.c:540: error: `p_ssl' undeclared (first use in this function)
ssl.c:542: error: `NULL' undeclared (first use in this function)
ssl.c:546: error: `p_str' undeclared (first use in this function)
ssl.c:546: error: `EVP_MAX_MD_SIZE' undeclared (first use in this function)
ssl.c:549: warning: implicit declaration of function `X509_digest'
ssl.c:549: warning: implicit declaration of function `EVP_sha256'
ssl.c:565: error: `p_sess' undeclared (first use in this function)
ssl.c: In function `get_ssl_error':
ssl.c:574: warning: implicit declaration of function `SSL_load_error_strings'
ssl.c:575: warning: implicit declaration of function `ERR_error_string'
ssl.c:575: warning: implicit declaration of function `ERR_get_error'
ssl.c:575: error: `NULL' undeclared (first use in this function)
ssl.c:575: warning: return makes pointer from integer without a cast
ssl.c: At top level:
ssl.c:578: error: syntax error before '*' token
ssl.c: In function `setup_bio_callbacks':
ssl.c:580: error: `BIO' undeclared (first use in this function)
ssl.c:580: error: `p_bio' undeclared (first use in this function)
ssl.c:580: warning: implicit declaration of function `SSL_get_rbio'
ssl.c:580: error: `p_ssl' undeclared (first use in this function)
ssl.c:581: warning: implicit declaration of function `BIO_set_callback'
ssl.c:582: warning: implicit declaration of function `SSL_get_wbio'
ssl.c: At top level:
ssl.c:588: error: syntax error before '*' token
ssl.c: In function `bio_callback':
ssl.c:592: error: `p_arg' undeclared (first use in this function)
ssl.c:593: error: `argi' undeclared (first use in this function)
ssl.c:594: error: `argl' undeclared (first use in this function)
ssl.c:595: error: `oper' undeclared (first use in this function)
ssl.c:595: error: `BIO_CB_READ' undeclared (first use in this function)
ssl.c:595: error: `BIO_CB_RETURN' undeclared (first use in this function)
ssl.c:596: error: `BIO_CB_WRITE' undeclared (first use in this function)
ssl.c:598: error: `ret' undeclared (first use in this function)
ssl.c:599: warning: implicit declaration of function `BIO_get_fd'
ssl.c:599: error: `p_bio' undeclared (first use in this function)
ssl.c:599: error: `NULL' undeclared (first use in this function)
ssl.c: At top level:
ssl.c:606: error: syntax error before "X509_STORE_CTX"
ssl.c: In function `ssl_verify_callback':
ssl.c:608: error: `p_ctx' undeclared (first use in this function)
ssl.c:611: error: `verify_ok' undeclared (first use in this function)
ssl.c: At top level:
ssl.c:294: warning: unused parameter 'p_ssl'
ssl.c:279: warning: unused parameter 'p_ssl'
ssl.c:279: warning: unused parameter 'p_buf'
ssl.c:279: warning: unused parameter 'len'
make: *** Error 1


这次我依然采用下载openssl安装后再编译的方法,但是不起作用了。

还望达人帮忙了。

非常感谢!

十六薙夜血 发表于 2009-03-02 22:56

这个问题我绝对不是第一个遇到的,还望有能力的朋友帮帮忙,非常感谢!

不进一环 发表于 2009-03-03 00:29

有现成的不用

只能说楼主有时间有闲心

十六薙夜血 发表于 2009-03-03 16:02

ls的话怎解?
现成的vsftp?还是现成的ftp?

问题已经解决了。谢谢大家的关注!

dps迷失_ 发表于 2013-04-26 10:31

请问楼主问题是怎么解决的?!总结下呗!回复 6# 十六薙夜血


   

yszx07 发表于 2013-04-26 15:16

求解决办法,共享!
页: [1]
查看完整版本: 编译vsftp出现错误,请帮助!非常感谢!