Browse Source

update: acl, attr

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@3372 ec354946-7b23-47d6-9f5a-488ba84defc7
inagaki 13 years ago
parent
commit
7f7f166fcb
2 changed files with 165 additions and 51 deletions
  1. 69 28
      a/acl/acl-vl.spec
  2. 96 23
      a/attr/attr-vl.spec

+ 69 - 28
a/acl/acl-vl.spec

@@ -1,28 +1,41 @@
-Summary: Access control list utilities
 Name: acl
-Version: 2.2.47
-Release: 2%{?_dist_release}
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-BuildRequires: libattr-devel >= 2.4.1
-BuildRequires: autoconf, libtool >= 1.5, gettext, gawk
-Source: ftp://oss.sgi.com/projects/xfs/cmd_tars/acl_%{version}-1.tar.gz
-Patch0: acl-2.2.3-multilib.patch
-Patch1: acl-2.2.39-build.patch
-Patch2: acl-2.2.39-path_max.patch
-Patch3: acl-2.2.39-params.patch
-Patch4: acl-2.2.45-exitcode.patch
-Patch5: acl-2.2.39-segfault.patch
-License: GPL
+Summary: Access control list utilities
+Version: 2.2.49
+Release: 1%{?_dist_release}
+
 Group: System Environment/Base
+License: GPLv2+
 URL: http://oss.sgi.com/projects/xfs/
 
+Source: http://download.savannah.gnu.org/releases-noredirect/acl/acl-%{version}.src.tar.gz
+Patch1: acl-2.2.39-build.patch
+# bz #488674
+Patch2: acl-2.2.49-setfacl-walk.patch
+# bz #467936
+Patch3: acl-2.2.49-bz467936.patch
+# prepare the test-suite for SELinux and arbitrary umask
+Patch4: acl-2.2.49-tests.patch
+# bz #576550
+Patch5: acl-2.2.49-setfacl-restore.patch
+# fix typos in setfacl(1) man page (#675451)
+Patch6: acl-2.2.49-bz675451.patch
+# add function acl_extended_file_nofollow() (#692982)
+Patch7: acl-2.2.49-bz692982.patch
+
+BuildRoot: %{_tmppath}/%{name}-%{version}-root
+BuildRequires: gawk
+BuildRequires: gettext
+BuildRequires: libattr-devel >= 2.4.1
+BuildRequires: libtool
+Requires: libacl = %{version}-%{release}
+
 %description
 This package contains the getfacl and setfacl utilities needed for
 manipulating access control lists.
 
 %package -n libacl
 Summary: Dynamic library for access control list support
-License: LGPL
+License: LGPLv2+
 Group: System Environment/Libraries
 Requires(post): /sbin/ldconfig
 Requires(postun): /sbin/ldconfig
@@ -34,10 +47,10 @@ control lists.
 
 %package -n libacl-devel
 Summary: Access control list static libraries and headers.
-License: LGPL
+License: LGPLv2+
 Group: Development/Libraries
-Requires: libacl = %{version}-%{release}, libattr-devel
-#Requires: nfs-utils-lib, openldap
+Requires: libacl = %{version}-%{release}
+Requires: libattr-devel
 
 %description -n libacl-devel
 This package contains static libraries and header files needed to develop
@@ -46,19 +59,19 @@ defined in POSIX 1003.1e draft standard 17.
 
 %prep
 %setup -q
-%patch0 -p1 -b .multilib
-%patch1 -p1 -b .build
-%patch2 -p1 -b .path_max
-%patch3 -p1 -b .params
-%patch4 -p1 -b .exitcode
-%patch5 -p1 -b .segfault
-autoconf
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
+%patch4 -p1
+%patch5 -p1
+%patch6 -p1
+%patch7 -p1
 
 %build
 touch .census
 # acl abuses libexecdir
 %configure --libdir=/%{_lib} --libexecdir=%{_libdir}
-make LIBTOOL="libtool --tag=CC"%{?_smp_mflags}
+make %{?_smp_mflags} LIBTOOL="libtool --tag=CC"
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -66,8 +79,11 @@ make install DESTDIR=$RPM_BUILD_ROOT
 make install-dev DESTDIR=$RPM_BUILD_ROOT
 make install-lib DESTDIR=$RPM_BUILD_ROOT
 
-# get rid of libacl.la
-rm -f $RPM_BUILD_ROOT/%{_libdir}/libacl.la
+# get rid of libacl.a and libacl.la
+rm -f $RPM_BUILD_ROOT/%{_lib}/libacl.a
+rm -f $RPM_BUILD_ROOT/%{_lib}/libacl.la
+rm -f $RPM_BUILD_ROOT%{_libdir}/libacl.a
+rm -f $RPM_BUILD_ROOT%{_libdir}/libacl.la
 
 # fix links to shared libs and permissions
 rm -f $RPM_BUILD_ROOT/%{_libdir}/libacl.so
