Subject: buildlink3, sed and Solaris
To: None <tech-pkg@netbsd.org>
From: Gavan Fantom <gavan@coolfactor.org>
List: tech-pkg
Date: 01/06/2004 13:01:50
Since bl3ification of libtool, I'm now unable to build libtool-base on
Solaris.

What's involved in making buildlink3 sed-friendly?

The relevant bits of the build log are here..

updating cache ./config.cache
AR="ar" CC="g++" CFLAGS="-O" CPPFLAGS=" "  LTCC="gcc" FILE="@FILE@"
LD="ld" LDFLAGS=""  LIBS="" LN_S="ln -s" NM="/usr/ccs/bin/nm -p"
RANLIB="ranlib"  STRIP="strip" AS="" DLLTOOL=""  OBJDUMP=""  objext="o"
exeext=""  reload_flag="-r"  deplibs_check_method="pass_all"
file_magic_cmd="$MAGIC_CMD"  /bin/ksh ./ltconfig
--cache-file=./config.cache --with-gcc --enable-dlopen --srcdir=.
--add-tag=CXX --output=libtoolT ./ltcf-cxx.sh i386-sun-solaris2
loading cache ./config.cache within ltconfig
checking host system type... i386-sun-solaris2
checking build system type... i386-sun-solaris2
sed: Too many commands, last:
s|_bUiLdLiNk__usr_pkgsrc_devel_libtool-base_work_.buildlink#\([/
`"':;]\)|/usr/pkgsrc/devel/libtool-base/work/.buildlink\1|g
g++: No input files
./ltconfig: --version: not found
sed: Too many commands, last:
s|_bUiLdLiNk__usr_pkgsrc_devel_libtool-base_work_.buildlink#\([/
`"':;]\)|/usr/pkgsrc/devel/libtool-base/work/.buildlink\1|g
g++: No input files
checking for objdir... .libs
checking for g++ option to produce PIC... -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works... yes

[...]

checking whether to build shared libraries... yes
checking whether to build static libraries... yes
appending configuration tag "GCJ" to libtoolT
rm -f libtool
mv libtoolT libtool
CONFIG_FILES=libtoolize CONFIG_HEADERS= ./config.status
creating libtoolize
chmod +x libtoolize
Making all in libltdl
/bin/ksh ./libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I.     -O
-c ltdl.c
mkdir .libs
gcc -DHAVE_CONFIG_H -I. -I. -I. -O -c ltdl.c  -fPIC -DPIC -o .libs/ltdl.o
gcc -DHAVE_CONFIG_H -I. -I. -I. -O -c ltdl.c -o ltdl.o >/dev/null 2>&1
/bin/ksh ./libtool --mode=link gcc  -O  -o libltdl.la -rpath /usr/pkg/lib
-no-undefined -version-info 3:0:0 ltdl.lo
ld -G -z defs -h libltdl.so.3 -o .libs/libltdl.so.3.0  .libs/ltdl.o  -lc
sed: Too many commands, last:
s|_bUiLdLiNk__usr_pkgsrc_devel_libtool-base_work_.buildlink#\([/
`"':;]\)|/usr/pkgsrc/devel/libtool-base/work/.buildlink\1|g
Undefined                       first referenced
 symbol                             in file
__ctype                             .libs/ltdl.o
malloc                              .libs/ltdl.o
sprintf                             .libs/ltdl.o
fclose                              .libs/ltdl.o
getenv                              .libs/ltdl.o
strncpy                             .libs/ltdl.o
strncmp                             .libs/ltdl.o
strcat                              .libs/ltdl.o
strrchr                             .libs/ltdl.o
strchr                              .libs/ltdl.o
free                                .libs/ltdl.o
strcmp                              .libs/ltdl.o
fgets                               .libs/ltdl.o
fopen                               .libs/ltdl.o
strcpy                              .libs/ltdl.o
memcpy                              .libs/ltdl.o
ld: fatal: Symbol referencing errors. No output written to
.libs/libltdl.so.3.0
*** Error code 1

Stop.
bmake: stopped in /usr/pkgsrc/devel/libtool-base/work/libtool-ml/libltdl


-- 
Gillette - the best a man can forget