From b47340f54abd497c4e4eca99694e35849ca40d66 Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Nov 18 2007 19:12:15 +0000 Subject: Initial import --- diff --git a/.cvsignore b/.cvsignore index e69de29..986460d 100644 --- a/.cvsignore +++ b/.cvsignore @@ -0,0 +1 @@ +debootstrap_1.0.7.tar.gz diff --git a/debootstrap-1.0.7-arch.patch b/debootstrap-1.0.7-arch.patch new file mode 100644 index 0000000..e457a28 --- /dev/null +++ b/debootstrap-1.0.7-arch.patch @@ -0,0 +1,13 @@ +diff -urp debootstrap.orig/Makefile debootstrap/Makefile +--- debootstrap.orig/Makefile 2007-11-17 19:17:15.000000000 +0100 ++++ debootstrap/Makefile 2007-11-17 19:19:11.000000000 +0100 +@@ -1,7 +1,8 @@ + # avoid dpkg-dev dependency; fish out the version with sed + VERSION := $(shell sed 's/.*(\(.*\)).*/\1/; q' debian/changelog) + +-ARCH := $(shell dpkg --print-architecture) ++# Not used at all ++#ARCH := $(shell dpkg --print-architecture) + + MAKEDEV := $(shell if [ -e /dev/MAKEDEV ]; then echo /dev/MAKEDEV; else echo /sbin/MAKEDEV; fi) + diff --git a/debootstrap-1.0.7-devices.patch b/debootstrap-1.0.7-devices.patch new file mode 100644 index 0000000..52819d3 --- /dev/null +++ b/debootstrap-1.0.7-devices.patch @@ -0,0 +1,11 @@ +diff -urp debootstrap.orig/Makefile debootstrap/Makefile +--- debootstrap.orig/Makefile 2007-11-17 19:22:29.000000000 +0100 ++++ debootstrap/Makefile 2007-11-17 19:23:03.000000000 +0100 +@@ -35,6 +35,6 @@ devices.tar.gz: + mkdir -p dev + chown 0:0 dev + chmod 755 dev +- (cd dev && $(MAKEDEV) std ptmx fd) ++ $(MAKEDEV) -d dev std ptmx fd + tar cf - dev | gzip -9 >devices.tar.gz + rm -rf dev diff --git a/debootstrap-1.0.7-perms.patch b/debootstrap-1.0.7-perms.patch new file mode 100644 index 0000000..5617574 --- /dev/null +++ b/debootstrap-1.0.7-perms.patch @@ -0,0 +1,28 @@ +diff -urp debootstrap.orig/Makefile debootstrap/Makefile +--- debootstrap.orig/Makefile 2007-11-17 19:32:40.000000000 +0100 ++++ debootstrap/Makefile 2007-11-17 19:33:52.000000000 +0100 +@@ -14,9 +14,9 @@ clean: + DSDIR=$(DESTDIR)/usr/share/debootstrap + install: + # Dirs are created by dh_installdirs +- install -o root -g root -m 0644 scripts/debian/* $(DSDIR)/scripts/ +- install -o root -g root -m 0644 scripts/ubuntu/* $(DSDIR)/scripts/ +- install -o root -g root -m 0644 functions $(DSDIR)/ ++ install -m 0644 scripts/debian/* $(DSDIR)/scripts/ ++ install -m 0644 scripts/ubuntu/* $(DSDIR)/scripts/ ++ install -m 0644 functions $(DSDIR)/ + + # no special script for etch anymore + ln -s sid $(DSDIR)/scripts/etch +@@ -25,10 +25,9 @@ install: + ln -s gutsy $(DSDIR)/scripts/hardy + + sed 's/@VERSION@/$(VERSION)/g' debootstrap >$(DESTDIR)/usr/sbin/debootstrap +- chown root:root $(DESTDIR)/usr/sbin/debootstrap + chmod 0755 $(DESTDIR)/usr/sbin/debootstrap + +- install -o root -g root -m 0644 devices.tar.gz $(DSDIR)/ ++ install -m 0644 devices.tar.gz $(DSDIR)/ + + devices.tar.gz: + rm -rf dev diff --git a/debootstrap.spec b/debootstrap.spec new file mode 100644 index 0000000..3e34220 --- /dev/null +++ b/debootstrap.spec @@ -0,0 +1,75 @@ +Name: debootstrap +Version: 1.0.7 +Release: 1%{?dist} +Summary: Bootstrap a basic Debian GNU/Linux system + +Group: System Environment/Base +License: MIT +URL: http://code.erisian.com.au/Wiki/debootstrap +Source0: http://ftp.debian.org/debian/pool/main/d/debootstrap/debootstrap_%{version}.tar.gz +Patch0: debootstrap-1.0.7-arch.patch +Patch1: debootstrap-1.0.7-devices.patch +Patch2: debootstrap-1.0.7-perms.patch +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildArch: noarch + +BuildRequires: fakeroot, MAKEDEV +Requires: gettext, wget, tar, gzip, binutils + + +%description +debootstrap is used to create a Debian base system from scratch, without +requiring the availability of dpkg or apt. It does this by downloading +.deb files from a mirror site, and carefully unpacking them into a +directory which can eventually be chrooted into. + +This might be often useful coupled with virtualization techniques to run +Debian GNU/Linux guest system. + + +%prep +%setup -q -n %{name} +%patch0 -p1 -b .arch +%patch1 -p1 -b .devices +%patch2 -p1 -b .perms + + +%build +# _smp_mflags would make no sense at all +fakeroot make + + +%install +rm -rf $RPM_BUILD_ROOT +install -d $RPM_BUILD_ROOT%{_datadir}/debootstrap/scripts/ +install -d $RPM_BUILD_ROOT%{_sbindir} +install -d $RPM_BUILD_ROOT%{_mandir}/man8 +install -m 0644 debootstrap.8 $RPM_BUILD_ROOT%{_mandir}/man8 +make install DESTDIR=$RPM_BUILD_ROOT \ + VERSION="%{version}-%{release}" + + +%clean +rm -rf $RPM_BUILD_ROOT + + +%files +%defattr(-,root,root,-) +%{_datadir}/debootstrap +%{_sbindir}/debootstrap +%{_mandir}/man8/debootstrap.8* +%doc debian/changelog debian/copyright debian/README.Debian + + +%changelog +* Sat Nov 17 2007 Lubomir Kundrak 1.0.7-1 +- Version bump + +* Thu Nov 15 2007 Lubomir Kundrak 1.0.3-2 +- Some more fixes, thanks to Patrice Dumas (#329291) + +* Fri Oct 12 2007 Lubomir Kundrak 1.0.3-1 +- Incorporating advises from Patrice Dumas (#329291) in account + +* Fri Oct 12 2007 Lubomir Kundrak 0.3.3.2etch1-1 +- Initial package diff --git a/sources b/sources index e69de29..b9110fa 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +bd446c40b90c6069178b23065d4179ca debootstrap_1.0.7.tar.gz