Forum

PolarSSL script and unexpected static library

Cinderella
15 April 2014, 23:53
Hi everybody ,

by launching PolarSSL script before compiling (to obtain 1.3.6 software version), I see that not only dynamic libraries are available in final package, but also a static one.

Finally, in hiawatha-9.4/usr/lib/hiawatha, you can find: libpolarssl.a libpolarssl.so libpolarssl.so.1.3.6 libpolarssl.so.6

This behavior increase size of the webserver package and I suppose that can be avoided, since I never see it before.

Am I right?

FYI, cmake options used:

cmake -DCMAKE_INSTALL_PREFIX=/usr -DCONFIG_DIR=/etc/hiawatha -DLOG_DIR=/var/log/hiawatha -DPID_DIR=/var/run -DWEBROOT_DIR=/var/www/hiawatha -DWORK_DIR=/var/lib/hiawatha

Thanks in advance.

Cinderella

Hiawatha version: Hiawatha v9.4, cache, IPv6, reverse proxy, SSL (1.3.6), URL toolkit, XSLT
Operating System: Puppy Linux 5.7.1
Hugo Leisink
16 April 2014, 01:19
I think I don't understand what your question is. Why run the PolarSSL script before compiling? Just follow the instructions from the README file.
Cinderella
16 April 2014, 13:35
Hi Hugo,

about use of PolarSSL script before compiling, I followed your post: https://www.hiawatha-webserver.org/weblog/62.
Unfortunately, README file doesn't help me to avoid building static library libpolarssl.a.
At last, I put "-DUSE_STATIC_POLARSSL_LIBRARY=OFF", as cmake option, and it works.
Hugo Leisink
16 April 2014, 13:41
Ow, wait. Now I understand what you mean. Yes, something changed in the PolarSSL 1.3.5 release. It indeed creates a static library if the the flag you mentioned is not specified. I already fixed this for the Hiawatha 9.5 release, but previous Hiawatha versions will have a problem with that. I've added this line to CMakeLists.txt at line 102:
option(USE_STATIC_POLARSSL_LIBRARY "Build PolarSSL static library." off)
Cinderella
16 April 2014, 13:53
Thank you, Hugo.
This topic has been closed.