Those are the header you included. But you need to link against libs after compilation. What platform(win/linux) and What tool(studio/shell)? -Anand
On Fri, Feb 26, 2010 at 1:59 PM, xabi esteban <xab...@msn.com> wrote: > I don't understand you. I put the libreries in the includes #include > <openssl/ssl.h> #include <....> > but i'din't put nothing more. > How i could link with this libreries? I didn't found any example. > > Thanks > > ------------------------------ > Date: Fri, 26 Feb 2010 12:39:57 -0500 > Subject: Re: Error copiling ssl: undefined reference > From: anand.apa...@gmail.com > To: openssl-users@openssl.org > > > Do you link against correct libraries? Try linking with ssleay and libeay. > -Anand > > On Fri, Feb 26, 2010 at 12:08 PM, xabi esteban <xab...@msn.com> wrote: > > Hello: > I'm trying to use the SSL libreries. When I try to comipile my code y > always obtain the same error: > > cli.c:(.text+0x20): undefined reference to `SSL_library_init' > cli.c:(.text+0x25): undefined reference to `SSLv2_client_method' > cli.c:(.text+0x30): undefined reference to `SSL_load_error_strings' > cli.c:(.text+0x3e): undefined reference to `SSL_CTX_new' > cli.c:(.text+0x6f): undefined reference to `ERR_print_errors_fp' > cli.c:(.text+0x150): undefined reference to `SSL_new' > cli.c:(.text+0x183): undefined reference to `SSL_set_fd' > cli.c:(.text+0x191): undefined reference to `SSL_connect' > cli.c:(.text+0x1ad): undefined reference to `ERR_print_errors_fp' > cli.c:(.text+0x1c7): undefined reference to `SSL_get_current_cipher' > cli.c:(.text+0x1cf): undefined reference to `SSL_CIPHER_get_name' > cli.c:(.text+0x1ed): undefined reference to `SSL_get_peer_certificate' > cli.c:(.text+0x222): undefined reference to `X509_get_subject_name' > cli.c:(.text+0x23a): undefined reference to `X509_NAME_oneline' > cli.c:(.text+0x279): undefined reference to `CRYPTO_free' > cli.c:(.text+0x287): undefined reference to `X509_get_issuer_name' > cli.c:(.text+0x29f): undefined reference to `X509_NAME_oneline' > cli.c:(.text+0x2de): undefined reference to `CRYPTO_free' > cli.c:(.text+0x2ec): undefined reference to `X509_free' > cli.c:(.text+0x30a): undefined reference to `SSL_write' > cli.c:(.text+0x326): undefined reference to `ERR_print_errors_fp' > cli.c:(.text+0x352): undefined reference to `SSL_read' > cli.c:(.text+0x36e): undefined reference to `ERR_print_errors_fp' > cli.c:(.text+0x3b6): undefined reference to `SSL_shutdown' > cli.c:(.text+0x3d2): undefined reference to `SSL_free' > cli.c:(.text+0x3e0): undefined reference to `SSL_CTX_free' > > I'm trying with differets codes from the web and with the examples in > demos/ssl > In the includes y put the includes: > > #include <openssl/crypto.h> > #include <openssl/x509.h> > #include <openssl/pem.h> > #include <openssl/ssl.h> > #include <openssl/err.h> > > And the all the files are in /usr/includes/openssl > > Any idea? thanks > <http://www.messengergamesclub.com/spain/> > ------------------------------ > Navega con el navegador más seguro de todos. ¡Descárgatelo > ya!<http://www.vivelive.com/internetexplorer8> > > > > ------------------------------ > Navega con el navegador más seguro de todos. ¡Descárgatelo > ya!<http://www.vivelive.com/internetexplorer8> >