]> git.pld-linux.org Git - packages/grep.git/blobdiff - grep.spec
- call env-update if available, rel 2
[packages/grep.git] / grep.spec
index 46de1fe06ce22731d3578ebc15911a907402485a..f30ebedaffc4e551fa7832b034ebdfd3e0331dfb 100644 (file)
--- a/grep.spec
+++ b/grep.spec
@@ -1,22 +1,38 @@
+#
+# Conditional build:
+%bcond_with    pcre    # with PCRE support
+#
 Summary:       GNU grep Utilities
 Summary(de):   GNU-Version der Pattern-Matching-Utilities
 Summary:       GNU grep Utilities
 Summary(de):   GNU-Version der Pattern-Matching-Utilities
+Summary(es):   Utilitarios grep GNU
 Summary(fr):   Utilitaires grep de GNU
 Summary(fr):   Utilitaires grep de GNU
-Summary(pl):   GNU grep 
+Summary(ja):   GNU grep ¤ÎÆüËܸìÂбþÈǤǤ¹.
+Summary(pl):   GNU grep
+Summary(pt_BR):        Utilitários grep GNU
+Summary(ru):   õÔÉÌÉÔÙ ÐÏÉÓËÁ ÐÏ ÛÁÂÌÏÎÁÍ GNU grep
 Summary(tr):   Dosyalarda katar arama aracý
 Summary(tr):   Dosyalarda katar arama aracý
+Summary(uk):   õÔÉ̦ÔÉ ÐÏÛÕËÕ ÐÏ ÛÁÂÌÏÎÁÍ GNU grep
 Name:          grep
 Name:          grep
-Version:       2.5a
-Release:       6
+Version:       2.5.1a
+Release:       2
+Epoch:         2
 License:       GPL
 Group:         Applications/Text
 License:       GPL
 Group:         Applications/Text
-Group(de):     Applikationen/Text
-Group(fr):     Utilitaires/Texte
-Group(pl):     Aplikacje/Tekst
-Source0:       ftp://alpha.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz
-Source1:       %{name}.1.pl
+Source0:       ftp://ftp.gnu.org/gnu/grep/%{name}-%{version}.tar.gz
+# Source0-md5: 71db1cb262c27f02461c4bca514591ce
+Source1:       http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2
+# Source1-md5: 1b5e726d0bee53e898531de4a76ad290
 Patch0:                %{name}-info.patch
 Patch0:                %{name}-info.patch
-Patch1:                %{name}-i18n.patch
-BuildRequires: pcre-devel
-Requires:      pcre
+Patch1:                %{name}-egrep.patch
+Patch2:                %{name}-locale-names.patch
+URL:           http://www.gnu.org/software/grep/grep.html
+BuildRequires: autoconf
+BuildRequires: automake
+BuildRequires: gettext-devel
+BuildRequires: libtool
+%{?with_pcre:BuildRequires:    pcre-devel}
+BuildRequires: texinfo
+%{?with_pcre:Requires: pcre}
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                _bindir         /bin
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                _bindir         /bin
@@ -34,68 +50,121 @@ eine oder mehrere Eingabedateien nach Zeilen, die auf ein angegebenes
 Muster passen, und zeigt dann die entsprechenden Zeilen an. GNUs grep
 enthält grep, egrep und fgrep.
 
 Muster passen, und zeigt dann die entsprechenden Zeilen an. GNUs grep
 enthält grep, egrep und fgrep.
 
+%description -l es
+Esta es la implementación GNU del popular utilitario grep. Permite la
+localización rápida de strings en archivos texto.
+
 %description -l fr
 Ceci est l'implémentation par GNU du populaire l'utilitaire grep su
 %description -l fr
 Ceci est l'implémentation par GNU du populaire l'utilitaire grep su
-- *nix. Il permet de localiser rapidement des chaînes de caractéres
-  dans les fichiers.
+Unix. Il permet de localiser rapidement des chaînes de caractéres dans
+les fichiers.
+
+%description -l ja
+GNU ¥×¥í¥¸¥§¥¯¥È¤Ë¤è¤ë grep, egrep, fgrep (°Ê²¼Ã±¤Ë grep) ¤ò¥Þ¥ë¥Á¥Ð
+¥¤¥È¥Ñ¥Ã¥Á(mb1.04)¤Ë¤è¤Ã¤ÆÆüËܸìÂбþ¤Ë¤·¤¿¤â¤Î¤Ç¤¹.
 
 
-%description -l pl 
-GNU grep jest implementacj± popularnego programu unixowego `grep'.
+%description -l pl
+GNU grep jest implementacj± popularnego programu uniksowego `grep'.
 Grep jest jednym z podstawowych narzêdzi, korzysta z niego prawie
 ka¿dy skrypt shella.
 
 Grep jest jednym z podstawowych narzêdzi, korzysta z niego prawie
 ka¿dy skrypt shella.
 
+%description -l pt_BR
+Esta é a implementação GNU do popular utilitário grep. Permite a
+localização rápida de strings em arquivos texto.
+
+%description -l ru
+üÔÏ ÒÅÁÌÉÚÁÃÉÑ GNU ÕÔÉÌÉÔÙ grep, ÐÒÅÄÎÁÚÎÁÞÅÎÎÏÊ ÄÌÑ ÂÙÓÔÒÏÇÏ ÐÏÉÓËÁ
+ÐÏ ÏÂÒÁÚÃÕ × ÔÅËÓÔÏ×ÙÈ ÆÁÊÌÁÈ.
+
 %description -l tr
 Bu, bütün Unix'lerde bulunan ve yaygýn olarak kullanýlan grep aracýnýn
 GNU sürümüdür. Metin dosyalarý içinde bulunan katarlarý aramada
 kullanýlýr.
 
 %description -l tr
 Bu, bütün Unix'lerde bulunan ve yaygýn olarak kullanýlan grep aracýnýn
 GNU sürümüdür. Metin dosyalarý içinde bulunan katarlarý aramada
 kullanýlýr.
 
