1
0
Fork 0

Added actual download to build.sh

This commit is contained in:
Stefan Reimer 2011-10-28 14:14:56 -07:00
parent 64f8a61179
commit 360261769b
1 changed files with 13 additions and 0 deletions

View File

@ -53,6 +53,19 @@ bootstrap() {
STAGE_TARBALL=${GENTOO_MIRROR}/releases/${STAGE_ARCH}/autobuilds/$(curl -s ${LATEST_STAGE_FILE} | grep -v "^#" | head -n 1)
PORTAGE_SNAPSHOT="${GENTOO_MIRROR}/snapshots/portage-latest.tar.bz2"
[ -d ${ROOT_FS} ] || die "${ROOT_FS} does not exists"
[ -w ${ROOT_FS} ] || die "${ROOT_FS} isn't writable"
cd ${ROOT_FS}
if [ ! -d "usr" ] ; then
wget "${STAGE_TARBALL}" || die "Getting stage file from ${STAGE_TARBALL} failed"
tar jxpf stage3*.bz2 || die "Extracting stage file failed"
fi
if [ ! -d "usr/portage" ] ; then
wget "${PORTAGE_SNAPSHOT}" || die "Getting portage snapshot ${PORTAGE_SNAPSHOT} failed"
tar jxf portage-latest.tar.bz2 -C "${ROOT_FS}/usr" || die "Extracting portage snapshot failed"
fi
}