%bcond_without tests # do not perform "make test"
#
%define ver 3.2
-%define patchlevel 39
-%define rel 1
+%define patchlevel 48
+%define rel 3
Summary: GNU Bourne Again Shell (bash)
Summary(fr.UTF-8): Le shell Bourne Again de GNU
Summary(pl.UTF-8): Powłoka GNU Bourne Again Shell (bash)
BuildRequires: bison
BuildRequires: ncurses-devel >= 5.2
BuildRequires: readline-devel >= 5.2
-BuildRequires: rpmbuild(macros) >= 1.429
+BuildRequires: rpmbuild(macros) >= 1.462
BuildRequires: sed >= 4.0
BuildRequires: texinfo
%if %{with static}
%{?with_bash_history:%patch9 -p1}
%patch10 -p1
%patch11 -p1
-tar xjf %SOURCE6 -C po
+%{__tar} xjf %{SOURCE6} -C po
sed -e 's/boldquot ru/boldquot ru af ca de es et fr hu ja nl pl pt_BR ro tr vi/' -i po/LINGUAS
%build
%clean
rm -rf $RPM_BUILD_ROOT
-%post -p %add_etc_shells -p /bin/sh /bin/ksh
+%post -p <lua>
+%lua_add_etc_shells /bin/bash /bin/rbash
os.execute("/usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1")
-%preun -p %remove_etc_shells -p /bin/bash /bin/rbash
+%preun -p <lua>
+if arg[2] == 0 then
+ %lua_remove_etc_shells /bin/bash /bin/rbash
+end
%postun -p /sbin/postshell
-/usr/sbin/fix-info-dir -c %{_infodir}
-%post static -p %add_etc_shells -p /bin/bash.static
-%preun static -p %remove_etc_shells -p /bin/bash.static
+%post static -p <lua>
+%lua_add_etc_shells /bin/bash.static
+
+%preun static -p <lua>
+if arg[2] == 0 then
+ %lua_remove_etc_shells /bin/bash.static
+end
%files -f %{name}.lang
%defattr(644,root,root,755)