Author: hunter Date: Sun Nov 27 17:19:40 2005 GMT Module: SPECS Tag: HEAD ---- Log message: - nyf.
---- Files affected: SPECS: mkcdrec.spec (NONE -> 1.1) (NEW) ---- Diffs: ================================================================ Index: SPECS/mkcdrec.spec diff -u /dev/null SPECS/mkcdrec.spec:1.1 --- /dev/null Sun Nov 27 18:19:40 2005 +++ SPECS/mkcdrec.spec Sun Nov 27 18:19:35 2005 @@ -0,0 +1,282 @@ +# $Revision$, $Date$ +%define _prefix /var/opt/mkcdrec +%define _webmin_root /usr/libexec/webmin +%define _webmin_access_file /etc/webmin/webmin.acl +%define _webmin_cache_cile /etc/webmin/module.infos.cache +%define _boot_arch x86 +Summary: mkCDrec (make CD-ROM Recovery) disaster recovery tool-set +Summary(pl): mkCDrec (zrób CD-ROM odzyskyjący system) +Name: mkcdrec +Version: 0.8.9 +Release: 0.1 +Source0: http://mkcdrec.ota.be/project/mkCDrec_v%{version}.tar.gz +# Source0-md5: 0cbe2efbd083ce9745c5d5c5cea1c7c2 +##Source1: busybox-1.01.tar.bz2 +URL: http://mkcdrec.ota.be/ +License: GPL +Group: System/Tools +Provides: perl(mkcdrec-lib.pl) +Requires: MAKEDEV + +%if %{_boot_arch}==ia64 +Prereq: chkconfig fileutils cdrecord mkisofs tar ash mtools rsync +Requires: kernel >= 2.0.0, util-linux >= 2.11, perl >= 5.0, parted >= 1.6 +BuildRequires: gcc >= 2.96 +%endif +%if %{_boot_arch}==x86_64 +Prereq: fileutils cdrecord mkisofs tar ash rsync syslinux +Requires: kernel >= 2.0.0, util-linux >= 2.11, perl >= 5.0 +BuildRequires: gcc >= 2.96 +%endif +%if %{_boot_arch}==x86 +Prereq: coreutils fileutils cdrecord mkisofs tar ash syslinux rsync +Requires: kernel >= 2.0.0, util-linux >= 2.11, perl >= 5.0 +BuildRequires: syslinux >= 1.60, gcc >= 2.96 +%endif +BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) + +%description +mkCDrec (Make CDROM Recovery) makes a bootable (El Torito) disaster +recovery image, including backups of the Linux system to one or more +CD-ROM(s) (multi-volume sets). Otherwise, the backups can be stored on +another disk, NFS disk, or (remote) tape. After a disk crash or system +intrusion, the system can be booted from the CD-ROM and one can +restore the complete system as it was. It also features disk cloning, +which allows one to restore a disk to another disk (the destination +disk does not have to be of the same size, as it calculates the +partition layout itself). Currently, ext2, ext3, minix, msdos, fat, +vfat, reiserfs, xfs and jfs filesystems are supported. One Button +Disaster Recovery (OBDR) is also supported as recovery method. + +%description -l pl +mkCDrec (zrób odzyskujący CDROM) tworzy uruchamialną (El Torito) +płtkę zawierają system oraz kilka voluminów kopii danych. Zamiast +wielu płytek można posłużyć się innym dyskiem, NFSem, kopią na taśmie. +Po awarii system albo wejściu intruza system może być uruchomiony +z płytki i przywrócony do pierwotnego stanu. +mkcdrec wspiera klonowanie systemu. Aktualnie można używać ext2, ext3, +minix, msdos, fat, vfat, reiserfs, xfs and jfs jako systemów plików. +Metoda zwana 'One Button Disaster Recovery (OBDR)' jest również wpierana. + +%prep +%setup -q -n mkcdrec +##%setup -n mkcdrec -a 1 + +%build +%{__make} -f Makefile.%{_boot_arch} build + +%install +rm -rf $RPM_BUILD_ROOT +find . -name CVS | xargs rm -Rfv + +install -d $RPM_BUILD_ROOT%{_prefix}/busybox/applets +install -d $RPM_BUILD_ROOT%{_bindir} +install -d $RPM_BUILD_ROOT%{_prefix}/contributions +install -d $RPM_BUILD_ROOT%{_prefix}/modules +install -d $RPM_BUILD_ROOT%{_prefix}/scripts/messages +install -d $RPM_BUILD_ROOT%{_prefix}/doc +install -d $RPM_BUILD_ROOT%{_prefix}/doc/style +install -d $RPM_BUILD_ROOT%{_prefix}/doc/images +install -d $RPM_BUILD_ROOT%{_prefix}/usr +install -d $RPM_BUILD_ROOT%{_prefix}%{_sysconfdir} +install -d $RPM_BUILD_ROOT%{_mandir}/man8 +for fname in busybox*/busybox busybox*/busybox.links; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/busybox +done + +install -m 755 busybox*/applets/install.sh $RPM_BUILD_ROOT%{_prefix}/busybox/applets + +for fname in cutstream*/cutstream \ + pastestream*/pastestream mediacheck/checkisomd5 mediacheck/implantisomd5 +do + install -m 755 $fname $RPM_BUILD_ROOT%{_bindir} +done +for fname in contributions/*.sh contributions/mkcdrec; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/contributions +done +for fname in scripts/messages/*; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/scripts/messages +done +for fname in `find scripts -type f`; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/$fname +done +for fname in modules/*; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/modules +done +for fname in doc/*.html doc/*.gif doc/*.jpg doc/*.png; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/doc +done +for fname in doc/style/*.css; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/doc/style +done +for fname in doc/images/*; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/doc/images +done + +for fname in `find etc -type d`; do + install -d -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/$fname +done +for fname in `find etc -type f`; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/$fname +done +for fname in `find usr -type d`; do + install -d -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/$fname +done +for fname in `find usr -type f`; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/$fname +done + +for fname in `find . -type f -maxdepth 1`; do + install -m 755 $fname $RPM_BUILD_ROOT%{_prefix}/$fname +done + +install -m 755 doc/mkcdrec.8 $RPM_BUILD_ROOT%{_mandir}/man8 + +gzip -c $RPM_BUILD_ROOT%{_mandir}/man8/mkcdrec.8 > \ + $RPM_BUILD_ROOT%{_mandir}/man8/mkcdrec.8.gz + +for file in \ + $RPM_BUILD_ROOT%{_prefix}/.cvsignore \ + $RPM_BUILD_ROOT%{_prefix}/COPYING \ + $RPM_BUILD_ROOT%{_prefix}/Changelog \ + $RPM_BUILD_ROOT%{_prefix}/README \ +; do rm -f $file ; done + +# installation of webmin module + + +[ ! -d $RPM_BUILD_ROOT%{_webmin_root}/mkcdrec ] && install -d -m 755 $RPM_BUILD_ROOT%{_webmin_root}/mkcdrec +# we copy files in webmin directory +#if test -d $RPM_BUILD_ROOT%{_webmin_root} + + for fname in `find webmin -type d`; do + install -d -m 755 $fname $RPM_BUILD_ROOT%{_webmin_root}/`echo $fname | sed -e 's/webmin/mkcdrec/'` + done + for fname in `find webmin -type f`; do + install -m 755 $fname $RPM_BUILD_ROOT%{_webmin_root}/`echo $fname | sed -e 's/webmin/mkcdrec/'` + done +#fi +%files +%defattr(644,root,root,755) +%doc Changelog README COPYING +%doc %{_prefix}/doc +%config %{_prefix}/Config.sh +%{_prefix}/VERSION +%{_prefix}/.config.bb +%{_prefix}/busybox +%attr(755,root,root) %{_bindir} +%{_prefix}/contributions +%{_prefix}/scripts +%{_prefix}/modules +%{_prefix}%{_sysconfdir} +%{_prefix}/usr +%{_prefix}/linuxrc +%{_prefix}/linuxrc_find_and_prep_root +%{_prefix}/linuxrc_post +%{_prefix}/linuxrc_pre +%{_prefix}/Makefile +%{_prefix}/Makefile.new-powermac +%{_prefix}/Makefile.x86 +%{_prefix}/Makefile.sparc +%{_prefix}/Makefile.ia64 +%{_prefix}/Makefile.x86_64 +%{_mandir}/man8/* +%{_webmin_root}/mkcdrec/help.cgi +%{_webmin_root}/mkcdrec/images/icon +%{_webmin_root}/mkcdrec/images/icon.gif +%{_webmin_root}/mkcdrec/index.cgi +%{_webmin_root}/mkcdrec/lang/en +%{_webmin_root}/mkcdrec/lang/fr +%{_webmin_root}/mkcdrec/mkcdrec-lib.pl +%{_webmin_root}/mkcdrec/module.info +%{_webmin_root}/mkcdrec/save.cgi +%{_webmin_root}/mkcdrec/README.webmin + +%post +#we add mkcdrec in webmin root's ACL +if [ -f %{_webmin_access_file} ]; then + cp %{_webmin_access_file} %{_webmin_access_file}.beforemkcdrec.sauv + ed %{_webmin_access_file} << EOF > /tmp/mkcdrec.log 2>&1 +/root: +s/root:/root: mkcdrec/ +w +q +EOF +else + echo "WARNING: it seems that webmin isn't installed on that system.If you install it later, don't forget to add mkcdrec to the list of modules in %{_webmin_access_file} to make mkcdrec's webmin module available." + +fi +# install the mkcdrec wrapper +install -m 750 %{_prefix}/contributions/mkcdrec /usr/sbin/mkcdrec + +%postun +# we remove mkcdrec from webmin root's ACL + +if [ -f %{_webmin_access_file} ]; then + ed %{_webmin_access_file} << EOF > /tmp/mkcdrec.log 2>&1 +s/mkcdrec//g +w +q +EOF +fi +# rm the mkcdrec wrapper +rm -f /usr/sbin/mkcdrec +%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`) +%changelog +* %{date} PLD Team <[EMAIL PROTECTED]> +All persons listed below can be reached at <cvs_login>@pld-linux.org + +$Log$ +Revision 1.1 2005/11/27 17:19:35 hunter +- nyf. + +* Sun Oct 30 2005 Gratien D'haese +- Config.sh became a config file instead of plain file +- remove mtools from x86_64 Prereq list +- added syslinux to x86_64 Prereq list +- added OBDR to the description line +- man page mkcdrec.8 saved as plain file and as gzip'ed file +- remove all CVS directory for install +- added Source1 and changed %setup + +* Sat Sep 10 2005 Gratien D'haese +- add mkcdrec script + +* Wed Jun 23 2004 Guillaume Radde & Gratien D'haese +- add support for IA64 +- add webmin module + +* Tue Jun 09 2004 Gratien D'haese +- remove sfdisk, tinylogin and udpcp + +* Tue Jun 01 2004 Gratien D'haese +- Updated Prereq list + +* Sat Jan 24 2004 Gratien D'haese +- remove "cksfv*/src/cksfv" from binaries + +* Tue Nov 13 2003 Gratien D'haese +- add contributions directory + +* Sun Sep 7 2003 Gratien D'haese +- added doc/style to rpm + +* Mon May 5 2003 Michal Jaegermann +- spec edits for sanity + +* Sat Feb 22 2003 Gratien D'haese + - changed the rules for syslinux/isolinux + +* Sat Jan 10 2003 Gratien D'haese + - finishing mkcdrec2.spec for our i386 binary RPM + +* Tue Dec 10 2002 Gratien D'haese + - extending mkcdrec2.spec file + +* Sat Feb 09 2002 Gratien D'haese + - initial draft of mkcdrec2.spec file and modified the original makerpms.sh + shell script from samba team. + + +%clean +rm -rf $RPM_BUILD_ROOT ================================================================ _______________________________________________ pld-cvs-commit mailing list [email protected] http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit
