Summary: A powerful interactive shell Name: zsh Version: 5.3 Release: 1 License: BSD URL: http://www.zsh.org Group: System Environment/Shells Source0: ftp://ftp.zsh.org/pub/%{name}-%{version}.tar.gz Source10: ftp://ftp.zsh.org/pub/%{name}-%{version}.tar.gz.asc Source1: zlogin.rhs Source2: zlogout.rhs Source3: zprofile.rhs Source4: zshrc.rhs Source5: zshenv.rhs Source6: dotzshrc Source7: zshprompt.pl # Give me better tools or die! %define _default_patch_fuzz 2 # legacy downstream patches, TODO: either get them upstream or drop them Patch0: %{name}-serial.patch Patch1: %{name}-4.3.6-8bit-prompts.patch Patch2: %{name}-test-C02-dev_fd-mock.patch Patch100: %{name}-%{version}-aix.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: coreutils, sed, info, make, patch BuildRequires: gdbm-devel >= 1.11-1 BuildRequires: libiconv >= 1.14-3 BuildRequires: pcre-devel >= 8.39-1 Requires: /sbin/install-info, info Requires: gdbm >= 1.11-1 Requires: libiconv >= 1.14-3 Requires: pcre >= 8.39-1 %description The zsh shell is a command interpreter usable as an interactive login shell and as a shell script command processor. Zsh resembles the ksh shell (the Korn shell), but includes many enhancements. Zsh supports command line editing, built-in spelling correction, programmable command completion, shell functions (with autoloading), a history mechanism, and more. %prep %setup -q export PATH=/opt/freeware/bin:$PATH %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch100 cp -p %{SOURCE7} . %build export CC="cc_r -qcpluscmt" ./configure \ --prefix=%{_prefix} \ --mandir=%{_mandir} \ --infodir=%{_infodir} \ --enable-etcdir=/etc \ --enable-pcre \ --enable-maildir-support \ --with-tcsetpgrp \ make all html %install [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} export PATH=/opt/freeware/bin:$PATH make DESTDIR=${RPM_BUILD_ROOT} install install.info /usr/bin/strip ${RPM_BUILD_ROOT}%{_bindir}/* || : rm -f ${RPM_BUILD_ROOT}%{_bindir}/zsh-%{version} rm -f ${RPM_BUILD_ROOT}%{_infodir}/dir gzip --best ${RPM_BUILD_ROOT}%{_infodir}/*info* mkdir -p ${RPM_BUILD_ROOT}/etc for i in %{SOURCE1} %{SOURCE2} %{SOURCE3} %{SOURCE4} %{SOURCE5} ; do install -m 644 $i ${RPM_BUILD_ROOT}/etc/"$(basename $i .rhs)" done mkdir -p ${RPM_BUILD_ROOT}/etc/skel install -m 644 %{SOURCE6} ${RPM_BUILD_ROOT}/etc/skel/.zshrc # replace to put proper command line to remove the dependency on /bin/zsh for i in calendar_add checkmail harden run-help run-help-ip sticky-note zcalc zed zkbd; do sed -i -e 's!/bin/zsh!%{_bindir}/zsh!' \ ${RPM_BUILD_ROOT}%{_datadir}/%{name}/%{version}/functions/${i} chmod +x ${RPM_BUILD_ROOT}%{_datadir}/%{name}/%{version}/functions/${i} done ( cd ${RPM_BUILD_ROOT} for dir in bin include lib do mkdir -p usr/${dir} cd usr/${dir} ln -sf ../..%{_prefix}/${dir}/* . cd - done ) %post if [ "$1" = 1 ]; then if [ ! -f /etc/shells ]; then echo "%{_bindir}/zsh" >> /etc/shells else grep '^%{_bindir}/zsh$' /etc/shells || \ echo "%{_bindir}/zsh" >> /etc/shells fi fi if [ -f %{_infodir}/zsh.info.gz ]; then /sbin/install-info %{_infodir}/%{name}.info.gz %{_infodir}/dir \ --entry="* zsh: (zsh). An enhanced bourne shell." fi : %preun if [ "$1" = 0 ] ; then if [ -f %{_infodir}/zsh.info.gz ]; then /sbin/install-info --delete %{_infodir}/%{name}.info.gz %{_infodir}/dir \ --entry="* zsh: (zsh). An enhanced bourne shell." fi fi : %postun if [ "$1" = 0 ] ; then if [ ! -x %{_bindir}/zsh ]; then grep -v '^%{_bindir}/%{name}$' /etc/shells > /etc/shells.rpm && \ mv /etc/shells.rpm /etc/shells fi fi %clean [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,system) %doc README LICENCE Etc/BUGS Etc/CONTRIBUTORS Etc/FAQ FEATURES MACHINES %doc NEWS Etc/zsh-development-guide Etc/completion-style-guide zshprompt.pl %attr(755,root,system) %{_bindir}/zsh* %{_mandir}/man?/* %{_infodir}/* %{_libdir}/%{name} %{_datadir}/%{name} %config(noreplace) /etc/skel/.z* %config(noreplace) /etc/z* /usr/bin/zsh* %changelog * Wed Dec 14 2016 Michael Perzl - 5.3-1 - updated to version 5.3 * Mon Dec 28 2015 Michael Perzl - 5.2-1 - updated to version 5.2 * Mon Dec 28 2015 Michael Perzl - 5.1.1-1 - updated to version 5.1.1 * Mon Dec 28 2015 Michael Perzl - 5.1-1 - updated to version 5.1 * Mon Dec 28 2015 Michael Perzl - 5.0.8-1 - updated to version 5.0.8 * Wed Oct 29 2014 Michael Perzl - 5.0.7-1 - updated to version 5.0.7 * Wed Oct 01 2014 Michael Perzl - 5.0.6-1 - updated to version 5.0.6 * Mon Jan 20 2014 Michael Perzl - 5.0.5-1 - updated to version 5.0.5 * Mon Jan 20 2014 Michael Perzl - 5.0.4-1 - updated to version 5.0.4 * Wed Dec 11 2013 Michael Perzl - 5.0.2-2 - fixed wrong dependency on /bin/zsh * Mon Jan 07 2013 Michael Perzl - 5.0.2-1 - updated to version 5.0.2 * Mon Jan 07 2013 Michael Perzl - 5.0.1-1 - updated to version 5.0.1 * Fri Feb 24 2012 Michael Perzl - 4.3.17-1 - updated to version 4.3.17 * Wed Dec 21 2011 Michael Perzl - 4.3.15-1 - updated to version 4.3.15 * Thu Dec 08 2011 Michael Perzl - 4.3.14-1 - updated to version 4.3.14 * Wed Jun 01 2011 Michael Perzl - 4.3.12-1 - updated to version 4.3.12 * Mon Jan 10 2011 Michael Perzl - 4.3.11-1 - updated to version 4.3.11 - automatically add entry to /etc/shells * Wed Aug 11 2010 Michael Perzl - 4.3.10-1 - first version for AIX V5.1 and higher