W3C home > Mailing lists > Public > www-lib@w3.org > April to June 2000

Re: Static compiling

From: Christopher Keller <christopher.keller@epropose.com>
Date: Mon, 01 May 2000 13:20:04 -0700
Message-ID: <390DE6F4.CA71A3E1@epropose.com>
To: www-lib@w3.org
Yeah, that's pretty much what I figured. Putting in "-Wl, -Bstatic" and
just having "-static" seem to imply the same thing (at least with gcc).
I tested both just in case. I'm getting the same error though, so they
have to be indentical. I'm including a copy of the link error I'm
getting just in case it rings any bells with anyone. As far as the
install for libwww went,  I just followed the unix directions for
generating a configure file, then ran "make; make install". It compiled
and installed without any errors, and dynamic linking seems to work as
expected. I've been long away from the  C world (having been in the
realms of Perl and Java for the past few years), so it's entirely
possible I'm doing something stupid.

In case it matters, I'm on a Inetl/Linux box running Red Hat 6.2. I'm
using a fairly new version of libwww (downloaded it late last week).
Thanks for any help anyone has.

I'd  building a tool for stress testing web servers/servlet engines and
would like to be able to distribute a binary without having to install
any libraries.

% gcc -o static_chunk chunk.o  -Wl,-Bstatic  `libwww-config --libs`

/usr/local/lib/libwwwapp.a(HTInit.o): In function `HTConverterInit':

/home/ckeller/software/libwww/Library/src/HTInit.c:84: undefined reference to `HTXML_new'

/home/ckeller/software/libwww/Library/src/HTInit.c:85: undefined reference to `HTXML_new'

collect2: ld returned 1 exit status

Christopher Keller
Senior Software Engineer
ePropose, Inc -- San Francisco, CA
Received on Monday, 1 May 2000 16:20:02 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:33:52 UTC