Compiling 1.4.30 on Solaris 9

Added by dkinney over 2 years ago

Hello,

I am trying to compile version 1.4.30 on solaris 9 both sparc and x86, but run into the following problem. The last version I am successfully able to compile version 1.4.22.

I have included what I see as the difference when compiling 1.4.22 and made it bold. Is this actually and error with libtool?

I am able to build 1.4.30 if I copy over the libtool file from version 1.4.22. Is this advised?

-------------------------------------------------------------------------------------------------------------------------------------
ERROR

make all-recursive
Making all in src
\
source='lemon.c' object='lemon.o' libtool=no \
DEPDIR=.deps depmode=none /bin/bash ../depcomp \
cc -DHAVE_CONFIG_H -DHAVE_VERSION_H -DLIBRARY_DIR="\"/usr/local/lib\"" -DSBIN_DIR="\"/usr/local/sbin\"" -I. -I.. -D_REENTRANT -D__EXTENSIONS__ -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES -g -c lemon.c
/bin/bash ../libtool --tag=CC --mode=link cc -g -o lemon lemon.o -lresolv -lnsl -lsocket
libtool: link: cc -g -o lemon lemon.o -lresolv -lnsl -lsocket
rm -f configparser.h
../src/lemon -q ./configparser.y ./lempar.c
rm -f mod_ssi_exprparser.h
../src/lemon -q ./mod_ssi_exprparser.y ./lempar.c
make all-am
\
source='mod_flv_streaming.c' object='mod_flv_streaming.lo' libtool=yes \
DEPDIR=.deps depmode=none /bin/bash ../depcomp \
/bin/bash ../libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -DHAVE_VERSION_H -DLIBRARY_DIR="\"/usr/local/lib\"" -DSBIN_DIR="\"/usr/local/sbin\"" -I. -I.. -D_REENTRANT -D__EXTENSIONS__ -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES -g -c -o mod_flv_streaming.lo mod_flv_streaming.c
libtool: compile: cc -DHAVE_CONFIG_H -DHAVE_VERSION_H -DLIBRARY_DIR=\"/usr/local/lib\" -DSBIN_DIR=\"/usr/local/sbin\" -I. -I.. -D_REENTRANT -D__EXTENSIONS__ -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES -g -c mod_flv_streaming.c -KPIC -DPIC -o .libs/mod_flv_streaming.o

/bin/bash ../libtool --tag=CC --mode=link cc -g -module -export-dynamic -avoid-version -no-undefined -o mod_flv_streaming.la -rpath /usr/local/lib mod_flv_streaming.lo -lresolv -lnsl -lsocket
libtool: link: cc -G -z defs -h mod_flv_streaming.so -o .libs/mod_flv_streaming.so .libs/mod_flv_streaming.o -lresolv -lnsl -lsocket -lc

Undefined first referenced
symbol in file
buffer_copy_string_buffer .libs/mod_flv_streaming.o
http_chunk_append_file .libs/mod_flv_streaming.o
data_string_init .libs/mod_flv_streaming.o
buffer_init_string .libs/mod_flv_streaming.o
array_get_element .libs/mod_flv_streaming.o
buffer_copy_string_len .libs/mod_flv_streaming.o
buffer_is_empty .libs/mod_flv_streaming.o
response_header_overwrite .libs/mod_flv_streaming.o
config_check_cond .libs/mod_flv_streaming.o
array_free .libs/mod_flv_streaming.o
array_init .libs/mod_flv_streaming.o
config_insert_values_global .libs/mod_flv_streaming.o
stat_cache_get_entry .libs/mod_flv_streaming.o
buffer_init .libs/mod_flv_streaming.o
buffer_free .libs/mod_flv_streaming.o
chunkqueue_get_append_buffer .libs/mod_flv_streaming.o
array_insert_unique .libs/mod_flv_streaming.o
array_get_unused_element .libs/mod_flv_streaming.o
array_reset .libs/mod_flv_streaming.o
buffer_is_equal_string .libs/mod_flv_streaming.o
ld: fatal: Symbol referencing errors. No output written to .libs/mod_flv_streaming.so
  • Error code 1
    make: Fatal error: Command failed for target `mod_flv_streaming.la'
    Current working directory /testing/lighttpd-1.4.30/src
  • Error code 1
    make: Fatal error: Command failed for target `all'
    Current working directory /testing/lighttpd-1.4.30/src
  • Error code 1
    make: Fatal error: Command failed for target `all-recursive'
    Current working directory /testing/lighttpd-1.4.30
  • Error code 1
    make: Fatal error: Command failed for target `all'
    -------------------------------------------------------------------------------------------------------------------------------------

-------------------------------------------------------------------------------------------------------------------------------------
Success with version 1.4.22
....
source='mod_flv_streaming.c' object='mod_flv_streaming.lo' libtool=yes \
DEPDIR=.deps depmode=none /bin/bash ../depcomp \
/bin/bash ../libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -DLIBRARY_DIR="\"/usr/local/lib\"" -DSBIN_DIR="\"/usr/local/sbin\"" -I. -I.. -D_REENTRANT -D__EXTENSIONS__ -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES -g -c -o mod_flv_streaming.lo mod_flv_streaming.c
cc -DHAVE_CONFIG_H -DLIBRARY_DIR=\"/usr/local/lib\" -DSBIN_DIR=\"/usr/local/sbin\" -I. -I.. -D_REENTRANT -D__EXTENSIONS__ -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES -g -c mod_flv_streaming.c -KPIC -DPIC -o .libs/mod_flv_streaming.o

/bin/bash ../libtool --tag=CC --mode=link cc -g -module -export-dynamic -avoid-version -no-undefined -o mod_flv_streaming.la -rpath /usr/local/lib mod_flv_streaming.lo -lresolv -lnsl -lsocket
/usr/bin/ld -G -z text -h mod_flv_streaming.so -o .libs/mod_flv_streaming.so .libs/mod_flv_streaming.o -lresolv -lnsl -lsocket -lc
creating mod_flv_streaming.la

(cd .libs && rm -f mod_flv_streaming.la && ln -s ../mod_flv_streaming.la mod_flv_streaming.la)
source='mod_evasive.c' object='mod_evasive.lo' libtool=yes \
DEPDIR=.deps depmode=none /bin/bash ../depcomp \

....
-------------------------------------------------------------------------------------------------------------------------------------


Replies (3)

RE: Compiling 1.4.30 on Solaris 9 - Added by dkinney over 2 years ago

Solution Found:

I was able to get the compile to work as follows. Before running ./configure edit the configure file as follows.

Line 10271
  1. OLD ##
    solaris*)
    no_undefined_flag=' -z defs'
    if test "$GCC" = yes; then
    wlarc='${wl}'
  1. NEW ##
    solaris*)
    no_undefined_flag=' -z text'
    if test "$GCC" = yes; then
    wlarc='${wl}'

RE: Compiling 1.4.30 on Solaris 9 - Added by stbuehler over 2 years ago

well, the configure file is created by autuconf; the problem is in the included "libtool.m4" - so it probably is a libtool bug. you could try running the ./autogen.sh script and see if it got fixed on your own platform.

http://lists.gnu.org/archive/html/autoconf/2002-03/msg00195.html (2002... seems quite old)

RE: Compiling 1.4.30 on Solaris 9 - Added by solarized over 1 year ago

The link-error still happens with lighttpd-1.3.32 and Solaris 11.1.

(1-3/3)