source: branches/stable/mindi/distributions/rpm/mindi.spec @ 388

Last change on this file since 388 was 388, checked in by bcornec, 14 years ago

RPMs are now made with a .spec containing m4 macros expanded with tools/mkrpm
this allows for a simpler spec file at the end,
which should be suited for at least Mandriva official packages.
Added a new mkspec tool which does the expansion
This way of dealing with distributions will be used is some other areas in the future

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