[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Lynx-dev] problems building 2.8.7.dev.5 with SSL
From: |
Thomas Dickey |
Subject: |
Re: [Lynx-dev] problems building 2.8.7.dev.5 with SSL |
Date: |
Mon, 21 May 2007 11:03:46 -0400 (EDT) |
On Mon, 21 May 2007, Virden, Larry W. wrote:
I tried to build the latest lynx this morning, on a sparc solaris 9 system,
using Sun's C compiler. I was wondering if anyone had any advice on what
I might need to add.
$ export LIBS=" -L/projects/intranet/lib -L/volws/lwv28/ldatae/lib -L${gnu}/lib
-R/projects/intranet/lib:/volws/lwv28/ldatae/lib:${gnu}/lib -lz "
$ export CPPFLAGS="-I/projects/intranet/include -I/volws/lwv28/ldatae/include
-I${gnu}/include"
$ export CC=cc
$ export TN3270="gettso 2"
$ $PWD/configure --prefix=/projects/intranet \
--libdir=/projects/intranet/lib/lynx \
--includedir=${gnu}/include \
--with-included-gettext \
--with-ssl=/projects/intranet \
There's more than one potential pitfall here. The configure script
expects that "/projects/intranet" to be the directory containing the
library. It looks for something like ../include/openssl to see if it can
find the matching headers there. Since it failed the header check, it's
not finding the right ssl.h file (I ran into a similar problem last week
starting to check on a gnutls configuration).
skipped several thousand lines of output...
configure:9341: checking if we can link to ssl library
configure:9363: cc -o conftest -g -I/projects/intranet/include
-I/projects/intranet/include -I/volws/lwv28/ldatae/include
-I/projects/gnu/sparc-sun-solaris2.8/include -D__EXTENSIONS__ conftest.c
-L/projects/intranet/lib -lssl -lcrypto -L/projects/intranet/lib
-L/volws/lwv28/ldatae/lib -L/projects/gnu/sparc-sun-solaris2.8/lib
-R/projects/intranet/lib:/volws/lwv28/ldatae/lib:/projects/gnu/sparc-sun-solaris2.8/lib
-lz -lnsl -lsocket >&5
ld: warning: file /projects/intranet/lib/libssl.a(ssl_lib.o): wrong ELF class:
ELFCLASS64
As TG pointed out, this is saying the ssl library is 64-bits.
Sun's compiler uses -xarch=v9 (in $CFLAGS) to create 64-bit objects.
Rather than setting $CFLAGS, I generally just make a wrapper-script for
the compiler options, e.g.,
This is "cc-solaris64":
#!/bin/sh
cc -Xa -xtransition -xarch=v9 $*
then I just have to set $CC to "cc-solaris64" (which is easier to remember
than the compiler options).
Undefined first referenced
symbol in file
SSL_shutdown conftest.o
ld: fatal: Symbol referencing errors. No output written to conftest
configure:9366: $? = 1
configure: failed program was:
#line 9344 "configure"
#include "confdefs.h"
#include <stdio.h>
#ifdef USE_OPENSSL_INCL
#include <openssl/ssl.h>
#else
#include <ssl.h>
#endif
--
Thomas E. Dickey
http://invisible-island.net
ftp://invisible-island.net