@@ -76,6 +92,17 @@ chmod 0755 $RPM_BUILD_ROOT/%{_lib}/libacl.so.*.*.*
 
 %find_lang %{name}
 
+%check
+if ./setfacl/setfacl -m u:`id -u`:rwx .; then
+    make tests || exit $?
+    if test 0 = `id -u`; then
+        make root-tests || exit $?
+    fi
+else
+    echo '*** ACLs are probably not supported by the file system,' \
+         'the test-suite will NOT run ***'
+fi
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -107,6 +134,20 @@ rm -rf $RPM_BUILD_ROOT
 /%{_lib}/libacl.so.*
 
 %changelog
+* Sat Apr 09 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.2.49-1
+- updated to 2.2.49
+- added Patch2-7 from Fedora
+  * Wed Apr 06 2011 Kamil Dudka <kdudka@redhat.com> 2.2.49-11
+  - add function acl_extended_file_nofollow() (#692982)
+  * Tue Mar 29 2011 Kamil Dudka <kdudka@redhat.com> 2.2.49-10
+  - fix typos in setfacl(1) man page (#675451)
+  * Thu Jul 08 2010 Kamil Dudka <kdudka@redhat.com> 2.2.49-8
+  - remove dependency of libacl-devel on nfs-utils-lib and openldap
+  * Tue May 25 2010 Kamil Dudka <kdudka@redhat.com> 2.2.49-7
+  - let acl depend on the same version of libacl (#595674)
+  * Wed Mar 24 2010 Kamil Dudka <kdudka@redhat.com> 2.2.49-6
+  - prevent setfacl --restore from SIGSEGV on malformed restore file (#576550)
+
 * Mon Jun 30 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 2.2.47-2
 - initial build for Vine Linux
 

+ 96 - 23
a/attr/attr-vl.spec

@@ -2,17 +2,51 @@
 
 Summary: Utilities for managing filesystem extended attributes
 Name: attr
-Version: 2.4.43
-Release: 2%{?_dist_release}
-Conflicts: xfsdump < 2.0.0
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-Source: ftp://oss.sgi.com/projects/xfs/cmd_tars/attr_%{version}-1.tar.gz
-Patch1: attr-2.2.0-multilib.patch
-Patch2: attr-2.4.32-build.patch
-License: GPL
+Version: 2.4.44
+Release: 1%{?_dist_release}
+
+License: GPLv2+
 URL: http://oss.sgi.com/projects/xfs/
 Group: System Environment/Base
-BuildRequires: autoconf, libtool >= 1.5, gettext
+
+Source: http://download.savannah.gnu.org/releases-noredirect/attr/attr-%{version}.src.tar.gz
+
+# a file available in the upstream git repo, but not in the release
+Source2: sort-getfattr-output
+
+# make it ready for rpmbuild
+Patch1: attr-2.4.32-build.patch
+
+# bz #485473
+Patch2: attr-2.4.43-leak.patch
+
+# prepare the test-suite for SELinux
+Patch3: attr-2.4.44-tests.patch
+
+# silence compile-time warnings
+Patch4: attr-2.4.44-warnings.patch
+
+# setfattr.1: document supported encodings of values (#587516)
+Patch5: attr-2.4.44-bz587516.patch
+
+# getfattr: encode NULs properly with --encoding=text (#650539)
+Patch6: attr-2.4.44-bz650539.patch
+
+# getfattr: return non-zero exit code on failure (#660619)
+Patch7: attr-2.4.44-bz660619.patch
+
+# walk_tree: do not follow symlink to directory with -h (#660613)
+Patch8: attr-2.4.44-bz660613.patch
+
+# fix typos in attr(1) man page (#669095)
+Patch9: attr-2.4.44-bz669095.patch
+
+BuildRoot: %{_tmppath}/%{name}-%{version}-root
+BuildRequires: gettext
+BuildRequires: libtool
+Requires: libattr = %{version}-%{release}
+
+Conflicts: xfsdump < 2.0.0
 
 %description
 A set of tools for manipulating extended attributes on filesystem
@@ -23,7 +57,7 @@ with the SGI IRIX tool of the same name.
 %package -n libattr
 Summary: Dynamic library for extended attribute support
 Group: System Environment/Libraries
-License: LGPL
+License: LGPLv2+
 
 %description -n libattr
 This package contains the libattr.so dynamic library which contains
@@ -32,7 +66,7 @@ the extended attribute system calls and library functions.
 %package -n libattr-devel
 Summary: Extended attribute static libraries and headers
 Group: Development/Libraries
-License: LGPL
+License: LGPLv2+
 Requires: libattr = %{version}-%{release}
 
 %description -n libattr-devel
@@ -54,7 +88,7 @@ you'll also want to install attr.
 %package -n compat32-libattr
 Summary: Dynamic library for extended attribute support
 Group: System Environment/Libraries
-License: LGPL
+License: LGPLv2+
 
 %description -n compat32-libattr
 This package contains the libattr.so dynamic library which contains
@@ -63,7 +97,7 @@ the extended attribute system calls and library functions.
 %package -n compat32-libattr-devel
 Summary: Extended attribute static libraries and headers
 Group: Development/Libraries
-License: LGPL
+License: LGPLv2+
 Requires: libattr-devel = %{version}-%{release}
 Requires: compat32-libattr = %{version}-%{release}
 
@@ -85,19 +119,25 @@ you'll also want to install attr.
 
 %prep
 %setup -q
-# We need to turn off executable permissions on the script in %doc
-# because we don't want to drag perl into the base.  Users advanced
-# enough to have used ACLs before they were added to the distro can
-# figure out how to chmod and how to install perl.  :-)
-%patch1 -p1 -b .multilib
-%patch2 -p1 -b .build
+%setup -q
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
+%patch4 -p1
+%patch5 -p1
+%patch6 -p1
+%patch7 -p1
+%patch8 -p1
+%patch9 -p1
+
+# test-suite helper script
+install -m0755 %{SOURCE2} test/
 
-autoconf
 
 %build
 # attr abuses libexecdir
 %configure --libdir=/%{_lib} --libexecdir=%{_libdir}
-make LIBTOOL="libtool --tag=CC"
+make %{?_smp_mflags} LIBTOOL="libtool --tag=CC"
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -105,8 +145,11 @@ make install DESTDIR=$RPM_BUILD_ROOT
 make install-dev DESTDIR=$RPM_BUILD_ROOT
 make install-lib DESTDIR=$RPM_BUILD_ROOT
 
-# get rid of libattr.la
-rm -f $RPM_BUILD_ROOT/%{_libdir}/libattr.la
+# get rid of libattr.a and libattr.la
+rm -f $RPM_BUILD_ROOT/%{_lib}/libattr.a
+rm -f $RPM_BUILD_ROOT/%{_lib}/libattr.la
+rm -f $RPM_BUILD_ROOT%{_libdir}/libattr.a
+rm -f $RPM_BUILD_ROOT%{_libdir}/libattr.la
 
 # fix links to shared libs and permissions
 rm -f $RPM_BUILD_ROOT/%{_libdir}/libattr.so
@@ -115,6 +158,19 @@ chmod 0755 $RPM_BUILD_ROOT/%{_lib}/libattr.so.*.*.*
 
 %find_lang %{name}
 
+%check
+if ./setfattr/setfattr -n user.name -v value .; then
+    make tests || exit $?
+
+    # FIXME: root-tests are not ready for the SELinux
+    #if test 0 = `id -u`; then
+    #    make root-tests || exit $?
+    #fi
+else
+    echo '*** xattrs are probably not supported by the file system,' \
+         'the test-suite will NOT run ***'
+fi
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -160,6 +216,23 @@ rm -rf $RPM_BUILD_ROOT
 %endif
 
 %changelog
+* Sat Apr  9 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 2.4.44-1
+- new upstream release
+- remove static library from devel package
+- added Patch2-9
+  * Tue Mar 29 2011 Kamil Dudka <kdudka@redhat.com> 2.2.44-8
+  - fix typos in attr(1) man page (#669095)
+  * Wed Dec 22 2010 Kamil Dudka <kdudka@redhat.com> 2.2.44-6
+  - setfattr.1: document supported encodings of values (#587516)
+  - getfattr: encode NULs properly with --encoding=text (#650539)
+  - getfattr: return non-zero exit code on failure (#660619)
+  - walk_tree: do not follow symlink to directory with -h (#660613)
+  * Tue May 25 2010 Kamil Dudka <kdudka@redhat.com> 2.2.44-5
+  - let attr depend on the same version of libattr (#595689)
+  - silence compile-time warnings
+  * Wed Feb 18 2009 Zdenek Prikryl <zprikryl@redhat.com> 2.4.43-2
+  - Fixed memory leaks (#485473)
+
 * Wed Jul 15 2009 NAKAMURA Kenta <kenta@vinelinux.org> 2.4.43-2
 - added compat32 package for x86_64 arch support