Sophie

Sophie

distrib > Mandriva > 2010.0 > x86_64 > media > main-release-src > by-pkgid > 20590f80c1f2f4c859869aea7e8d094a > files > 8

partimage-0.6.8-1mdv2010.0.src.rpm

%define	name	partimage 
%define release	%mkrel 1
%define	version	0.6.8

Summary: 	Partition Image
Name: 		%{name}
Version: 	%{version}
Release: 	%{release}
URL: 		http://www.partimage.org/
License: 	GPL
Group: 		Archiving/Backup
Source: 	%{name}-%{version}.tar.bz2
Source1:	partimage.1
Source2:	partimaged.8
Source3:	partimagedusers.5
Source4:	partimaged-sysconfig
Source5:	partimaged-init.d
Patch1: 	partimage-0.6.7-chown.patch
Patch3: 	partimage-0.6.7-ssl-certs-policy.patch
Patch12:	partimage-0.6.8-lzma.patch
Patch13:	partimage-0.6.7-splash.patch
Patch14:	partimage-0.6.8-format-security.patch
BuildRequires:	automake1.8
BuildRequires:	bzip2-devel
BuildRequires:	gettext-devel
BuildRequires:	liblzmadec-devel
BuildRequires:	newt-devel
BuildRequires:	openssl
BuildRequires:	openssl-devel
BuildRequires:	zlib-devel
BuildRequires:	rpm-helper >= 0.21
Requires:	openssl > 0.9.6
Requires(post): rpm-helper >= 0.21
Buildroot: 	%{_tmppath}/%{name}-%{version}

%description
Partition Image is a Linux/UNIX partition imaging utility: it saves
partitions in the following file system formats to an image file:
- Ext2FS & Ext3FS (the linux standard),
- FAT16/32 (DOS & Windows file systems),
- HFS (MacOS File System),
- JFS (Journalised File System, from IBM, used on Aix),
- NTFS (Windows NT File System),
- HPFS (IBM OS/2 File System),
- ReiserFS (a journalized and powerful file system),
- UFS (Unix File System),
- XFS (another jounalized and efficient File System, from SGI, used on Irix),

Only used blocks are copied. The image file can be 
compressed in the GZIP/BZIP2 formats to save disk space, and splitted 
into multiple files to be copied on amovibles floppies (ZIP for example),
or burned on a CD-R ...

This allows to save a full Linux/Windows system, with an only 
operation. When problems (viruses, crash, error, ...), you just have to 
restore, and after several minutes, all your system is restored (boot, 
files, ...), and fully working.

This is very useful when installing the same software on many 
machines: just install one of them, creat|e an image, and just restore 
the image on all other machines. Then, after the first one, each 
installation is automatically made, and only require a few minutes.

%prep
%setup -q
%patch1 -p1
%patch3 -p1
%patch12 -p1 -b .lzma
%patch13 -p1 -b .splash
%patch14 -p1 -b .strfmt

for i in %{_datadir}/automake-1.*/mkinstalldirs; do cp -f $i .; done

%build
cp %{_datadir}/gettext/config.rpath .
autoreconf # needed on 2007.0
%configure
%make

%install
rm -rf  %{buildroot}
%makeinstall

