On Wed, Sep 19, 2012 at 02:54:56PM -0700, Emanuel Patern wrote: > I tried to build curl with polarssl instead of openssl. Here what I did : > > Libcurl version : 7.27.0 > Polar ssl version : 1.1.4 > > To build polar ssl I did : > > make CC=gcc APPS= > make DESTDIR=/c/pssl install > > To build curl I did : > perl Configure CFLAGS="-Os -ffunction-sections -fdata-sections -flto" > LDFLAGS="-Wl,-s -Wl,-Bsymbolic -Wl,--gc-sections -flto -Os" > --without-libidn,zlib,ldap-lib > --disable-ipv6,manual,shared,verbose,debug,gopher --enable-hidden-symbols > --enable-static --prefix=/c/curl --with-polarssl=/c/polarssl
I don't know what "perl Configure" does but --without- and --disable- arguments can't be separated by commas like this with autoconf. The directory specified with the --with-polarssl= option is not the same as that you show for the PolarSSL build above. If PolarSSL uses an autoconf-like build system, then DESTDIR isn't going to produce the right output directory structure; in autoconf-based builds, the --prefix option does that. Rather than adding all those optimization options right away, try getting a standard build working first. If one of those optimizations isn't compatible with your build, it's just going to get in the way. > Now Everything looks okay, I have added licurl.a, libpolarssl.a into my > project with link option -DCURL_STATICLIB. After Compile I get those errors > during linking : To your project? I don't know what kind of build system you're using, but clearly, it's not libcurl's, which increases the chance dramatically that the problem is not in curl but rather your environment. > ================================================= > ...\libcurl.a(libcurl_la-polarssl.o):polarssl.c:(.text$polarssl_connect_step2+0x4b)||undefined > reference to `ssl_handshake'| > ...\libcurl.a(libcurl_la-polarssl.o):polarssl.c:(.text$polarssl_connect_step2+0xd6)||undefined > reference to `ssl_get_ciphersuite'| What does the link command-line look like? It looks like the PolarSSL library isn't being linked. It may be the order of the library given on the link command-line is wrong. >>> Dan ------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-library Etiquette: http://curl.haxx.se/mail/etiquette.html