]> granicus.if.org Git - sudo/commitdiff
Allow the user to specify and alternate libtool
authorTodd C. Miller <Todd.Miller@courtesan.com>
Sun, 28 Oct 2012 16:58:48 +0000 (12:58 -0400)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Sun, 28 Oct 2012 16:58:48 +0000 (12:58 -0400)
INSTALL
configure
configure.in

diff --git a/INSTALL b/INSTALL
index 964d75ef26c0815cdeb909ef44a359c0b5f7ab7b..9effdd1465f6eb2d5fadd6039a4c6ba6aecd9f73 100644 (file)
--- a/INSTALL
+++ b/INSTALL
@@ -584,6 +584,15 @@ The following options are also configurable at runtime:
         specified, I/O logs will be stored in the indicated directory
         instead.
 
+  --with-libtool=PATH
+        By default, sudo will use the included version of libtool
+        to build shared libraries.  The --with-libtool option can
+        be used to specify a different version of libtool to use.
+        The special values "system" and "builtin" can be used in
+        place of a path to denote the default system libtool (obtained
+        via the user's PATH) and the default libtool that comes
+        with sudo.
+
   --disable-authentication
        By default, sudo requires the user to authenticate via a
        password or similar means.  This options causes sudo to
index cdc14af295b0ef78bf54ca7afc61ced63a439848..a2305cbdbc88cea50bcc0076c00197039186c626 100755 (executable)
--- a/configure
+++ b/configure
@@ -907,6 +907,7 @@ enable_fast_install
 with_gnu_ld
 with_sysroot
 enable_libtool_lock
+with_libtool
 with_noexec
 with_netsvc
 enable_sia
@@ -1673,6 +1674,7 @@ Optional Packages:
   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
   --with-sysroot=DIR Search for dependent libraries within DIR
                         (or the compiler's sysroot if not specified).
+  --with-libtool=PATH     specify path to libtool
   --with-noexec=PATH      fully qualified pathname of sudo_noexec.so
   --with-netsvc[=PATH]    path to netsvc.conf
   --with-pam-login        enable specific PAM session for sudo -i
@@ -13612,6 +13614,21 @@ CC="$lt_save_CC"
 
 
 
+
+# Check whether --with-libtool was given.
+if test "${with_libtool+set}" = set; then :
+  withval=$with_libtool; case $with_libtool in
+    yes|builtin) ;;
+    no)                as_fn_error $? "\"--without-libtool not supported.\"" "$LINENO" 5
+               ;;
+    system)    LIBTOOL=libtool
+               ;;
+    *)         LIBTOOL="$with_libtool"
+               ;;
+esac
+fi
+
+
 if test "$enable_shared" = "no"; then
     with_noexec=no
     enable_dlopen=no
index 7d5c4c2f8fcd6121a13ee74839b28f6421157c9f..9ae795a58c43c2e70ca22a21326da2a9eee63d20 100644 (file)
@@ -1435,6 +1435,21 @@ AC_CONFIG_MACRO_DIR([m4])
 LT_PREREQ([2.2.6b])
 LT_INIT([dlopen])
 
+dnl
+dnl Allow the user to specify an alternate libtool.
+dnl XXX - should be able to skip LT_INIT if we are using a different libtool
+dnl
+AC_ARG_WITH(libtool, [AS_HELP_STRING([--with-libtool=PATH], [specify path to libtool])],
+[case $with_libtool in
+    yes|builtin) ;;
+    no)                AC_MSG_ERROR(["--without-libtool not supported."])
+               ;;
+    system)    LIBTOOL=libtool
+               ;;
+    *)         LIBTOOL="$with_libtool"
+               ;;
+esac])
+
 dnl
 dnl Defer with_noexec until after libtool magic runs
 dnl