net-ftp/lftp: Remove all LDFLAGS=.*-L.*\/lib (bug #646284).
authorJeroen Roovers <jer@gentoo.org>
Mon, 5 Feb 2018 14:59:59 +0000 (15:59 +0100)
committerJeroen Roovers <jer@gentoo.org>
Mon, 5 Feb 2018 15:01:19 +0000 (16:01 +0100)
15 files changed:
net-ftp/lftp/files/lftp-4.7.5-libdir-additional.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.7.5-libdir-configure.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.7.5-libdir-expat.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.7.5-libdir-libidn.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.7.5-libdir-openssl.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.7.5-libdir-readline.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.7.5-libdir-zlib.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.8.2-libdir-configure.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.8.2-libdir-libidn2.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.8.2-libdir-openssl.patch [new file with mode: 0644]
net-ftp/lftp/files/lftp-4.8.2-libdir-zlib.patch [new file with mode: 0644]
net-ftp/lftp/lftp-4.7.5.ebuild
net-ftp/lftp/lftp-4.8.2.ebuild
net-ftp/lftp/lftp-4.8.3.ebuild
net-ftp/lftp/lftp-9999.ebuild

diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-additional.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-additional.patch
new file mode 100644 (file)
index 0000000..bf7f0a9
--- /dev/null
@@ -0,0 +1,12 @@
+--- a/m4/lib-prefix.m4
++++ b/m4/lib-prefix.m4
+@@ -108,7 +108,8 @@
+         if test -z "$haveit"; then
+           if test -d "$additional_libdir"; then
+             dnl Really add $additional_libdir to $LDFLAGS.
+-            LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
++            dnl No, let's not do that.
++            :
+           fi
+         fi
+       fi
diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-configure.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-configure.patch
new file mode 100644 (file)
index 0000000..e855ac1
--- /dev/null
@@ -0,0 +1,10 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -186,7 +186,6 @@
+ esac
+ if test x$socks_loc != x; then
+-   LDFLAGS="$LDFLAGS -L$socks_loc/lib"
+    CPPFLAGS="$CPPFLAGS -I$socks_loc/include"
+ fi
diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-expat.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-expat.patch
new file mode 100644 (file)
index 0000000..f82afc7
--- /dev/null
@@ -0,0 +1,11 @@
+--- a/m4/ax_lib_expat.m4
++++ b/m4/ax_lib_expat.m4
+@@ -109,7 +109,7 @@
+     if test -n "$expat_prefix"; then
+         expat_include_dir="$expat_prefix/include"
+-        expat_ld_flags="-L$expat_prefix/lib"
++        expat_ld_flags="-L$libdir"
+         expat_lib_flags="-lexpat"
+         run_expat_test="yes"
+     elif test "$expat_requested" = "yes"; then
diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-libidn.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-libidn.patch
new file mode 100644 (file)
index 0000000..8901380
--- /dev/null
@@ -0,0 +1,10 @@
+--- a/m4/lftp.m4
++++ b/m4/lftp.m4
+@@ -319,7 +319,6 @@
+        libidn=$withval, libidn=yes)
+      if test "$libidn" != "no"; then
+        if test "$libidn" != "yes"; then
+-         LDFLAGS="${LDFLAGS} -L$libidn/lib"
+          CPPFLAGS="${CPPFLAGS} -I$libidn/include"
+        fi
+        AC_CHECK_HEADER(idna.h,
diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-openssl.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-openssl.patch
new file mode 100644 (file)
index 0000000..44c5239
--- /dev/null
@@ -0,0 +1,18 @@
+--- a/m4/ssl.m4
++++ b/m4/ssl.m4
+@@ -10,7 +10,6 @@
+               old_CPPFLAGS="$CPPFLAGS"
+               LIBS="$LIBS -lssl -lcrypto"
+               if test $loc != default; then
+-                      LDFLAGS="$LDFLAGS -L$loc/lib"
+                       CPPFLAGS="$CPPFLAGS -I$loc/include"
+               fi
+               AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <openssl/ssl.h>
+@@ -21,7 +20,6 @@
+               if test $found_loc != "none"; then
+                       lftp_cv_openssl="OPENSSL_LIBS=\"-lssl -lcrypto\""
+                       if test $found_loc != default; then
+-                              lftp_cv_openssl="$lftp_cv_openssl OPENSSL_LDFLAGS=\"-L$found_loc/lib -R$found_loc/lib\""
+                               lftp_cv_openssl="$lftp_cv_openssl OPENSSL_CPPFLAGS=-I$found_loc/include"
+                       fi
+                       break;
diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-readline.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-readline.patch
new file mode 100644 (file)
index 0000000..01c9371
--- /dev/null
@@ -0,0 +1,11 @@
+--- a/m4/lftp_lib_readline.m4
++++ b/m4/lftp_lib_readline.m4
+@@ -107,7 +107,7 @@
+       if test -f "$readline_include_dir/readline/readline.h"; then
+           readline_include_dir="$readline_include_dir/readline"
+       fi
+-        readline_ld_flags="-L$readline_prefix/lib"
++        readline_ld_flags="-L$libdir"
+         readline_lib_flags="-lreadline"
+         run_readline_test="yes"
+     elif test "$readline_requested" = "yes"; then
diff --git a/net-ftp/lftp/files/lftp-4.7.5-libdir-zlib.patch b/net-ftp/lftp/files/lftp-4.7.5-libdir-zlib.patch
new file mode 100644 (file)
index 0000000..9ec7c1b
--- /dev/null
@@ -0,0 +1,18 @@
+--- a/m4/ax_check_zlib.m4
++++ b/m4/ax_check_zlib.m4
+@@ -105,7 +105,6 @@
+   ZLIB_OLD_LDFLAGS=$LDFLAGS
+   ZLIB_OLD_CPPFLAGS=$CPPFLAGS
+   if test -n "${ZLIB_HOME}"; then
+-        LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib"
+         CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include"
+   fi
+   AC_LANG_SAVE
+@@ -120,7 +119,6 @@
+     #
+     m4_ifblank([$1],[
+                 CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include"
+-                LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib"
+                 LIBS="-lz $LIBS"
+                 AC_DEFINE([HAVE_LIBZ], [1],
+                           [Define to 1 if you have `z' library (-lz)])
diff --git a/net-ftp/lftp/files/lftp-4.8.2-libdir-configure.patch b/net-ftp/lftp/files/lftp-4.8.2-libdir-configure.patch
new file mode 100644 (file)
index 0000000..d8d620b
--- /dev/null
@@ -0,0 +1,18 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -186,7 +186,6 @@
+ esac
+ if test x$socks_loc != x; then
+-   LDFLAGS="$LDFLAGS -L$socks_loc/lib"
+    CPPFLAGS="$CPPFLAGS -I$socks_loc/include"
+ fi
+@@ -307,7 +306,6 @@
+ AX_CHECK_ZLIB([
+    AC_SUBST([ZLIB],[-lz])
+    r=""; test "$enable_rpath" = yes -a "$ZLIB_HOME" != /usr && r=" -R${ZLIB_HOME}/lib"
+-   AC_SUBST([ZLIB_LDFLAGS],["-L${ZLIB_HOME}/lib$r"])
+    AC_SUBST([ZLIB_CPPFLAGS],["-I${ZLIB_HOME}/include"])
+ ],[
+    AC_MSG_ERROR([cannot find -lz library, install zlib-devel package])
diff --git a/net-ftp/lftp/files/lftp-4.8.2-libdir-libidn2.patch b/net-ftp/lftp/files/lftp-4.8.2-libdir-libidn2.patch
new file mode 100644 (file)
index 0000000..cae07b9
--- /dev/null
@@ -0,0 +1,10 @@
+--- a/m4/lftp.m4
++++ b/m4/lftp.m4
+@@ -319,7 +319,6 @@
+        libidn2=$withval, libidn2=yes)
+      if test "$libidn2" != "no"; then
+        if test "$libidn2" != "yes"; then
+-         LDFLAGS="${LDFLAGS} -L$libidn2/lib"
+          CPPFLAGS="${CPPFLAGS} -I$libidn2/include"
+        fi
+        AC_CHECK_HEADER(idn2.h,
diff --git a/net-ftp/lftp/files/lftp-4.8.2-libdir-openssl.patch b/net-ftp/lftp/files/lftp-4.8.2-libdir-openssl.patch
new file mode 100644 (file)
index 0000000..f8bf45b
--- /dev/null
@@ -0,0 +1,18 @@
+--- a/m4/ssl.m4
++++ b/m4/ssl.m4
+@@ -10,7 +10,6 @@
+               old_CPPFLAGS="$CPPFLAGS"
+               LIBS="$LIBS -lssl -lcrypto"
+               if test $loc != default; then
+-                      LDFLAGS="$LDFLAGS -L$loc/lib"
+                       CPPFLAGS="$CPPFLAGS -I$loc/include"
+               fi
+               AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <openssl/ssl.h>
+@@ -22,7 +21,6 @@
+                       lftp_cv_openssl="OPENSSL_LIBS=\"-lssl -lcrypto\""
+                       if test $found_loc != default; then
+                               r=""; test "$enable_rpath" = yes -a "$found_loc" != /usr && r=" -R$found_loc/lib"
+-                              lftp_cv_openssl="$lftp_cv_openssl OPENSSL_LDFLAGS=\"-L$found_loc/lib$r\""
+                               lftp_cv_openssl="$lftp_cv_openssl OPENSSL_CPPFLAGS=-I$found_loc/include"
+                       fi
+                       break;
diff --git a/net-ftp/lftp/files/lftp-4.8.2-libdir-zlib.patch b/net-ftp/lftp/files/lftp-4.8.2-libdir-zlib.patch
new file mode 100644 (file)
index 0000000..7ff003f
--- /dev/null
@@ -0,0 +1,20 @@
+--- a/m4/ax_check_zlib.m4
++++ b/m4/ax_check_zlib.m4
+@@ -105,7 +105,6 @@
+   ZLIB_OLD_LDFLAGS="$LDFLAGS"
+   ZLIB_OLD_CPPFLAGS="$CPPFLAGS"
+   if test -n "${ZLIB_HOME}"; then
+-        LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib"
+         CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include"
+   fi
+   AC_LANG_SAVE
+@@ -118,8 +118,7 @@
+     # If both library and header were found, action-if-found
+     #
+     m4_ifblank([$1],[
+-              test "$enable_rpath" = yes -a "$ZLIB_HOME" != /usr && \
+-                  LDFLAGS="$LDFLAGS -R${ZLIB_HOME}/lib"
++              test "$enable_rpath" = yes -a "$ZLIB_HOME" != /usr
+                 LIBS="-lz $LIBS"
+                 AC_DEFINE([HAVE_LIBZ], [1],
+                           [Define to 1 if you have `z' library (-lz)])
index 138bce2efdea2efd93251cd97009a64ff3ab3a97..ed6f78f723f9f1067a979c73a70447b93d49b10d 100644 (file)
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
-inherit autotools eutils libtool multilib
+inherit autotools eutils libtool
 
 DESCRIPTION="A sophisticated ftp/sftp/http/https/torrent client and file transfer program"
 HOMEPAGE="https://lftp.tech/"
@@ -55,6 +55,13 @@ PATCHES=(
        "${FILESDIR}"/${PN}-4.0.2.91-lafile.patch
        "${FILESDIR}"/${PN}-4.5.5-am_config_header.patch
        "${FILESDIR}"/${PN}-4.7.0-gettext.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-additional.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-configure.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-expat.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-libidn.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-openssl.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-readline.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-zlib.patch
 )
 
 src_prepare() {
@@ -76,7 +83,6 @@ src_configure() {
                $(usex ssl "$(use_with !gnutls openssl ${EPREFIX}/usr)" '--without-openssl') \
                $(usex ssl "$(use_with gnutls)" '--without-gnutls') \
                --enable-packager-mode \
-               --libdir="${EPREFIX}/usr/$(get_libdir)" \
                --sysconfdir="${EPREFIX}"/etc/${PN} \
                --with-modules \
                --with-readline="${EPREFIX}"/usr \
index a6577ffe126d7c814a2d0eab50061149cde2251b..3ea35f33f1da41e23feee13b9ab687c3b4ba61f3 100644 (file)
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
-inherit autotools eutils libtool multilib
+inherit autotools eutils libtool
 
 DESCRIPTION="A sophisticated ftp/sftp/http/https/torrent client and file transfer program"
 HOMEPAGE="https://lftp.tech/"
@@ -57,6 +57,13 @@ PATCHES=(
        "${FILESDIR}"/${PN}-4.0.2.91-lafile.patch
        "${FILESDIR}"/${PN}-4.5.5-am_config_header.patch
        "${FILESDIR}"/${PN}-4.7.0-gettext.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-additional.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-expat.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-readline.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-configure.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-libidn2.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-openssl.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-zlib.patch
 )
 
 src_prepare() {
@@ -79,7 +86,6 @@ src_configure() {
                $(usex ssl "$(use_with !gnutls openssl ${EPREFIX}/usr)" '--without-openssl') \
                $(usex ssl "$(use_with gnutls)" '--without-gnutls') \
                --enable-packager-mode \
-               --libdir="${EPREFIX}/usr/$(get_libdir)" \
                --sysconfdir="${EPREFIX}"/etc/${PN} \
                --with-modules \
                --with-readline="${EPREFIX}"/usr \
index a6577ffe126d7c814a2d0eab50061149cde2251b..3ea35f33f1da41e23feee13b9ab687c3b4ba61f3 100644 (file)
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
-inherit autotools eutils libtool multilib
+inherit autotools eutils libtool
 
 DESCRIPTION="A sophisticated ftp/sftp/http/https/torrent client and file transfer program"
 HOMEPAGE="https://lftp.tech/"
@@ -57,6 +57,13 @@ PATCHES=(
        "${FILESDIR}"/${PN}-4.0.2.91-lafile.patch
        "${FILESDIR}"/${PN}-4.5.5-am_config_header.patch
        "${FILESDIR}"/${PN}-4.7.0-gettext.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-additional.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-expat.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-readline.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-configure.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-libidn2.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-openssl.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-zlib.patch
 )
 
 src_prepare() {
@@ -79,7 +86,6 @@ src_configure() {
                $(usex ssl "$(use_with !gnutls openssl ${EPREFIX}/usr)" '--without-openssl') \
                $(usex ssl "$(use_with gnutls)" '--without-gnutls') \
                --enable-packager-mode \
-               --libdir="${EPREFIX}/usr/$(get_libdir)" \
                --sysconfdir="${EPREFIX}"/etc/${PN} \
                --with-modules \
                --with-readline="${EPREFIX}"/usr \
index 75206b9924068222d7acd05a6f4d63a49fa43ada..d8dca66a3ca7cd72873c9bdeabd637416e71ccf3 100644 (file)
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
-inherit autotools eutils git-r3 libtool multilib
+inherit autotools eutils git-r3 libtool
 
 DESCRIPTION="A sophisticated ftp/sftp/http/https/torrent client and file transfer program"
 HOMEPAGE="https://lftp.tech/"
@@ -19,7 +19,7 @@ RDEPEND="
        dev-libs/expat
        sys-libs/zlib
        convert-mozilla-cookies? ( dev-perl/DBI )
-       idn? ( net-dns/libidn )
+       idn? ( net-dns/libidn2 )
        socks5? (
                >=net-proxy/dante-1.1.12
                virtual/pam
@@ -52,6 +52,12 @@ DOCS=(
 )
 PATCHES=(
        "${FILESDIR}"/${PN}-4.5.5-am_config_header.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-expat.patch
+       "${FILESDIR}"/${PN}-4.7.5-libdir-readline.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-configure.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-libidn2.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-openssl.patch
+       "${FILESDIR}"/${PN}-4.8.2-libdir-zlib.patch
 )
 
 src_prepare() {
@@ -69,12 +75,11 @@ src_configure() {
        econf \
                $(use_enable ipv6) \
                $(use_enable nls) \
-               $(use_with idn libidn) \
+               $(use_with idn libidn2) \
                $(use_with socks5 socksdante "${EPREFIX}"/usr) \
                $(usex ssl "$(use_with !gnutls openssl ${EPREFIX}/usr)" '--without-openssl') \
                $(usex ssl "$(use_with gnutls)" '--without-gnutls') \
                --enable-packager-mode \
-               --libdir="${EPREFIX}/usr/$(get_libdir)" \
                --sysconfdir="${EPREFIX}"/etc/${PN} \
                --with-modules \
                --with-readline="${EPREFIX}"/usr \