PDA

View Full Version : pure-ftpd compile fails


fork
5th November 2007, 05:49
hi,
i installed latest openssl 0.9.8g (i already compiled ssh postfix php and apache with that)
i'm trying to compile pure-ftpd-1.0.xx (xx means 21 and 22)

first i get an error at configure

i can't really choose the dir of ssl includes, so i do
ln -s /usr/local/ssl/include/openssl/ /usr/include/openssl
and i pass the configure

when i do make this happens

gcc -g -O2 -L/usr/local/lib -L/usr/local/mysql/lib -L/usr/lib/mysql -L/usr/mysql/lib -L/usr/local/lib/mysql -L/usr/local/mysql/lib/mysql -L/usr/mysql/lib/mysql -o pure-ftpd pure_ftpd-daemons.o pure_ftpd-ftpd.o pure_ftpd-log_unix.o pure_ftpd-log_mysql.o pure_ftpd-log_pgsql.o pure_ftpd-log_pam.o pure_ftpd-log_ldap.o pure_ftpd-log_puredb.o pure_ftpd-log_extauth.o pure_ftpd-ls.o pure_ftpd-parser.o pure_ftpd-bsd-glob.o pure_ftpd-fakesnprintf.o pure_ftpd-bsd-realpath.o pure_ftpd-mysnprintf.o pure_ftpd-caps.o pure_ftpd-ftp_parser.o pure_ftpd-dynamic.o pure_ftpd-ftpwho-update.o pure_ftpd-bsd-getopt_long.o pure_ftpd-upload-pipe.o pure_ftpd-ipv4stack.o pure_ftpd-altlog.o pure_ftpd-crypto.o pure_ftpd-crypto-md5.o pure_ftpd-crypto-sha1.o pure_ftpd-quotas.o pure_ftpd-fakechroot.o pure_ftpd-diraliases.o pure_ftpd-ftpwho-read.o pure_ftpd-getloadavg.o pure_ftpd-privsep.o pure_ftpd-tls.o pure_ftpd-osx-extensions.o pure_ftpd-auth_gssapi.o ../puredb/src/libpuredb_read.a -lmysqlclient -lz -lm -lcrypt -ldl -lpam
pure_ftpd-ftpd.o: In function `doreply':
/home/fork/src/pure-ftpd-1.0.22/src/ftpd.c:712: undefined reference to `SSL_write'
pure_ftpd-ftpd.o: In function `die':
/home/fork/src/pure-ftpd-1.0.22/src/ftpd.c:228: undefined reference to `SSL_write'
pure_ftpd-ftp_parser.o: In function `sfgets':
/home/fork/src/pure-ftpd-1.0.22/src/ftp_parser.c:97: undefined reference to `SSL_read'
pure_ftpd-tls.o: In function `tls_error':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:15: undefined reference to `ERR_get_error'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:15: undefined reference to `ERR_error_string'
pure_ftpd-tls.o: In function `tls_init_new_session':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:118: undefined reference to `SSL_new'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:122: undefined reference to `SSL_set_rfd'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:126: undefined reference to `SSL_set_accept_state'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:127: undefined reference to `SSL_accept'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:130: undefined reference to `SSL_get_current_cipher'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:132: undefined reference to `SSL_CIPHER_get_bits'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:137: undefined reference to `SSL_CIPHER_get_name'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:137: undefined reference to `SSL_CIPHER_get_version'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:122: undefined reference to `SSL_set_wfd'
pure_ftpd-tls.o: In function `tls_free_library':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:105: undefined reference to `SSL_free'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:109: undefined reference to `SSL_CTX_free'
pure_ftpd-tls.o: In function `tls_init_library':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:56: undefined reference to `SSL_library_init'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:57: undefined reference to `SSL_load_error_strings'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:60: undefined reference to `RAND_seed'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:58: undefined reference to `RAND_status'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:62: undefined reference to `SSLv23_server_method'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:62: undefined reference to `SSL_CTX_new'
pure_ftpd-tls.o: In function `tls_init_cache':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:49: undefined reference to `SSL_CTX_ctrl'
pure_ftpd-tls.o: In function `tls_init_library':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:66: undefined reference to `SSL_CTX_ctrl'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:67: undefined reference to `SSL_CTX_use_certificate_chain_file'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:72: undefined reference to `SSL_CTX_use_PrivateKey_file'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:76: undefined reference to `SSL_CTX_check_private_key'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:79: undefined reference to `SSL_CTX_ctrl'
pure_ftpd-tls.o: In function `tls_init_diffie':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:26: undefined reference to `BIO_new_file'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:29: undefined reference to `PEM_read_bio_DHparams'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:38: undefined reference to `SSL_CTX_ctrl'
pure_ftpd-tls.o: In function `tls_init_library':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:82: undefined reference to `RSA_generate_key'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:86: undefined reference to `SSL_CTX_ctrl'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:89: undefined reference to `RSA_free'
pure_ftpd-tls.o: In function `tls_init_diffie':
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:41: undefined reference to `DH_free'
/home/fork/src/pure-ftpd-1.0.22/src/tls.c:42: undefined reference to `BIO_free'
collect2: ld returned 1 exit status
make[2]: *** [pure-ftpd] Error 1
make[2]: Leaving directory `/home/fork/src/pure-ftpd-1.0.22/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/fork/src/pure-ftpd-1.0.22'
make: *** [all] Error 2
user@host:~/src/pure-ftpd-1.0.22$ grep RSA_generate_key /usr/include/openssl/rsa.h
RSA * RSA_generate_key(int bits, unsigned long e,void
int RSA_generate_key_ex(RSA *rsa, int bits, BIGNUM *e, BN_GENCB *cb);

kernel: 2.6.18-5
gcc: gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)
distro: debian 4.0
configure command:
./configure --with-mysql --with-tls --with-privsep --with-virtualhosts --with-quotas --with-pam --without-shadow --without-inetd --without-unicode

P.S.
i checked and inside my ssl's file i have those requested functions. i don't know why i get this error.

fork
5th November 2007, 06:05
fixed but i don't know why it works now
istead of an symlink if i do
export LDFLAGS=-L/usr/local/ssl/lib/
export CFLAGS=-I/usr/local/ssl/include

it works.
the error is on the heades.. but they are found in the configure script