Missing stpcpy on Solaris 8

Boban Acimovic acim@mbl.is
Mon, 18 Feb 2002 19:56:06 +0100


Hello,

I tried to compile libgcrypt 1.1.6 on Solaris 8, but compile fails with
message:

gcc -DHAVE_CONFIG_H -I. -I. -I..     -O2 -Wall -c `test -f testapi.c || echo
'./'`testapi.c
/bin/sh ../libtool --mode=link gcc  -O2 -Wall   -o testapi  testapi.o
libgcrypt.la -ldl -lnsl  -lsocket
gcc -O2 -Wall -o .libs/testapi testapi.o
 ./.libs/libgcrypt.so -ldl -lnsl -lsocket -Wl,--rpath -Wl,/usr/local/lib
./.libs/libgcrypt.so: undefined reference to `stpcpy'
./.libs/libgcrypt.so: undefined reference to `_gcry_rndunix_constructor'
./.libs/libgcrypt.so: undefined reference to `__udiv_qrnnd'
./.libs/libgcrypt.so: undefined reference to
`register_internal_cipher_extension'
collect2: ld returned 1 exit status
make[3]: *** [testapi] Error 1
make[3]: Leaving directory `/usr/local/src/libgcrypt-1.1.6/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/local/src/libgcrypt-1.1.6/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/libgcrypt-1.1.6'
make: *** [all] Error 2

I fixed missing stpcpy function adding ../jnlib/stringhelp.o to the last gcc
line:

make  all-am
make[1]: Entering directory `/usr/local/src/libgcrypt-1.1.6/src'
/bin/sh ../libtool --mode=link gcc  -O2 -Wall   -o testapi  testapi.o
libgcrypt.la -ldl -lnsl  -lsocket ../jnlib/stringhelp.o
gcc -O2 -Wall -o .libs/testapi testapi.o ../jnlib/stringhelp.o
./.libs/libgcrypt.so -ldl -lnsl -lsocket -Wl,--rpath -Wl,/usr/local/lib
./.libs/libgcrypt.so: undefined reference to `_gcry_rndunix_constructor'
./.libs/libgcrypt.so: undefined reference to `__udiv_qrnnd'
./.libs/libgcrypt.so: undefined reference to
`register_internal_cipher_extension'
collect2: ld returned 1 exit status
make[1]: *** [testapi] Error 1
make[1]: Leaving directory `/usr/local/src/libgcrypt-1.1.6/src'
make: *** [all] Error 2

But problem with _gcry_rndunix_constructor, __udiv_qrnnd and
register_internal_cipher_extension remains. I saw some functions with
similar names having underscore at the beginning and without underscore and
I supose this is just problem with function names. Probably configure script
fails to make the right configuration.

Machine info: SunOS riemann 5.8 Generic_108528-12 sun4u sparc SUNW,Ultra-4

I need to compile libgcrypt to be able to upgrade AIDE to version 0.8.
Please let me know what shell I do to fix this.

Best regards,
Boban Acimovic
www.mbl.is