#! /bin/sh# link.test - check that .lo files aren't made into programs.# Test script header.need_prefix=noif test -z "$srcdir"; thensrcdir=`echo "$0" | sed 's%/[^/]*$%%'`test "$srcdir" = "$0" && srcdir=.test "${VERBOSE+set}" != "set" && VERBOSE=yesfi. $srcdir/defs || exit 1rm -f hell.locat > hell.lo <<EOF# Generated by libtoolpic_object=nonenon_pic_object=hell.oEOF# Try a sample link command.linkresult=`$libtool -n --mode=link $CC -o something foo.o hell.lo`res=$?rm -f hell.lotest $res -eq 0 || exit 1echo "$linkresult"case "$linkresult" in*".lo "*)echo "$0: .lo files should not be linked into programs"exit 1;;esacexit 0