Name: mach Version: 0.4.0 Release: 0.fdr.1 Summary: Make a chroot. Group: Applications/System License: GPL URL: http://thomas.apestaart.org/projects/mach/ Source: http://thomas.apestaart.org/download/mach/%{name}-%{version}.tar.gz Buildroot: %{_tmppath}/%{name}-%{version}-root Requires: python Requires: rpm Requires: rpm-python Requires: apt Requires: sed BuildRequires: python %description mach makes a chroot. Using apt-get and a suid binary, it manages to install clean chroot environments based on the original packages for that distribution. The clean root can be used to run jail roots, to create image files, or to build clean packages. Authors: -------- Thomas Vander Stichele (thomas (at) apestaart (dot) org) %prep %setup -q %build %configure %install rm -rf $RPM_BUILD_ROOT %makeinstall install -d -m 775 %{buildroot}%{_localstatedir}/lib/mach/states install -d -m 775 %{buildroot}%{_localstatedir}/lib/mach/roots #install -d -m 775 %{buildroot}%{_localstatedir}/tmp/mach #install -d -m 775 %{buildroot}%{_localstatedir}/tmp/mach/tmp install -d -m 775 %{buildroot}%{_localstatedir}/cache/mach/packages install -d -m 775 %{buildroot}%{_localstatedir}/cache/mach/archives %clean rm -rf $RPM_BUILD_ROOT %pre # create user and group mach /usr/sbin/useradd -c "mach user" \ -r -m mach > /dev/null 2>&1 || : %preun if [ "$1" == 0 ]; then # last removal # be a good boy and clean out the dirs we filled with junk rm -rf %{_localstatedir}/lib/mach/states/* rm -rf %{_localstatedir}/lib/mach/roots/* rm -rf %{_localstatedir}/cache/mach/* > /dev/null 2>&1 || : rmdir %{_localstatedir}/lib/mach/states > /dev/null 2>&1 || : rmdir %{_localstatedir}/lib/mach/roots > /dev/null 2>&1 || : rmdir %{_localstatedir}/cache/mach > /dev/null 2>&1 || : rm -rf %{_localstatedir}/tmp/mach fi %postun if [ "$1" == 0 ]; then # last removal userdel mach > /dev/null 2>&1 || : groupdel mach > /dev/null 2>&1 || : fi %files %defattr(-,root,root,-) %doc ChangeLog COPYING README AUTHORS BUGS TODO FORGETMENOT RELEASE %dir %{_sysconfdir}/mach %config %{_sysconfdir}/mach/conf %config %{_sysconfdir}/mach/dist %attr(-,mach,mach) %dir %{_localstatedir}/lib/mach/states %attr(-,mach,mach) %dir %{_localstatedir}/lib/mach/roots # %attr(-,mach,mach) %dir %{_localstatedir}/tmp/mach # %attr(-,mach,mach) %dir %{_localstatedir}/tmp/mach/tmp %attr(-,mach,mach) %dir %{_localstatedir}/cache/mach/packages %attr(-,mach,mach) %dir %{_localstatedir}/cache/mach/archives %{_bindir}/mach %attr(04750,root,mach) %{_sbindir}/mach-helper %changelog * Mon Sep 08 2003 Thomas Vander Stichele - 0.4.0-0.fdr.1: first public release. * Sat Aug 16 2003 Ville Skyttä - Add COPYING to docs. * Wed May 21 2003 Thomas Vander Stichele - added mach-helper * Wed Apr 30 2003 Thomas Vander Stichele - initial creation