From ff35f7147754313eeec7703ac46c00a56195b2e8 Mon Sep 17 00:00:00 2001 From: Pavel Raiskup Date: Wed, 24 Apr 2013 08:31:15 +0200 Subject: [PATCH] libtoolize: allow root to copy files to NFS Version: 2.4.2-14 Resolves: #740079 --- libtool-2.4.2-tar-no-owner.patch | 30 ++++++++++++++++++++++++++++++ libtool.spec | 11 ++++++++++- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 libtool-2.4.2-tar-no-owner.patch diff --git a/libtool-2.4.2-tar-no-owner.patch b/libtool-2.4.2-tar-no-owner.patch new file mode 100644 index 0000000..e64bb34 --- /dev/null +++ b/libtool-2.4.2-tar-no-owner.patch @@ -0,0 +1,30 @@ +diff --git a/libtoolize.in b/libtoolize.in +index 2bce172..16b764d 100644 +--- a/libtoolize.in ++++ b/libtoolize.in +@@ -69,6 +69,7 @@ + # General help using GNU software: . + + : ${TAR=tar} ++test "$TAR" = "tar" && : ${TAR_NO_OWNER=--no-same-owner} + + PROGRAM=libtoolize + +@@ -1279,7 +1280,7 @@ func_copy_cb () + $RM "$my_destdir/$my_file" + if $opt_copy; then + if { ( cd "$my_srcdir" && $TAR chf - "$my_file" ) 2>/dev/null \ +- | ( umask 0 && cd "$my_destdir" && $TAR xf - ) >/dev/null 2>&1; } \ ++ | ( umask 0 && cd "$my_destdir" && $TAR xf - $TAR_NO_OWNER) >/dev/null 2>&1; } \ + && touch "$my_destdir/$my_file"; then + $opt_quiet || func_echo_once "$my_msg_var" + $opt_quiet || func_echo "copying $my_copy_msg" +@@ -1288,7 +1289,7 @@ func_copy_cb () + else + if test "$my_file" = "aclocal.m4"; then + if { ( cd "$my_srcdir" && $TAR chf - "$my_file" ) 2>/dev/null \ +- | ( umask 0 && cd "$my_destdir" && $TAR xf - ) >/dev/null 2>&1 ; } ++ | ( umask 0 && cd "$my_destdir" && $TAR xf - $TAR_NO_OWNER) >/dev/null 2>&1 ; } + then + $opt_quiet || func_echo_once "$my_msg_var" + $opt_quiet || func_echo "copying $my_copy_msg" diff --git a/libtool.spec b/libtool.spec index 4a8c159..ac086d3 100644 --- a/libtool.spec +++ b/libtool.spec @@ -3,7 +3,7 @@ Summary: The GNU Portable Library Tool Name: libtool Version: 2.4.2 -Release: 13%{?dist} +Release: 14%{?dist} License: GPLv2+ and LGPLv2+ and GFDL URL: http://www.gnu.org/software/libtool/ Group: Development/Tools @@ -11,6 +11,11 @@ Group: Development/Tools Source: http://ftp.gnu.org/gnu/libtool/libtool-%{version}.tar.xz Patch0: libtool-2.2.10-rpath.patch Patch1: libtool-2.4.2-TEMPORARY-disable-gcj-tests.patch +# Run the 'tar --no-same-owner -xf' instead of 'tar -xf' +# ~> #740079 +# ~> Downstream - tar is not used in upstream 'master' branch anymore, will be +# fixed in next release. +Patch2: libtool-2.4.2-tar-no-owner.patch Requires(post): /sbin/install-info Requires(preun): /sbin/install-info @@ -74,6 +79,7 @@ Static libraries and header files for development with ltdl. %setup -n libtool-%{version} -q %patch0 -p1 -b .rpath %patch1 -p1 -b .temp-disable-gcj-test +%patch2 -p1 -b .tar-no-same-owner %build @@ -153,6 +159,9 @@ fi %{_libdir}/libltdl.so %changelog +* Wed Apr 24 2013 Pavel Raiskup - 2.4.2-14 +- allow root to copy files into NFS in libtoolize (#740079) + * Thu Mar 14 2013 Pavel Raiskup - 2.4.2-13 - do not BR gcc-java in RHEL (by dmach)