From cc15b45630e72d683b6ca069e050849b8c18572e Mon Sep 17 00:00:00 2001 From: Thomas Woerner Date: Dec 06 2005 16:40:07 +0000 Subject: [tw] - spec file cleanup - mark po files as lang specific --- diff --git a/attr-2.4.24-build.patch b/attr-2.4.24-build.patch new file mode 100644 index 0000000..77dc1c2 --- /dev/null +++ b/attr-2.4.24-build.patch @@ -0,0 +1,36 @@ +--- attr-2.4.24/include/buildmacros.build 2005-12-06 16:47:17.000000000 +0100 ++++ attr-2.4.24/include/buildmacros 2005-12-06 16:48:49.000000000 +0100 +@@ -54,7 +54,7 @@ + $(LFILES:.l=.o) \ + $(YFILES:%.y=%.tab.o) + +-INSTALL = $(TOPDIR)/install-sh -o $(PKG_USER) -g $(PKG_GROUP) ++INSTALL = $(TOPDIR)/install-sh + + SHELL = /bin/sh + IMAGES_DIR = $(TOPDIR)/all-images +--- attr-2.4.24/include/builddefs.in.build 2005-12-06 16:47:01.000000000 +0100 ++++ attr-2.4.24/include/builddefs.in 2005-12-06 16:48:18.000000000 +0100 +@@ -52,14 +52,14 @@ + PKG_VERSION = @pkg_version@ + PKG_PLATFORM = @pkg_platform@ + PKG_DISTRIBUTION= @pkg_distribution@ +-PKG_BIN_DIR = @bindir@ +-PKG_SBIN_DIR = @sbindir@ +-PKG_LIB_DIR = @libdir@ +-PKG_DEVLIB_DIR = @libexecdir@ +-PKG_INC_DIR = @includedir@/attr +-PKG_MAN_DIR = @mandir@ +-PKG_DOC_DIR = @datadir@/doc/@pkg_name@ +-PKG_LOCALE_DIR = @datadir@/locale ++PKG_BIN_DIR = $(DESTDIR)@bindir@ ++PKG_SBIN_DIR = $(DESTDIR)@sbindir@ ++PKG_LIB_DIR = $(DESTDIR)@libdir@ ++PKG_DEVLIB_DIR = $(DESTDIR)@libexecdir@ ++PKG_INC_DIR = $(DESTDIR)@includedir@/attr ++PKG_MAN_DIR = $(DESTDIR)@mandir@ ++PKG_DOC_DIR = $(DESTDIR)@datadir@/doc/@pkg_name@-@pkg_version@ ++PKG_LOCALE_DIR = $(DESTDIR)@datadir@/locale + + CC = @cc@ + AWK = @awk@ diff --git a/attr.spec b/attr.spec index 1c64654..88e2ee3 100644 --- a/attr.spec +++ b/attr.spec @@ -1,13 +1,14 @@ Summary: Utilities for managing filesystem extended attributes. Name: attr Version: 2.4.24 -Release: 1 +Release: 2 Prereq: /sbin/ldconfig Conflicts: xfsdump < 2.0.0 BuildRoot: %{_tmppath}/%{name}-root Source: http://acl.bestbits.at/current/tar/attr-%{version}.src.tar.gz Patch1: attr-2.0.8-docperms.patch Patch2: attr-2.2.0-multilib.patch +Patch3: attr-2.4.24-build.patch License: GPL URL: http://acl.bestbits.at/ Group: System Environment/Base @@ -58,6 +59,7 @@ you'll also want to install attr. # figure out how to chmod and how to install perl. :-) %patch1 -p1 -b .perms %patch2 -p1 -b .multilib +%patch3 -p1 -b .build autoconf @@ -68,46 +70,19 @@ make LIBTOOL="libtool --tag=CC" %install rm -rf $RPM_BUILD_ROOT +make install DESTDIR=$RPM_BUILD_ROOT +make install-dev DESTDIR=$RPM_BUILD_ROOT +make install-lib DESTDIR=$RPM_BUILD_ROOT -DIST_ROOT="$RPM_BUILD_ROOT" -DIST_INSTALL=`pwd`/install.manifest -DIST_INSTALL_DEV=`pwd`/install-dev.manifest -DIST_INSTALL_LIB=`pwd`/install-lib.manifest -export DIST_ROOT DIST_INSTALL DIST_INSTALL_DEV DIST_INSTALL_LIB -make install DIST_MANIFEST="$DIST_INSTALL" PKG_DOC_DIR=%{_docdir}/attr-%{version} -make install-dev DIST_MANIFEST="$DIST_INSTALL_DEV" -make install-lib DIST_MANIFEST="$DIST_INSTALL_LIB" - -# Buahhh, ugly hack, but it works. -perl -pi -e 's|^f 644|f 755|' $DIST_INSTALL_LIB - -# get rid of *.la files -rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la - -files() -{ - sort | uniq | awk ' -$1 == "d" { - if (match ($6, "/usr/include/attr")) - printf ("%%%%dir %%%%attr(%s,%s,%s) %s\n", $2, $3, $4, $5); } -$1 == "f" { if (match ($6, "/usr/share/man") || match ($6, "/usr/share/doc/attr")) - printf ("%%%%doc "); - if (match ($6, "/usr/share/man")) - printf ("%%%%attr(%s,%s,%s) %s*\n", $2, $3, $4, $6); - else - printf ("%%%%attr(%s,%s,%s) %s\n", $2, $3, $4, $6); } -$1 == "l" { if (match ($3, "/usr/share/man") || match ($3, "/usr/share/doc/attr")) - printf ("%%%%doc "); - if (match ($3, "/usr/share/man")) - printf ("%attr(0777,root,root) %s*\n", $3); - else - printf ("%attr(0777,root,root) %s\n", $3); }' -} -set +x -files < "$DIST_INSTALL" > files.rpm -files < "$DIST_INSTALL_DEV" | grep -v libattr.la > filesdevel.rpm -files < "$DIST_INSTALL_LIB" > fileslib.rpm -set -x +# get rid of libattr.la +rm -f $RPM_BUILD_ROOT/%{_libdir}/libattr.la + +# fix links to shared libs and permissions +rm -f $RPM_BUILD_ROOT/%{_libdir}/libattr.so +ln -s /%{_lib}/libattr.so $RPM_BUILD_ROOT/%{_libdir}/libattr.so +chmod 0755 $RPM_BUILD_ROOT/%{_lib}/libattr.so.*.*.* + +%find_lang %{name} %clean rm -rf $RPM_BUILD_ROOT @@ -116,16 +91,33 @@ rm -rf $RPM_BUILD_ROOT %postun -n libattr -p /sbin/ldconfig -%files -f files.rpm +%files -f %{name}.lang %defattr(-,root,root) - -%files -n libattr-devel -f filesdevel.rpm +%{_bindir}/attr +%{_bindir}/getfattr +%{_bindir}/setfattr +%{_datadir}/doc/attr-%{version} +%{_mandir}/man1/attr.1* +%{_mandir}/man1/getfattr.1* +%{_mandir}/man1/setfattr.1* +%{_mandir}/man5/attr.5* + +%files -n libattr-devel %defattr(-,root,root) -/usr/include/attr +/%{_lib}/libattr.so +%{_includedir}/attr +%{_libdir}/libattr.* +%{_mandir}/man2/*attr.2* +%{_mandir}/man3/attr_*.3.* -%files -n libattr -f fileslib.rpm +%files -n libattr +/%{_lib}/libattr.so.* %changelog +* Tue Dec 6 2005 Thomas Woerner 2.4.24-2 +- spec file cleanup +- mark po files as lang specific + * Sun Nov 06 2005 Florian La Roche - 2.4.24