source: MondoRescue/trunk/mindi/mindi.spec@ 119

Last change on this file since 119 was 84, checked in by bcornec, 19 years ago

merge patch r83 of the branch 2.04_berlios

  • Property svn:keywords set to Id
File size: 12.8 KB
Line 
1#
2# $Id: mindi.spec 84 2005-10-21 00:05:42Z bcornec $
3#
4%define is_mandriva %(test -e /etc/mandriva-release && echo 1 || echo 0)
5%define is_mandrake %(test -e /etc/mandrake-release && echo 1 || echo 0)
6%define is_suse %(test -e /etc/SuSE-release && echo 1 || echo 0)
7%define is_fedora %(test -e /etc/fedora-release && echo 1 || echo 0)
8%define is_redhat %(test -e /etc/redhat-release && echo 1 || echo 0)
9
10%define name mindi
11%define version 1.04_berlios
12%define mrel 1
13
14%if %is_redhat
15%define src %{name}-%{version}.tgz
16Group: Applications/Archiving
17Autoreq: 0
18%endif
19
20%if %is_mandrake
21%define src %{name}-%{version}.tar.bz2
22Group: Archiving/Backup
23Autoreqprov: no
24%endif
25
26%if %is_mandriva
27%define src %{name}-%{version}.tar.bz2
28Group: Archiving/Backup
29Autoreqprov: no
30%endif
31
32Summary: Mindi creates emergency boot disks/CDs using your kernel, tools and modules
33Name: %name
34Version: %version
35Release: %mrel
36License: GPL
37Group: System/Kernel and hardware
38Url: http://mondorescue.berlios.de
39Source: %{src}
40BuildRoot: %{_tmppath}/%{name}-%{version}
41Requires: bzip2 >= 0.9, mkisofs, ncurses, binutils, gawk, dosfstools, afio, which
42# Not on all systems
43#Conflicts: bonnie++
44
45%description
46Mindi takes your kernel, modules, tools and libraries, and puts them on N
47bootable disks (or 1 bootable CD image). You may then boot from the disks/CD
48and do system maintenance - e.g. format partitions, backup/restore data,
49verify packages, etc.
50
51%prep
52%{__rm} -rf $RPM_BUILD_ROOT
53%setup -n %name-%{version}
54
55%build
56%ifarch ia64
57%{__make} -f Makefile.parted2fdisk clean
58%{__make} -f Makefile.parted2fdisk
59%endif
60
61%install
62export DONT_RELINK=1
63
64%{__rm} -rf $RPM_BUILD_ROOT
65MINDIDIR=$RPM_BUILD_ROOT%{_datadir}/mindi
66
67%{__mkdir_p} $MINDIDIR $RPM_BUILD_ROOT%{_bindir} $RPM_BUILD_ROOT%{_sysconfdir}/mindi $RPM_BUILD_ROOT%{_sbindir}
68%{__cp} deplist.txt $RPM_BUILD_ROOT%{_sysconfdir}/mindi/
69%{__cp} -af * $MINDIDIR
70
71%ifarch ia64
72 %{__make} -f Makefile.parted2fdisk DEST=${MINDIDIR}/ install
73 %{__mv} $MINDIDIR/rootfs/bin/busybox-ia64 $MINDIDIR/rootfs/bin/busybox
74 %{__mv} $MINDIDIR/rootfs/sbin/parted2fdisk-ia64 $MINDIDIR/rootfs/sbin/parted2fdisk
75%else
76 %{__mv} $MINDIDIR/rootfs/bin/busybox-i386 $MINDIDIR/rootfs/bin/busybox
77 %{__mv} $MINDIDIR/rootfs/bin/busybox-i386.net $MINDIDIR/rootfs/bin/busybox.net
78 %{__ln_s} fdisk $MINDIDIR/rootfs/sbin/parted2fdisk
79%endif
80%{__rm} -f $MINDIDIR/rootfs/bin/busybox-ia64 $MINDIDIR/rootfs/sbin/parted2fdisk-ia64 $MINDIDIR/rootfs/bin/busybox-i386 $MINDIDIR/rootfs/bin/busybox-i386.net
81
82#
83# These are installed twice if not removed here
84#
85( cd $MINDIDIR
86%{__rm} -f CHANGES INSTALL COPYING README TODO README.ia64 README.pxe
87)
88
89# Symlinks
90
91cd $RPM_BUILD_ROOT%{_sbindir}
92%{__ln_s} -f %{_datadir}/mindi/mindi .
93%{__ln_s} -f %{_datadir}/mindi/analyze-my-lvm .
94%ifarch ia64
95%{__ln_s} -f %{_datadir}/mindi/parted2fdisk.pl .
96%endif
97
98%clean
99%{__rm} -rf $RPM_BUILD_ROOT
100
101%post
102%ifarch ia64
103 %{__mkdir_p} /usr/local/bin
104 if [ "`file /sbin/fdisk |grep 'LF 64-bit LSB executable'`" ] ; then
105 %{__cp} /sbin/fdisk /sbin/fdisk.mondosav
106 %{__mv} /sbin/fdisk /usr/local/bin/fdisk
107 %{__ln_s} -f /usr/share/mindi/parted2fdisk.pl /sbin/fdisk
108 echo "Warning: you fdisk binary is now under /usr/local/bin"
109 fi
110%endif
111
112%files
113%defattr(644,root,root,755)
114%config(noreplace) %{_sysconfdir}/mindi/deplist.txt
115%doc CHANGES INSTALL COPYING README TODO README.ia64 README.pxe
116%attr(755,root,root) %{_sbindir}/mindi
117%attr(755,root,root) %{_sbindir}/analyze-my-lvm
118%{_datadir}/mindi
119%attr(755,root,root) %{_datadir}/mindi/analyze-my-lvm
120%attr(755,root,root) %{_datadir}/mindi/mindi
121%attr(755,root,root) %{_datadir}/mindi/parted2fdisk.pl
122%attr(755,root,root) %{_datadir}/mindi/aux-tools/sbin/*
123%attr(755,root,root) %{_datadir}/mindi/rootfs/bin/*
124%attr(755,root,root) %{_datadir}/mindi/rootfs/sbin/*
125
126%changelog
127* Tue Sep 06 2005 Bruno Cornec <bcornec@users.berlios.de> 1.04_berlios
128- Merge of patches mentionned on mondo ML + ia64 updates
129- Fix bugs when called alone
130
131* Tue May 03 2005 Hugo Rabson <hugorabson@msn.com> 1.04_cvs_20050503
132- supports exec-shield
133
134* Wed Aug 04 2004 Hugo Rabson <hugorabson@msn.com> 1.03
135- better support of SLES 8
136
137* Mon Jun 28 2004 Hugo Rabson <hugorabson@msn.com> 1.02
138- better kernel-level logging
139- added ACL, xattr binaries to deplist.txt
140- fixed obscure bug which occasionally stopped mindi from correctly finding
141 and documenting all LVM2 LVM-on-RAID volumes
142
143* Fri Jun 25 2004 Hugo Rabson <hugorabson@msn.com> 1.01
144- added ide_tape and other modules to mindi's config detection
145- unmount errant ramdisk ($mtpt) if fail to create boot floppy
146- better support of ISO dirs at restore-time (Conor Daly)
147
148* Fri Jun 18 2004 Hugo Rabson <hugorabson@msn.com> 1.00
149- first 1.0x release
150- busybox now static
151- trap Ctrl-Alt-Del; trigger soft reset
152- better SuSE 9.1 support
153- added parted2fdisk.pl (IA64) (Bruno Cornec)
154- add LVM2 support for kernel 2.6 (Takeru Komoriya)
155- better detection of multiple Mindis (Martin Fürstenau)
156- don't complain if just a Mindi boot CD & not a platform for Mondo
157- updated busybox to 1.0.0pre10
158- removed uClibc
159- add memtest support
160- 2.6 kernel support
161- removed Embleer files (Andree Leidenfrost)
162- added kernel-only floppy support, to accommodate really big kernels
163- updated+rebuilt busybox
164- added star support
165- mount /sys at boot-time
166- better 64-bit and 2.6 kernel support
167- better LVM, failsafe kernel support (Jim Richard)
168- use LILO, not raw kernel, on 1.4MB boot floppy
169- record names of unsaved modules, for future reference
170- enlarged ramdisk by 8MB
171
172* Wed Oct 22 2003 Hugo Rabson <hugorabson@msn.com> 0.95
173- changed some '==' to '=' --- now more RH6-friendly
174- allow absolute pathnames again in deplist
175- disable multifunc cd thing
176- better Gentoo support (Bill)
177- better OnStream support
178- better Slackware support (Laurenz)
179- added partimagehack-static to deplist.txt
180- recompiled Busybox - now 10k smaller; better stack-handling
181- fixed boot screen typo
182- added support for 'auto' fs format
183- better devfs support for Mandrake users
184- better Debian+LVM support (Ralph Grewe)
185- updated analyze-my-lvm to handle floating-point gigabyte -L values
186
187* Thu Jul 24 2003 Anonymous <root@rohan> 0.94
188- altered rootfs's /dev entry to stop cvs from becoming confused
189- tweaked MAX_COMPRESSED_SIZE
190- added multi-function CD support to mindi and sbin/post-init
191- re-mount root as rw just in case
192- ask user to remove last data (floppy) disk if nec. (Tom Mortell)
193- added support for 5th column in mountlist.txt for labels
194- added symlinks.tgz
195- suppress erroneous error msgs re: failsafe kernel
196
197* Sun May 18 2003 Hugo Rabson <hugorabson@msn.com> 0.93
198- added cciss.o to SCSI_MODS
199- if format type is (e.g.) ext3,ext2 then use 1st entry
200- re-enabled fsck*
201- if cciss in use the enable it at boot-time
202- added /dev/ataraid/* to boot disk via ataraid.tgz (Luc S.)
203- better ISO support
204- tweaked Mindi to use 10-15% fewer floppies
205- added RUN_AFTER_INITIAL_BOOT_PHASE to let user specify a command
206 to be run by Mindi before it bootstraps to aux data disks;
207 e.g. 'echo engage > /proc/scsi/something'
208- added RUN_AFTER_BOOT_PHASE_COMPLETE to let user specify a command
209 to be run by Mindi after it boots but before it runs mondorestore
210- allow for Debian & other Stiefkinder that use 'none', not 'swap'
211 as the mountpoint of the swap partition
212- removed afio dependency
213- re-worked install.sh and tarball not to use tgz's
214- cleared up the boot msg
215- updated busybox to 0.60.5; updated uClibc to 0.9.19
216- add #!/bin/sh to start of insert-all-my-modules
217- fixed obscure bug in install-additional-tools
218- changed grep -m to grep | head -n1 for Debian users
219- moved vmlinuz, lib.tar.bz2 to mindi-kernel tarball/rpm
220
221* Wed Apr 09 2003 Hugo Rabson <hugorabson@msn.com> 0.92
222- fixed LVM/RAID bugs (Brian Borgeson)
223- if bad lilo, give more verbose error before quitting
224- added mt and perl to deplist.txt
225- insist on gawk being present
226- insmod ide-cd, cdrom, isofs, just in case
227- boot-time tmpfs ramdisk is now 40m (was 34m)
228- cleaned up logs
229- iso mode now calls Interactive
230- make SizeOfPartition() more Debian-friendly (Andree Leidenfrost)
231- clean up some calls to grep, esp. partition_mountpt=...
232- corrected some bashisms, to suit Debian ped- er, users
233- made first line refer to bash, not sh, to make sure
234 the Debian people know Mindi requires bash, not hs
235- changed grep -v "#" and grep -vx "#.*" to grep -vx " *#.*"
236- disabled code which would have made Mindi use sfdisk instead of fdisk
237 if it looked as if Debian's fdisk would misbehave
238
239* Wed Feb 12 2003 Hugo Rabson <hugorabson@msn.com> 0.91
240- new devel branch
241- EXTRA_SPACE=16384
242- updated ResolveSoftlinks() to work better with b0rkn Gentoo devfs /dev
243- patched analyze-my-lvm (Benjamin Mampaey)
244- detect built-in boot.b files in lilo
245- cleaned up spec file a bit, more use of macros (Jesse Keating)
246- return w/err, don't abort, if Matt Nelson's RH8 system is farked
247- better at finding isolinux.bin
248- better at analyzing dependencies when running on broken distributions
249- try harder to boot from CD, even if tape fails
250- added ADDITIONAL_BOOT_PARAMS to be sent to kernel
251- better resolution of relative softlinks, leading to fewer
252 duplicates on data disks and therefore fewer data disks
253- detect Debian+devfs; use sfdisk instead of fdisk in that
254 eventuality, to work around yet another of Debian's warts
255- removed /lib/libuuid.* from rootfs.tgz
256- fixed vi
257- mindi now uses gawk --traditional (making gawk behave in a functionally
258 identical way to awk) - PASS; great, so now Debian needs to fix its awk :)
259- removed / from list of dirs accessed when trying to resolve deplist entry
260- spinner bugfix; handle odd LABELs properly (Tom Mortell)
261- fixed LVM/RAID bugs (Brian Borgeson)
262
263* Mon Dec 02 2002 Hugo Rabson <hugo@firstlinux.net> 0.72_20021202
264- misc code clean-up
265- save boot device's boot sector
266- detect and beware Compaq diagnostic partitions
267- better handling of devfs V non-devfs kernels and boot devs
268- trimmed busybox 0.60.3 binary on boot disk
269- mindi now resides in /usr/local/bin
270- removed lilo from dependencies
271- more Gentoo-friendly
272
273* Sun Nov 18 2002 Hugo Rabson <hugo@firstlinux.net> 0.71
274- if your kernel's builddate doesn't match any of the kernels in
275 your /boot directory then fudge the issue & find the closest
276 match (*grumble* Debian)
277- scan tape & CD at start, to force inclusion of modules on boot device
278- double EXTRA_SPACE if >7 disks
279- slimmer, more lithesome logfile
280- now accepts --findkernel
281- line 1982 - dd count=24000 should be count=$ramdisksize (Andras Korn)
282- better handling of non-Linux partitions on DevFS-enabled kernels
283- misc clean-ups
284- fixed Debian/ramdisksize/bloat problem (Johannes Franken)
285- fixed 2.4.20/fdisk eccentricity (Alistair Stevens)
286- updated kernel to 2.4.18-mdk6
287- generate mountlist in dev-abetical order ;)
288- fixed minor bug in .spec file
289- better at finding /boot/boot.b if your distro breaks the de facto standard
290- fixed minor bug in MakeMountlist
291- fixed install.sh
292- cleaned up deplist.txt
293- added rudimentary -v / --version flag
294- line 1180 or so --- duplicate mindi.iso entries --- fixed
295- added /bin/[ - a softlink to /bin/sh
296- ListAllPartitions() - sanity fix (KP)
297- fixed .spec bug
298- better feedback
299- added Markus's RAID patch
300- ListAllPartitions() - include /mnt/win* (Hugo)
301
302* Sun Sep 08 2002 Hugo Rabson <hugo@firstlinux.net> 0.70
303- better logging by dependency-calculating code
304- better handling of dependencies, specifically softlinks
305- if called by mondo then use mondo's temp dir as our temp dir too
306- changed gawk to $AWK in a few places, to allow for Debian
307- added host* config files to deplist
308- added tftp, ifconfig to busybox
309- added RPC support to uClibc
310- cleaned up creation of Mondo-Mindi configuration file
311- fixed bug in TryToFindKernelPath which stopped it from handling
312 multiple, same-version kernels gracefully
313- cleaned up deplist.txt
314- receive 'DIFFERENTIAL' variable from Mondo
315- better Debian compatibility, esp. w/detection of ver# (Hector Alvarez)
316- better devfs support; call fgrep in places instead of grep (Andrew Korn)
317- fixed analyze-my-lvm (Ralph Gruwe)
318- moved 50K of stuff from rootfs.tgz to aux-tools.tgz
319- added x11-tools.tgz option
320- updated /dev/console and /dev/tty0 (Paul Stevens)
321- cleaned up /mnt/groovy-stuff V /tmp/tmpfs code
322- catch sigint, sighup, etc.
323- fixed LILO-related message.txt mistake
324- .spec file clean-up; automation; config file (Carl Wilhem Soderstrom)
325- better devfs support (Andrew Korn)
326
327* Sun Jul 14 2002 Hugo Rabson <hugo@firstlinux.net> 0.64-1
328- fixed RH7.3 readonly bug
329- improved nfs config file creation
330- search more locations for isolinux.bin
331- added isonuke option
332- faster data disk creation
333- better DevFS support (Hector Alvarez, DuckX)
334- nfs-related fix (Hans Lie)
335- abort if vfat filesystem present but mkfs.vfat missing
336- removed softlink to pico
337- allow Mondo to say no compression will be used
338- added [ to ramdisk
339- tar data disks with -b [block size] of 32k
340- don't autoboot to 'RESTORE' screen - it's scary!
341- let user choose lilo or syslinux as boot loader
342- added syslinux support
343- cleaned up message screens
344
Note: See TracBrowser for help on using the repository browser.