rev 1.334.2.92

With `-static', only link statically against uninstalled libtool
libraries.  Fixes 1.5.x regression to match documented (and actual
1.4.x) behavior.

From libtool CVS
This commit is contained in:
brad 2005-11-02 02:47:09 +00:00
parent b277fb26e7
commit e6695723f7
3 changed files with 77 additions and 14 deletions

View File

@ -1,4 +1,4 @@
# $OpenBSD: Makefile,v 1.43 2005/09/09 17:30:32 brad Exp $
# $OpenBSD: Makefile,v 1.44 2005/11/02 02:47:09 brad Exp $
# $FreeBSD: Makefile,v 1.2 1998/09/23 16:15:53 vanilla Exp $
COMMENT= "generic shared library support script"
@ -6,7 +6,8 @@ COMMENT-ltdl= "GNU libtool system independent dlopen wrapper"
VERSION= 1.5.20
DISTNAME= libtool-${VERSION}
PKGNAME-ltdl= libltdl-${VERSION}
PKGNAME= ${DISTNAME}p1
PKGNAME-ltdl= libltdl-${VERSION}p1
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_GNU:=libtool/}

View File

@ -1,7 +1,24 @@
$OpenBSD: patch-libltdl_ltmain_sh,v 1.12 2005/09/09 17:30:32 brad Exp $
$OpenBSD: patch-libltdl_ltmain_sh,v 1.13 2005/11/02 02:47:09 brad Exp $
--- libltdl/ltmain.sh.orig Wed Aug 31 14:55:39 2005
+++ libltdl/ltmain.sh Thu Sep 1 21:44:47 2005
@@ -1984,6 +1984,17 @@ EOF
+++ libltdl/ltmain.sh Tue Nov 1 15:15:22 2005
@@ -1089,14 +1089,15 @@ EOF
if test -n "$link_static_flag"; then
dlopen_self=$dlopen_self_static
fi
+ prefer_static_libs=yes
else
if test -z "$pic_flag" && test -n "$link_static_flag"; then
dlopen_self=$dlopen_self_static
fi
+ prefer_static_libs=built
fi
build_libtool_libs=no
build_old_libs=yes
- prefer_static_libs=yes
break
;;
esac
@@ -1984,6 +1985,17 @@ EOF
;;
esac
for pass in $passes; do
@ -19,7 +36,7 @@ $OpenBSD: patch-libltdl_ltmain_sh,v 1.12 2005/09/09 17:30:32 brad Exp $
if test "$linkmode,$pass" = "lib,link" ||
test "$linkmode,$pass" = "prog,scan"; then
libs="$deplibs"
@@ -2245,20 +2256,20 @@ EOF
@@ -2245,20 +2257,20 @@ EOF
# It is a libtool convenience library, so add in its objects.
convenience="$convenience $ladir/$objdir/$old_library"
old_convenience="$old_convenience $ladir/$objdir/$old_library"
@ -50,7 +67,21 @@ $OpenBSD: patch-libltdl_ltmain_sh,v 1.12 2005/09/09 17:30:32 brad Exp $
continue
fi # $pass = conv
@@ -2644,7 +2655,7 @@ EOF
@@ -2445,8 +2457,12 @@ EOF
fi
link_static=no # Whether the deplib will be linked statically
+ use_static_libs=$prefer_static_libs
+ if test "$use_static_libs" = built && test "$installed" = yes ; then
+ use_static_libs=no
+ fi
if test -n "$library_names" &&
- { test "$prefer_static_libs" = no || test -z "$old_library"; }; then
+ { test "$use_static_libs" = no || test -z "$old_library"; }; then
if test "$installed" = no; then
notinst_deplibs="$notinst_deplibs $lib"
need_relink=yes
@@ -2644,7 +2660,7 @@ EOF
add_dir=
add=
# Finalize command for both is simple: just hardcode it.
@ -59,7 +90,7 @@ $OpenBSD: patch-libltdl_ltmain_sh,v 1.12 2005/09/09 17:30:32 brad Exp $
add="$libdir/$linklib"
elif test "$hardcode_minus_L" = yes; then
add_dir="-L$libdir"
@@ -5932,40 +5943,6 @@ relink_command=\"$relink_command\""
@@ -5932,40 +5948,6 @@ relink_command=\"$relink_command\""
# Exit here if they wanted silent mode.
test "$show" = : && exit $EXIT_SUCCESS

View File

@ -1,7 +1,24 @@
$OpenBSD: patch-ltmain_in,v 1.12 2005/09/09 17:30:32 brad Exp $
$OpenBSD: patch-ltmain_in,v 1.13 2005/11/02 02:47:09 brad Exp $
--- ltmain.in.orig Wed Aug 31 14:25:28 2005
+++ ltmain.in Thu Sep 1 21:43:55 2005
@@ -1984,6 +1984,17 @@ EOF
+++ ltmain.in Tue Nov 1 15:13:43 2005
@@ -1089,14 +1089,15 @@ EOF
if test -n "$link_static_flag"; then
dlopen_self=$dlopen_self_static
fi
+ prefer_static_libs=yes
else
if test -z "$pic_flag" && test -n "$link_static_flag"; then
dlopen_self=$dlopen_self_static
fi
+ prefer_static_libs=built
fi
build_libtool_libs=no
build_old_libs=yes
- prefer_static_libs=yes
break
;;
esac
@@ -1984,6 +1985,17 @@ EOF
;;
esac
for pass in $passes; do
@ -19,7 +36,7 @@ $OpenBSD: patch-ltmain_in,v 1.12 2005/09/09 17:30:32 brad Exp $
if test "$linkmode,$pass" = "lib,link" ||
test "$linkmode,$pass" = "prog,scan"; then
libs="$deplibs"
@@ -2245,20 +2256,20 @@ EOF
@@ -2245,20 +2257,20 @@ EOF
# It is a libtool convenience library, so add in its objects.
convenience="$convenience $ladir/$objdir/$old_library"
old_convenience="$old_convenience $ladir/$objdir/$old_library"
@ -50,7 +67,21 @@ $OpenBSD: patch-ltmain_in,v 1.12 2005/09/09 17:30:32 brad Exp $
continue
fi # $pass = conv
@@ -2644,7 +2655,7 @@ EOF
@@ -2445,8 +2457,12 @@ EOF
fi
link_static=no # Whether the deplib will be linked statically
+ use_static_libs=$prefer_static_libs
+ if test "$use_static_libs" = built && test "$installed" = yes ; then
+ use_static_libs=no
+ fi
if test -n "$library_names" &&
- { test "$prefer_static_libs" = no || test -z "$old_library"; }; then
+ { test "$use_static_libs" = no || test -z "$old_library"; }; then
if test "$installed" = no; then
notinst_deplibs="$notinst_deplibs $lib"
need_relink=yes
@@ -2644,7 +2660,7 @@ EOF
add_dir=
add=
# Finalize command for both is simple: just hardcode it.
@ -59,7 +90,7 @@ $OpenBSD: patch-ltmain_in,v 1.12 2005/09/09 17:30:32 brad Exp $
add="$libdir/$linklib"
elif test "$hardcode_minus_L" = yes; then
add_dir="-L$libdir"
@@ -5932,40 +5943,6 @@ relink_command=\"$relink_command\""
@@ -5932,40 +5948,6 @@ relink_command=\"$relink_command\""
# Exit here if they wanted silent mode.
test "$show" = : && exit $EXIT_SUCCESS