diff --git a/tcsh.spec b/tcsh.spec index 3890605..f7401e2 100644 --- a/tcsh.spec +++ b/tcsh.spec @@ -130,14 +130,16 @@ install -p -m 644 tcsh.man %{buildroot}%{_mandir}/man1/tcsh.1 ln -sf tcsh %{buildroot}%{_bindir}/csh ln -sf tcsh.1 %{buildroot}%{_mandir}/man1/csh.1 -while read lang language ; do - dest=%{buildroot}%{_datadir}/locale/$lang/LC_MESSAGES - if test -f nls/$language.cat ; then - mkdir -p $dest - install -p -m 644 nls/$language.cat $dest/tcsh +# NOTE: We have to construct tcsh.lang by ourselves, since upstream does not use +# standard naming/placing of localization files for the gettext... +while read lang language; do + dest="%{buildroot}%{_datadir}/locale/$lang/LC_MESSAGES" + if [[ -f "nls/$language.cat" ]]; then + mkdir -p "$dest" + install -p -m 644 "nls/$language.cat" "$dest/tcsh" echo "%lang($lang) %{_datadir}/locale/$lang/LC_MESSAGES/tcsh" fi -done > tcsh.lang << _EOF +done > %{name}.lang << _EOF de german el greek en C @@ -182,7 +184,7 @@ if [ ! -x %{_bindir}/tcsh ]; then fi -%files -f tcsh.lang +%files -f %{name}.lang %defattr(-,root,root,-) %doc FAQ Fixes README complete.tcsh %license COPYING