specfile: Secure the paths when creting tcsh.lang file
This commit is contained in:
parent
fa980b7d85
commit
40ec3882a1
14
tcsh.spec
14
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
|
||||
|
||||
# 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 test -f nls/$language.cat ; then
|
||||
mkdir -p $dest
|
||||
install -p -m 644 nls/$language.cat $dest/tcsh
|
||||
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
|
||||
|
Loading…
Reference in New Issue
Block a user