Building libwww for Solaris
Okay, I had some serious issues building libwww for Solaris, particularly with SSL support.
The first thing I had to do was fix libtool. I got errors about bad arguments supplied to test. The libtool script is huge, with lots of incantations of the test command, and of course the error message didn't tell me which line the error occurred on.
I don't know what moron wrote the libtool script, but in many cases, an environment variable was supplied as an argument to test, and it wasn't quoted. This means that, if the environment variable is empty, no argument is supplied. If you quote it, an empty argument is supplied, and test doesn't get confused. Experienced shell script authors know this, but this wasn't done for dozens of occurances in the script. If one knows that the variable will never be empty, it's not a problem, but obviously some variables were empty that no one expected.
libtool is re-created each time configure is executed, so you actually need to edit the source file, which is config/ltmain.sh. Look for every line in which test is called and an environment variable is supplied, and if it isn't quoted, then put double quotes around it. The script is over 5000 lines long, so it takes a while.
For example, if a line reads:
if test -n $prev; then
change it to:
if test -n "$prev"; then
After you have finished fixing everything, run ./configure again to recreate the libtool script.
OpenSSL include files
I don't know if this is true for all distributions of OpenSSL and/or libwww, but I had issues on my system. Basically, libwww attempts to include "ssl.h" and "rand.h" but the rest of the include files are included with the openssl directory, such as "openssl/file.h". The trouble is that they are all actually in the same directory.
As far as I know, there is no way to tell configure what include directory to use, so I had to modify the script. We had the include files in a weird directory, anyway.
Look for where the sslinc variable is set, and add or modify the first part of the if statement to read:
if test -d '/usr/local/svvs/include/'; then sslinc="-I/usr/local/svvs/include -I/usr/local/svvs/include/openssl"
Note that I have set -I options for both directories. This satisfies both incantations of the #include directives.
So, then all I had to do is follow the normal directions:
./configure --with-ssl make make install