* libltdl/m4/libtool.m4 (_LT_ENABLE_LOCK) [*-*-solaris*):
Determine GNU ld options for 64-bit Solaris 2/x86. Detect gld
2.21 _sol2 emulations.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
+2011-02-01 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> (tiny change)
+
+ Fix LD setting for 64-bit Solaris 2/x86.
+ * libltdl/m4/libtool.m4 (_LT_ENABLE_LOCK) [*-*-solaris*):
+ Determine GNU ld options for 64-bit Solaris 2/x86. Detect gld
+ 2.21 _sol2 emulations.
+
2011-01-27 Peter O'Gorman <peter@pogma.com>
Don't loop through wrapper script arguments unnecessarily.
CFLAGS="$SAVE_CFLAGS"
fi
;;
-sparc*-*solaris*)
+*-*solaris*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.o` in
*64-bit*)
case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
+ yes*)
+ case $host in
+ i?86-*-solaris*)
+ LD="${LD-ld} -m elf_x86_64"
+ ;;
+ sparc*-*-solaris*)
+ LD="${LD-ld} -m elf64_sparc"
+ ;;
+ esac
+ # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
+ if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
+ LD="${LD-ld}_sol2"
+ fi
+ ;;
*)
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
LD="${LD-ld} -64"