+%description -l uk
+ãÅ GNU ÒÅÁ̦ÚÁæѠÐÏÐÕÌÑÒÎϧ ÕÔÉ̦ÔÉ grep, ÐÒÉÚÎÁÞÅÎϧ ÄÌÑ Û×ÉÄËÏÇÏ
+ÐÏÛÕËÕ ÐÏ ÛÁÂÌÏÎÕ × ÔÅËÓÔÏ×ÉÈ ÆÁÊÌÁÈ.
+
 %prep
 %prep
-%setup  -q
+%setup -q
 %patch0 -p1
 %patch1 -p1
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 
 
-%build
-gettextize --force --copy
-autoconf
+rm -f m4/{header,init}.m4
 
 
+# hack: AC_FUNC_STRERROR_R from strerror_r.m4 must override autoconf's version
+# (it contains HAVE_WORKING_STRERROR_R define, needed with glibc 2.x, as
+#  glibc version returns pointer to string and doesn't seem to store string in
+#  supplied buffer(???))
+cat m4/strerror_r.m4 >> acinclude.m4
+touch m4/{header,init}.m4
+
+# there is nb.po included, but more outdated than no.po (only no was in LINGUAS)
+mv -f po/{no,nb}.po
+
+%build
+%{__libtoolize}
+%{__aclocal} -I m4
+%{__automake}
+%{__autoconf}
 %ifarch sparc sparc64
 CPPFLAGS=""
 export CPPFLAGS
 %endif
 %ifarch sparc sparc64
 CPPFLAGS=""
 export CPPFLAGS
 %endif
-%configure
+%configure \
+       %{!?with_pcre:--disable-perl-regexp} \
+       --without-included-regex \
+       --enable-nls
 %{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
 %{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_mandir}/pl/man1
+install -d $RPM_BUILD_ROOT/etc/env.d
 
 
-%{__make} install DESTDIR=$RPM_BUILD_ROOT
-
-install %{SOURCE1} $RPM_BUILD_ROOT%{_mandir}/pl/man1/grep.1
+%{__make} install \
+       DESTDIR=$RPM_BUILD_ROOT
 
 echo .so grep.1 > $RPM_BUILD_ROOT%{_mandir}/man1/egrep.1
 echo .so grep.1 > $RPM_BUILD_ROOT%{_mandir}/man1/fgrep.1
 
 
 echo .so grep.1 > $RPM_BUILD_ROOT%{_mandir}/man1/egrep.1
 echo .so grep.1 > $RPM_BUILD_ROOT%{_mandir}/man1/fgrep.1
 
-echo .so grep.1 > $RPM_BUILD_ROOT%{_mandir}/pl/man1/egrep.1
-echo .so grep.1 > $RPM_BUILD_ROOT%{_mandir}/pl/man1/fgrep.1
+bzip2 -dc %{SOURCE1} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
 
 
-gzip -9nf NEWS README ChangeLog TODO
+cat << EOF >$RPM_BUILD_ROOT/etc/env.d/GREP_OPTIONS
+#GREP_OPTIONS="--binary-files=without-match --directories=skip --color=auto"
+EOF
 
 %find_lang %{name}
 
 
 %find_lang %{name}
 
+rm -f $RPM_BUILD_ROOT%{_infodir}/dir
+rm -f $RPM_BUILD_ROOT%{_mandir}/README.grep-non-english-man-pages
+rm -f $RPM_BUILD_ROOT%{_mandir}/ja-grep-nozgrep.diff
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
-%post
-[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
+%post -p /sbin/postshell
+-/usr/sbin/fix-info-dir -c %{_infodir}
+-/sbin/env-update -u
 
 
-%postun
-[ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
+%postun -p /sbin/postshell
+-/usr/sbin/fix-info-dir -c %{_infodir}
+-/sbin/env-update -u
 
 %files -f %{name}.lang
 %defattr(644,root,root,755)
 
 %files -f %{name}.lang
 %defattr(644,root,root,755)
-%doc *.gz
+%doc NEWS README ChangeLog TODO
+%config(noreplace,missingok) %verify(not md5 mtime size) /etc/env.d/*
 %attr(755,root,root) %{_bindir}/*
 %{_mandir}/man1/*
 %attr(755,root,root) %{_bindir}/*
 %{_mandir}/man1/*
+%lang(cs) %{_mandir}/cs/man1/*
+%lang(de) %{_mandir}/de/man1/*
+%lang(es) %{_mandir}/es/man1/*
+%lang(fi) %{_mandir}/fi/man1/*
+%lang(fr) %{_mandir}/fr/man1/*
+%lang(hu) %{_mandir}/hu/man1/*
+%lang(it) %{_mandir}/it/man1/*
+%lang(ja) %{_mandir}/ja/man1/*
+%lang(nl) %{_mandir}/nl/man1/*
 %lang(pl) %{_mandir}/pl/man1/*
 %{_infodir}/*info*
 %lang(pl) %{_mandir}/pl/man1/*
 %{_infodir}/*info*
This page took 0.035504 seconds and 4 git commands to generate.