rm -rf %{buildroot}%{_infodir}/*

install -m644 %{SOURCE1} -D %{buildroot}%{_mandir}/man1/partimage.1
install -m644 %{SOURCE2} -D %{buildroot}%{_mandir}/man8/partimaged.8
install -m644 %{SOURCE3} -D %{buildroot}%{_mandir}/man5/partimagedusers.5
install -m644 %{SOURCE4} -D %{buildroot}%{_sysconfdir}/sysconfig/partimaged
install -m755 %{SOURCE5} -D %{buildroot}%{_initrddir}/partimaged

cat > README.mdv <<EOF
Mandriva RPM specific notes

setup
-----
In order to comply with Mandriva SSL certificates policy, partimage binary has
been modified to use the following files:
- /etc/pki/tls/certs/partimage.pem instead of default
  /etc/partimaged/partimaged.cert
- /etc/pki/tls/private/partimage.pem instead of default
  /etc/partimaged/partimaged.key
EOF

%find_lang %{name}

%pre
/usr/sbin/groupadd -r -f partimag > /dev/null 2>&1 ||:
/usr/sbin/useradd -g partimag -d /home/partimag -r -s /bin/bash partimag > /dev/null 2>&1 ||:

%post
dir=/var/lib/partimage
if [ ! -d $dir ]; then 
    mkdir -p $dir/{dev,etc,%_lib,var/log}
    cp -a /dev/{null,tty} $dir/dev
    cp /%_lib/{libnss_compat.so.2,libnss_files.so.2} $dir/%_lib
    grep partimag /etc/passwd > $dir/etc/passwd
    grep partimag /etc/group > $dir/etc/group
    install -d -o partimag $dir/data
fi
# now all you have to do is run partimaged -D --chroot /var/lib/partimage
%_post_service partimaged
%_create_ssl_certificate partimage -g partimag

%preun
%_preun_service partimaged

%clean
rm -rf %{buildroot}

%files -f %{name}.lang
%defattr (-,root,root)
%doc BOOT-ROOT.txt BUGS AUTHORS ABOUT-NLS COPYING ChangeLog
%doc FORMAT FUTURE README README.partimaged README.mdv
%doc THANKS TODO
%{_sbindir}/*
%{_sysconfdir}/sysconfig/partimaged
%{_initrddir}/partimaged
%attr(0600,partimag,partimag) %config(noreplace) %{_sysconfdir}/partimaged/partimagedusers
%{_mandir}/man1/partimage.1*
%{_mandir}/man5/partimagedusers.5*
%{_mandir}/man8/partimaged.8*


%changelog
* Sat Sep 26 2009 Frederik Himpe <fhimpe@mandriva.org> 0.6.8-1mdv2010.0
+ Revision: 449320
- Fix BuildRequires for lzma support
- Update to new version 0.6.8
- Remove patches integrated upstream (nologin, inttypes, setegid,
  set-effective-gid, save_file_and_rest_file_actions, nossl, gcc43)
- Remove slang patch: not needed because it uses -I/usr/include/slang
- Remove disable_header_check Debian patch: not needed since 0.6.5
  according to Debian changelog
- Rediff lzma patch
- Add patch fixing build with -Werror=format-security

* Wed Nov 05 2008 Olivier Blin <oblin@mandriva.com> 0.6.7-12mdv2009.1
+ Revision: 300043
- fix crash in restore when bootsplash is disabled in kernel

* Thu Sep 04 2008 Olivier Blin <oblin@mandriva.com> 0.6.7-11mdv2009.0
+ Revision: 280712
- create /etc/group in jail
- fix setting group when dropping privileges (#42890)

* Fri Jun 13 2008 Olivier Blin <oblin@mandriva.com> 0.6.7-9mdv2009.0
+ Revision: 218815
- do not use jail by default (make it configurable in /etc/sysconfig/partimaged)
- run partimaged in jail without login and ssl support

* Thu Jun 12 2008 Olivier Blin <oblin@mandriva.com> 0.6.7-8mdv2009.0
+ Revision: 218372
- bump release
- update bootsplash support from Brazilian OEM package (salem/claudio/ehabkost ?)
- initial bootsplash support from Brazilian OEM package (salem/claudio/ehabkost ?)
- lzma support from Brazilian OEM package (salem/claudio/ehabkost ?)
- make sure inttypes.h is included early (so that other headers like lzmadec.h do not include it in a wrong way)

* Wed Jun 11 2008 Guillaume Rousse <guillomovitch@mandriva.org> 0.6.7-7mdv2009.0
+ Revision: 217867
- add README.mdv with mandriva-specific SSL certs note

* Tue Jun 10 2008 Olivier Blin <oblin@mandriva.com> 0.6.7-6mdv2009.0
+ Revision: 217690
- remove support of "--with jail" (last pixelware bits)
- always create jail and install initscript
- always create certificates
- always install partimagedusers
- do not disable login and ssl support when building jail, this can now be disabled at runtime
- always apply save/rest_file patch
- allow --nologin for client (even if built with login support)
- allow --nossl for server (even if built with ssl support)
- do not redefine write_unsigned and read_unsigned in save/rest_file patch

* Mon Jun 09 2008 Thierry Vignaud <tvignaud@mandriva.com> 0.6.7-5mdv2009.0
+ Revision: 217015
- other file systems are supported
- add missing colon
- reorder FSes (silent)
- fix description

* Fri Jun 06 2008 Pixel <pixel@mandriva.com> 0.6.7-4mdv2009.0
+ Revision: 216456
- fix build with gcc 4.3

* Wed May 07 2008 Guillaume Rousse <guillomovitch@mandriva.org> 0.6.7-3mdv2009.0
+ Revision: 202834
- patch4: set effective gid as well as effective uid, to be able to use group perms

* Wed Mar 05 2008 Guillaume Rousse <guillomovitch@mandriva.org> 0.6.7-2mdv2008.1
+ Revision: 180009
- ssl certs policy compliance

* Mon Feb 04 2008 Frederik Himpe <fhimpe@mandriva.org> 0.6.7-1mdv2008.1
+ Revision: 162508
- New upstream version
- Remove patch 6,7: integrated upstream
- Rediff patch 1
- Add LSB headers to partimaged init script (copied from Debian)

  + Olivier Blin <oblin@mandriva.com>
    - restore BuildRoot

  + Thierry Vignaud <tvignaud@mandriva.com>
    - kill re-definition of %%buildroot on Pixel's request

* Thu Jul 26 2007 Herton Ronaldo Krzesinski <herton@mandriva.com.br> 0.6.5-5mdv2008.0
+ Revision: 56115
- Added workaround from debian to allow partimage run on x86_64
  (partimage-0.6.5-deb_disable_header_check.patch). Closes: #20740

* Thu May 31 2007 Herton Ronaldo Krzesinski <herton@mandriva.com.br> 0.6.5-4mdv2008.0
+ Revision: 33397
- Rebuild again, for rpm changelog fix.

* Thu May 31 2007 Herton Ronaldo Krzesinski <herton@mandriva.com.br> 0.6.5-3mdv2008.0
+ Revision: 33309
- Rebuild with libnewt0.52.


* Tue Mar 06 2007 Pixel <pixel@mandriva.com> 0.6.5-2mdv2007.0
+ Revision: 133763
- add autoreconf (as explained by Olivier Lahaye)

* Tue Mar 06 2007 Pixel <pixel@mandriva.com> 0.6.5-1mdv2007.1
+ Revision: 133552
- new release
- drop menu (partimage is useful only as superuser)
- drop patch 2,4,5 (applied upstream)
- adapt patch 1,8
- updated %%doc
  (thanks to Olivier Lahaye)
- Import partimage

* Mon Nov 14 2005 Oden Eriksson <oeriksson@mandriva.com> 0.6.4-11mdk
- rebuilt against openssl-0.9.8a

* Fri Oct 21 2005 Pixel <pixel@mandriva.com> 0.6.4-10mdk
- dont discard some more error messages in batch mode (patch7)

* Thu Oct 20 2005 Pixel <pixel@mandriva.com> 0.6.4-9mdk
- dont discard error message in batch mode (patch7)

* Tue Oct 18 2005 Pixel <pixel@mandriva.com> 0.6.4-8mdk
- replace save_all and rest_all with save_file and rest_file 
  (we now use a perl script around partimage instead of 
   doing everything inside partimage with sfdisk)

* Wed Aug 24 2005 Gwenole Beauchesne <gbeauchesne@mandriva.com> 0.6.4-7mdk
- varargs fixes

* Mon Feb 21 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 0.6.4-6mdk
- 64-bit & lib64 fixes

* Mon Jan 31 2005 Pixel <pixel@mandrakesoft.com> 0.6.4-5mdk
- ensure the patch save_all_and_rest_all_actions is in the srpm
- add a service partimaged when in jail
- don't hardwire the automake directory, take any mkinstalldirs
- remove rubbish in info dir

* Mon Jan 24 2005 Pixel <pixel@mandrakesoft.com> 0.6.4-4mdk
- allow building with no authentication but in a jail
- in this forked version, add action save_all and rest_all

* Mon Nov 22 2004 Stefan van der Eijk <stefan@mandrake.org> 0.6.4-3mdk
- BuildRequires

* Sat Jul 24 2004 Marcel Pol <mpol@mandrake.org> 0.6.4-2mdk
- build against new slang

* Thu Jun 17 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 0.6.4-1mdk
- 0.8.4
- cleanups