diff options
Diffstat (limited to 'system/debootstrap')
-rw-r--r-- | system/debootstrap/README | 9 | ||||
-rw-r--r-- | system/debootstrap/debootstrap.SlackBuild | 74 | ||||
-rw-r--r-- | system/debootstrap/debootstrap.info | 8 | ||||
-rw-r--r-- | system/debootstrap/slack-desc | 19 | ||||
-rw-r--r-- | system/debootstrap/slackware.patch | 34 |
5 files changed, 144 insertions, 0 deletions
diff --git a/system/debootstrap/README b/system/debootstrap/README new file mode 100644 index 0000000000..cdd078cf71 --- /dev/null +++ b/system/debootstrap/README @@ -0,0 +1,9 @@ +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. +It's especially useful if you need to work on debian-like systems without having +to install them over our beloved Slackware ;-) + +As we do not have dpkg, remember to always pass an architecture to debootstrap +using the --arch switch. diff --git a/system/debootstrap/debootstrap.SlackBuild b/system/debootstrap/debootstrap.SlackBuild new file mode 100644 index 0000000000..5cb21bb118 --- /dev/null +++ b/system/debootstrap/debootstrap.SlackBuild @@ -0,0 +1,74 @@ +#!/bin/sh + +# Slackware build script for Debootstrap + +# Copyright 2009 Marco Bonetti <sid77@slackware.it> +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PRGNAM=debootstrap +VERSION=${VERSION:-1.0.11} +ARCH=${ARCH:-noarch} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +DOCS="debian/README.Debian debian/changelog debian/copyright" + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM +tar xvf $CWD/${PRGNAM}_$VERSION.tar.gz +cd $PRGNAM + +patch -p1 < $CWD/slackware.patch +cp $CWD/devices.tar.gz . + +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; + +make install DESTDIR=$PKG +mkdir -p $PKG/usr/man/man8 +install -o root -g root -m 0644 debootstrap.8 $PKG/usr/man/man8/ + +( cd $PKG/usr/man + find . -type f -exec gzip -9 {} \; + for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done +) + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz diff --git a/system/debootstrap/debootstrap.info b/system/debootstrap/debootstrap.info new file mode 100644 index 0000000000..a056aacad2 --- /dev/null +++ b/system/debootstrap/debootstrap.info @@ -0,0 +1,8 @@ +PRGNAM="debootstrap" +VERSION="1.0.11" +HOMEPAGE="http://packages.debian.org/sid/debootstrap" +DOWNLOAD="http://slackbuilds.org/sources/12.2/debootstrap_1.0.11.tar.gz" +MD5SUM="6e52cb3a7084d0ed89a8ba0fbd95543b" +MAINTAINER="Marco Bonetti" +EMAIL="sid77@slackware.it" +APPROVED="rworkman" diff --git a/system/debootstrap/slack-desc b/system/debootstrap/slack-desc new file mode 100644 index 0000000000..b4e7871429 --- /dev/null +++ b/system/debootstrap/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + + |-----handy-ruler-------------------------------------------------------| +debootstrap: debootstrap (create a Debian base system from scratch) +debootstrap: +debootstrap: Debootstrap is used to create a Debian base system from scratch, +debootstrap: without requiring the availability of dpkg or apt. It does this by +debootstrap: downloading .deb files from a mirror site, and carefully unpacking +debootstrap: them into a directory which can eventually be chrooted into. +debootstrap: +debootstrap: +debootstrap: +debootstrap: +debootstrap: diff --git a/system/debootstrap/slackware.patch b/system/debootstrap/slackware.patch new file mode 100644 index 0000000000..9fb2e942f1 --- /dev/null +++ b/system/debootstrap/slackware.patch @@ -0,0 +1,34 @@ +diff -Naur debootstrap.orig/Makefile debootstrap/Makefile +--- debootstrap.orig/Makefile 2009-01-30 12:12:06.000000000 +0100 ++++ debootstrap/Makefile 2009-03-03 17:27:14.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 needed ++#ARCH := $(shell dpkg --print-architecture) + + MAKEDEV := $(shell if [ -e /dev/MAKEDEV ]; then echo /dev/MAKEDEV; else echo /sbin/MAKEDEV; fi) + +@@ -10,7 +11,7 @@ + rm -f devices.tar.gz + rm -rf dev + +-DSDIR=$(DESTDIR)/usr/share/debootstrap ++DSDIR=$(DESTDIR)/usr/lib/debootstrap + install: + mkdir -p $(DSDIR)/scripts + mkdir -p $(DESTDIR)/usr/sbin +diff -Naur debootstrap.orig/debootstrap debootstrap/debootstrap +--- debootstrap.orig/debootstrap 2009-01-13 20:30:15.000000000 +0100 ++++ debootstrap/debootstrap 2009-03-03 17:28:16.000000000 +0100 +@@ -10,7 +10,7 @@ + if [ -x /debootstrap/debootstrap ]; then + DEBOOTSTRAP_DIR=/debootstrap + else +- DEBOOTSTRAP_DIR=/usr/share/debootstrap ++ DEBOOTSTRAP_DIR=/usr/lib/debootstrap + fi + fi + |