changeset 1259:3ffcb56847e3

Redo gentoo-boostrap on top of bootstrap-skeleton.
author Rob Landley <rob@landley.net>
date Thu, 07 Oct 2010 23:52:23 -0500
parents c264495fbf21
children fecb576b7e18
files sources/native-builds/gentoo-bootstrap/README sources/native-builds/gentoo-bootstrap/build/bash-build sources/native-builds/gentoo-bootstrap/build/file-build sources/native-builds/gentoo-bootstrap/build/functions.sh sources/native-builds/gentoo-bootstrap/build/init sources/native-builds/gentoo-bootstrap/build/ncurses-build sources/native-builds/gentoo-bootstrap/build/patch-build sources/native-builds/gentoo-bootstrap/build/portage-build sources/native-builds/gentoo-bootstrap/build/python-build sources/native-builds/gentoo-bootstrap/build/rsync-build sources/native-builds/gentoo-bootstrap/build/run-build-stages.sh sources/native-builds/gentoo-bootstrap/build/zlib-build sources/native-builds/gentoo-bootstrap/download.sh sources/native-builds/gentoo-bootstrap/files/emerge_wrapper.sh sources/native-builds/gentoo-bootstrap/files/etc/portage/profile/package.provided sources/native-builds/gentoo-bootstrap/make-control-image.sh sources/native-builds/gentoo-bootstrap/mnt/build/bash.sh sources/native-builds/gentoo-bootstrap/mnt/build/file.sh sources/native-builds/gentoo-bootstrap/mnt/build/ncurses.sh sources/native-builds/gentoo-bootstrap/mnt/build/patch.sh sources/native-builds/gentoo-bootstrap/mnt/build/portage.sh sources/native-builds/gentoo-bootstrap/mnt/build/python.sh sources/native-builds/gentoo-bootstrap/mnt/build/rsync.sh sources/native-builds/gentoo-bootstrap/mnt/build/zlib.sh sources/native-builds/gentoo-bootstrap/mnt/files/emerge_wrapper.sh sources/native-builds/gentoo-bootstrap/mnt/files/etc/portage/profile/package.provided
diffstat 26 files changed, 217 insertions(+), 363 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/README	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,16 @@
+Extend minimal native build environment into a seed for Gentoo Catalyst.
+
+This doesn't quite create an official Gentoo Stage 1.  We use busybox instead
+of gnu tools, we're uClibc-based instead of glibc-based, and we use our
+existing toolchain (with distcc acceleration) instead of asking portage
+to build one.  That said, this should be enough to run Catalyst and produce
+official Stage 1, Stage 2, and Stage 3 images.
+
+GFS used:
+
+  setup-base-packages.sh
+    strace, Python, ncurses, bash, tar, patch, findutils, file, pax-utils,
+    shadow
+  setup-portage.sh
+    /etc/passwd (root and portage), /etc/group (root and portage)
+    portage
--- a/sources/native-builds/gentoo-bootstrap/build/bash-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-# Portage uses bash ~= regex matches, which were introduced in bash 3.
-
-set_titlebar "Bash3" && cp -sfR /mnt/bash bash && cd bash &&
-
-./configure --enable-cond-regexp --disable-nls --prefix=/usr &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf bash || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/file-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-set_titlebar "file" && cp -sfR /mnt/file file && cd file &&
-
-./configure --prefix=/usr &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf file || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/functions.sh	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,40 +0,0 @@
-#!/bin/echo This file is sourced not run
-
-upload_result()
-{
-  ftpput $FTP_SERVER -P $FTP_PORT "$1-$HOST" "$1"
-}
-
-set_titlebar()
-{
-  echo -en "\033]2;($HOST) $1\007"
-  echo === "$1"
-}
-
-dotprogress()
-{
-  while read i; do echo -n .; done; echo
-}
-
-do_in_chroot()
-{
-  # Copy root filesystem into a new chroot directory and restart in there.
-
-  CHROOT="$1"
-  shift
-
-  set_titlebar "Setup chroot"
-  mkdir "$CHROOT"
-  cp -a /mnt/files/. "$CHROOT"
-  find / -xdev | cpio -m -v -p "$CHROOT" | dotprogress
-  for i in mnt proc sys dev; do mount --bind /$i "$CHROOT"/$i; done
-
-  echo Chroot
-  chroot "$CHROOT" "$@"
-  RC=$?
-
-  echo Chroot cleanup
-  for i in mnt proc sys dev; do umount "$CHROOT"/$i; done
-
-  return $RC
-}
--- a/sources/native-builds/gentoo-bootstrap/build/init	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,18 +0,0 @@
-#!/bin/bash
-
-# Start running, and hand off to run-build-stages.sh in chroot.
-
-. /mnt/functions.sh
-
-# Always chroot, because even if root filesystem is writeable it's hard to
-# tell tar to skip /proc and /sys and such without unmounting bits of the
-# host environment.
-
-do_in_chroot /home/chroot /mnt/run-build-stages.sh
-
-if [ $RC -eq 0 ]
-then
-  set_titlebar "upload tarball"
-  tar czvf gentoo-stage1.tar.gz gentoo-stage1 | dotprogress &&
-  upload_result gentoo-stage1.tar.gz
-fi
--- a/sources/native-builds/gentoo-bootstrap/build/ncurses-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-set_titlebar "ncurses" && cp -sfR /mnt/ncurses ncurses && cd ncurses &&
-
-./configure --without-cxx-binding --with-shared &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf ncurses || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/patch-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-# Need a patch with --dry-run to make portage happy
-
-set_titlebar "patch" && cp -sfR /mnt/patch patch && cd patch &&
-
-./configure --prefix=/usr &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf patch || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/portage-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,41 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-# Portage isn't really designed to be portable, so this script contains
-# the "make install" stage that portage really should have within itself.
-
-set_titlebar "portage" && cd /mnt/portage &&
-
-# Install portage user/group, and libraries.
-
-echo portage:x:250:250:portage:/var/tmp/portage:/bin/false >> /etc/passwd &&
-echo portage::250:portage >> /etc/group &&
-mkdir -p /usr/lib/portage &&
-cp -a bin pym /usr/lib/portage/ &&
-
-# Add portage python modules to the python search path.
-
-echo /usr/lib/portage/pym > /usr/lib/python2.6/site-packages/gentoo.pth ||
-  exit 1
-
-# Install portage binaries into bin and sbin
-
-for i in archive-conf dispatch-conf emaint emerge-webrsync env-update \
-         etc-update fixpackages quickpkg regenworld
-do
-  ln /usr/lib/portage/bin/$i /usr/sbin/$i || exit 1
-done
-
-for i in  ebuild egencache emerge portageq repoman
-do
-  ln /usr/lib/portage/bin/$i /usr/bin/$i || exit 1
-done
-
-# Install portage man pages
-
-cp cnf/make.globals /etc/ &&
-cp man/*.1 /usr/man/man1 &&
-cp man/*.5 /usr/man/man5 &&
-
-mkdir -p /var/log /etc/portage/profile || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/python-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-set_titlebar "Python" && cp -sfR /mnt/Python python && cd python &&
-
-./configure --prefix=/usr &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf python || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/rsync-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-set_titlebar "rsync" && cp -sfR /mnt/rsync rsync && cd rsync &&
-
-./configure --prefix=/usr &&
-# Break link and touch file, otherwise ./configure tries to recreate it
-# which requires perl.
-cat proto.h-tstamp > proto.h.new &&
-mv -f proto.h.new proto.h-tstamp &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf rsync || exit 1
--- a/sources/native-builds/gentoo-bootstrap/build/run-build-stages.sh	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,8 +0,0 @@
-#!/bin/sh
-
-# Run each of the individual package build files, in order.
-
-for i in zlib ncurses python bash rsync patch file portage
-do
-  cd /home && /mnt/${i}-build || exit 1
-done
--- a/sources/native-builds/gentoo-bootstrap/build/zlib-build	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,14 +0,0 @@
-#!/bin/sh
-
-. /mnt/functions.sh
-
-set_titlebar "zlib" && cp -sfR /mnt/zlib zlib && cd zlib &&
-
-# 1.2.5 accidentally shipped the Makefile, then configure tries to
-# modify it in place.
-rm Makefile && 
-./configure --prefix=/usr &&
-make -j $CPUS &&
-make install &&
-
-cd .. && rm -rf zlib || exit 1
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/download.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,36 @@
+#!/bin/bash
+
+# Download all the source tarballs we haven't got up-to-date copies of.
+
+URL=http://zlib.net/zlib-1.2.5.tar.bz2 \
+SHA1=543fa9abff0442edca308772d6cef85557677e02 \
+maybe_fork "download || dienow"
+
+URL=http://ftp.gnu.org/pub/gnu/ncurses/ncurses-5.7.tar.gz \
+SHA1=8233ee56ed84ae05421e4e6d6db6c1fe72ee6797 \
+maybe_fork "download || dienow"
+
+URL=http://python.org/ftp/python/2.6.5/Python-2.6.5.tar.bz2 \
+SHA1=24c94f5428a8c94c9d0b316e3019fee721fdb5d1 \
+RENAME='s/P/p/' \
+maybe_fork "download || dienow"
+
+URL=http://ftp.gnu.org/gnu/bash/bash-3.2.tar.gz \
+SHA1=fe6466c7ee98061e044dae0347ca5d1a8eab4a0d \
+maybe_fork "download || dienow"
+
+URL=http://www.samba.org/ftp/rsync/src/rsync-3.0.7.tar.gz \
+SHA1=63426a1bc71991d93159cd522521fbacdafb7a61 \
+maybe_fork "download || dienow"
+
+URL=http://ftp.gnu.org/gnu/patch/patch-2.5.9.tar.gz \
+SHA1=9a69f7191576549255f046487da420989d2834a6 \
+maybe_fork "download || dienow"
+
+URL=ftp://ftp.astron.com/pub/file/file-5.03.tar.gz \
+SHA1=f659a4e1fa96fbdc99c924ea8e2dc07319f046c1 \
+maybe_fork "download || dienow"
+
+URL=http://dev.gentoo.org/~zmedico/portage/archives/portage-2.1.8.tar.bz2 \
+SHA1=390c97f3783af2d9e52482747ead3681655ea9c3 \
+maybe_fork "download || dienow"
--- a/sources/native-builds/gentoo-bootstrap/files/emerge_wrapper.sh	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-#!/bin/bash
-
-if [ "$1" != "--sync" ]
-then
-  echo 'No portage tree, run "emerge --sync".' >&2
-  exit 1
-fi
-
-if [ "$(id -u)" -ne 0 ]
-then
-  echo "You are not root." >&2
-  exit 1
-fi
-
-echo "Downloading portage tree..."
-mkdir -p /var/log /usr/portage &&
-cd /usr &&
-#wget http://127.0.0.1/aboriginal/mirror/portage-latest.tar.bz2 -O - | \
-wget http://gentoo.osuosl.org/snapshots/portage-latest.tar.bz2 -O - | \
-  tar xjC /usr
-if [ ! -d portage ]
-then
-  echo "Failed to download portage-latest tarball." >&2
-  exit 1
-fi
-
-if ! emerge.real --sync
-then
-  echo "Sync failed"
-  exit 1
-fi
-
-cd $(dirname $(readlink -f $(which emerge.real)))
-mv emerge.real emerge
-
-echo "Portage tree initialized"
--- a/sources/native-builds/gentoo-bootstrap/files/etc/portage/profile/package.provided	Thu Oct 07 23:50:12 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-# Base aboriginal system
-
-sys-devel/gcc-4.2.1
-sys-devel/binutils-2.17
-sys-devel/make-3.81
-sys-libs/uclibc-0.9.31
-sys-kernel/linux-headers-2.6.35
-sys-apps/busybox-1.17.2
-
-# Stuff busybox provides
-
-app-arch/gzip-1.0
-sys-apps/sed-1.0
-sys-apps/findutils-1.0
-sys-apps/diffutils-1.0
-app-editors/vim-1.0
-sys-apps/gawk-1.0
-app-arch/tar-1.0
-app-arch/bzip2-1.0
-app-arch/cpio-1.0
-sys-process/procps-1.0
-sys-apps/which-1.0
-sys-apps/net-tools-1.0
-sys-apps/sysvinit-1.0
-sys-apps/util-linux-1.0
-sys-apps/coreutils-1.0
-sys-apps/less-1.0
-sys-apps/grep-1.0      
-sys-apps/shadow-1.0    
-sys-apps/module-init-tools-1.0
-net-misc/wget-1.0
-app-arch/xz-utils-1.0
-
-# Upgrades for seed
-
-sys-apps/portage-2.1.8.3
-dev-lang/python-2.6.5
-sys-libs/zlib-1.2.5
-sys-libs/ncurses-5.7
-app-shells/bash-3.2
-net-misc/rsync-3.0.7
-sys-devel/patch-2.5.9
-sys-apps/file-5.03
--- a/sources/native-builds/gentoo-bootstrap/make-control-image.sh	Thu Oct 07 23:50:12 2010 -0500
+++ b/sources/native-builds/gentoo-bootstrap/make-control-image.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -1,89 +1,1 @@
-#!/bin/bash
-
-# Extend minimal native build environment into a seed for Gentoo Catalyst.
-
-# This doesn't quite create an official Gentoo Stage 1.  We use busybox instead
-# of gnu tools, we're uClibc-based instead of glibc-based, and we use our
-# existing toolchain (with distcc acceleration) instead of asking portage
-# to build one.  That said, this should be enough to run Catalyst and produce
-# official Stage 1, Stage 2, and Stage 3 images.
-
-# GFS used:
-# setup-base-packages.sh
-#   strace, Python, ncurses, bash, tar, patch, findutils, file, pax-utils,
-#   shadow
-# setup-portage.sh
-#   /etc/passwd (root and portage), /etc/group (root and portage)
-#   portage
-
-# Download all the source tarballs we haven't got up-to-date copies of.
-
-# The tarballs are downloaded into the "packages" directory, which is
-# created as needed.
-
-source sources/include.sh || exit 1
-
-# Find path to our working directory.
-
-[ $# -ne 1 ] && echo "usage: $0 FILENAME" >&2 && exit 1
-[ "$1" != "/dev/null" ] && [ -e "$1" ] && echo "$1" exists && exit 0
-
-# We use a lot of our own directories because we may have the same packages
-# as the aboriginal build, but use different versions.  So keep things separate
-# so they don't interfere.
-
-MYDIR="$(dirname "$(readlink -f "$(which "$0")")")"
-IMAGENAME="${MYDIR/*\//}"
-PATCHDIR="$MYDIR/patches"
-SRCDIR="$SRCDIR/$IMAGENAME" && mkdir -p "$SRCDIR" || dienow
-WORK="$WORK/$IMAGENAME" && blank_tempdir "$WORK"
-SRCTREE="$WORK"
-
-echo "=== Download source code."
-
-EXTRACT_ALL=1
-
-URL=http://zlib.net/zlib-1.2.5.tar.bz2 \
-SHA1=543fa9abff0442edca308772d6cef85557677e02 \
-maybe_fork "download || dienow"
-
-URL=http://ftp.gnu.org/pub/gnu/ncurses/ncurses-5.7.tar.gz \
-SHA1=8233ee56ed84ae05421e4e6d6db6c1fe72ee6797 \
-maybe_fork "download || dienow"
-
-URL=http://python.org/ftp/python/2.6.5/Python-2.6.5.tar.bz2 \
-SHA1=24c94f5428a8c94c9d0b316e3019fee721fdb5d1 \
-maybe_fork "download || dienow"
-
-URL=http://ftp.gnu.org/gnu/bash/bash-3.2.tar.gz \
-SHA1=fe6466c7ee98061e044dae0347ca5d1a8eab4a0d \
-maybe_fork "download || dienow"
-
-URL=http://www.samba.org/ftp/rsync/src/rsync-3.0.7.tar.gz \
-SHA1=63426a1bc71991d93159cd522521fbacdafb7a61 \
-maybe_fork "download || dienow"
-
-URL=http://ftp.gnu.org/gnu/patch/patch-2.5.9.tar.gz \
-SHA1=9a69f7191576549255f046487da420989d2834a6 \
-maybe_fork "download || dienow"
-
-URL=ftp://ftp.astron.com/pub/file/file-5.03.tar.gz \
-SHA1=f659a4e1fa96fbdc99c924ea8e2dc07319f046c1 \
-maybe_fork "download || dienow"
-
-URL=http://dev.gentoo.org/~zmedico/portage/archives/portage-2.1.8.tar.bz2 \
-SHA1=390c97f3783af2d9e52482747ead3681655ea9c3 \
-maybe_fork "download || dienow"
-
-echo === Got all source.
-
-cleanup_oldfiles
-
-cp -a "$MYDIR/build/." "$WORK" &&
-cp -a "$MYDIR/files" "$WORK" || exit 1
-
-if [ "$1" != "/dev/null" ]
-then
-  cd "$TOP" &&
-  mksquashfs "$WORK" "$1" -noappend -all-root || dienow
-fi
+../bootstrap-skeleton/control-image-wrapper.sh
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/bash.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+# Portage uses bash ~= regex matches, which were introduced in bash 3.
+
+./configure --enable-cond-regexp --disable-nls --prefix=/usr &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/file.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+./configure --prefix=/usr &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/ncurses.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+./configure --without-cxx-binding --with-shared &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/patch.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+# Need a patch with --dry-run to make portage happy
+
+./configure --prefix=/usr &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/portage.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,37 @@
+#!/bin/sh
+
+# Portage isn't really designed to be portable, so this script contains
+# the "make install" stage that portage really should have within itself.
+
+# Install portage user/group, and libraries.
+
+echo portage:x:250:250:portage:/var/tmp/portage:/bin/false >> /etc/passwd &&
+echo portage::250:portage >> /etc/group &&
+mkdir -p /usr/lib/portage &&
+cp -a bin pym /usr/lib/portage/ &&
+
+# Add portage python modules to the python search path.
+
+echo /usr/lib/portage/pym > /usr/lib/python2.6/site-packages/gentoo.pth ||
+  exit 1
+
+# Install portage binaries into bin and sbin
+
+for i in archive-conf dispatch-conf emaint emerge-webrsync env-update \
+         etc-update fixpackages quickpkg regenworld
+do
+  ln /usr/lib/portage/bin/$i /usr/sbin/$i || exit 1
+done
+
+for i in  ebuild egencache emerge portageq repoman
+do
+  ln /usr/lib/portage/bin/$i /usr/bin/$i || exit 1
+done
+
+# Install portage man pages
+
+cp cnf/make.globals /etc/ &&
+cp man/*.1 /usr/man/man1 &&
+cp man/*.5 /usr/man/man5 &&
+
+mkdir -p /var/log /etc/portage/profile
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/python.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+./configure --prefix=/usr &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/rsync.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+./configure --prefix=/usr &&
+# Break link and touch file, otherwise ./configure tries to recreate it
+# which requires perl.
+cat proto.h-tstamp > proto.h.new &&
+mv -f proto.h.new proto.h-tstamp &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/build/zlib.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+# 1.2.5 accidentally shipped the Makefile, then configure tries to
+# modify it in place, which fails if the filesystem is read only.
+# The fix is to remove it before configuring.
+
+rm Makefile && 
+./configure --prefix=/usr &&
+make -j $CPUS &&
+make install
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/files/emerge_wrapper.sh	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,36 @@
+#!/bin/bash
+
+if [ "$1" != "--sync" ]
+then
+  echo 'No portage tree, run "emerge --sync".' >&2
+  exit 1
+fi
+
+if [ "$(id -u)" -ne 0 ]
+then
+  echo "You are not root." >&2
+  exit 1
+fi
+
+echo "Downloading portage tree..."
+mkdir -p /var/log /usr/portage &&
+cd /usr &&
+#wget http://127.0.0.1/aboriginal/mirror/portage-latest.tar.bz2 -O - | \
+wget http://gentoo.osuosl.org/snapshots/portage-latest.tar.bz2 -O - | \
+  tar xjC /usr
+if [ ! -d portage ]
+then
+  echo "Failed to download portage-latest tarball." >&2
+  exit 1
+fi
+
+if ! emerge.real --sync
+then
+  echo "Sync failed"
+  exit 1
+fi
+
+cd $(dirname $(readlink -f $(which emerge.real)))
+mv emerge.real emerge
+
+echo "Portage tree initialized"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/native-builds/gentoo-bootstrap/mnt/files/etc/portage/profile/package.provided	Thu Oct 07 23:52:23 2010 -0500
@@ -0,0 +1,43 @@
+# Base aboriginal system
+
+sys-devel/gcc-4.2.1
+sys-devel/binutils-2.17
+sys-devel/make-3.81
+sys-libs/uclibc-0.9.31
+sys-kernel/linux-headers-2.6.35
+sys-apps/busybox-1.17.2
+
+# Stuff busybox provides
+
+app-arch/gzip-1.0
+sys-apps/sed-1.0
+sys-apps/findutils-1.0
+sys-apps/diffutils-1.0
+app-editors/vim-1.0
+sys-apps/gawk-1.0
+app-arch/tar-1.0
+app-arch/bzip2-1.0
+app-arch/cpio-1.0
+sys-process/procps-1.0
+sys-apps/which-1.0
+sys-apps/net-tools-1.0
+sys-apps/sysvinit-1.0
+sys-apps/util-linux-1.0
+sys-apps/coreutils-1.0
+sys-apps/less-1.0
+sys-apps/grep-1.0      
+sys-apps/shadow-1.0    
+sys-apps/module-init-tools-1.0
+net-misc/wget-1.0
+app-arch/xz-utils-1.0
+
+# Upgrades for seed
+
+sys-apps/portage-2.1.8.3
+dev-lang/python-2.6.5
+sys-libs/zlib-1.2.5
+sys-libs/ncurses-5.7
+app-shells/bash-3.2
+net-misc/rsync-3.0.7
+sys-devel/patch-2.5.9
+sys-apps/file-5.03