diff options
author | Peter Gavin <pete@gentoo.org> | 2001-08-08 20:37:43 +0000 |
---|---|---|
committer | Peter Gavin <pete@gentoo.org> | 2001-08-08 20:37:43 +0000 |
commit | 2f26e5cf9b8cb2c9b39c939e43dea7ffe317f288 (patch) | |
tree | 1a2e2288b36c26ce0e52a14e90dbd5405153491d /scripts | |
parent | web, digest updates (diff) | |
download | gentoo-2-2f26e5cf9b8cb2c9b39c939e43dea7ffe317f288.tar.gz gentoo-2-2f26e5cf9b8cb2c9b39c939e43dea7ffe317f288.tar.bz2 gentoo-2-2f26e5cf9b8cb2c9b39c939e43dea7ffe317f288.zip |
*** empty log message ***
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/autosysimg.sh | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/scripts/autosysimg.sh b/scripts/autosysimg.sh new file mode 100644 index 000000000000..fcf46836b931 --- /dev/null +++ b/scripts/autosysimg.sh @@ -0,0 +1,31 @@ +#!/bin/bash + +export USE=build +export CFLAGS="-O2 -mcpu=i486 -march=i486 -O2 -pipe" +export CXXFLAGS="${CFLAGS}" +export CHOST="i486-pc-linux-gnu" +export ROOT=/tmp/autobuildimg +export STEPS="clean unpack compile install qmerge clean" + +TODAY=`date '+%Y%m%d'` + +[ -z "${PORTDIR}" ] && PORTDIR=/usr/portage +[ -z "${BUILDTARBALL}" ] && BUILDTARBALL="build-${TODAY}.tbz2" +[ -z "${BUILD_PACKAGES}" ] && BUILD_PACKAGES=`ls -1 ${PORTDIR}/files/build-*.packages | sort | tail -1` + +echo ">>> Cleaning up ${ROOT}..." +rm -rf "${ROOT}" +mkdir -p "${ROOT}" + +scripts/autocompile.sh "${BUILD_PACKAGES}" + +rm -rf "${ROOT}/tmp" +mkdir -p ${ROOT}/tmp +chown root.root ${ROOT}/tmp +chmod 1777 ${ROOT}/tmp + +echo ">>> Creating ${BUILDTARBALL}..." +cd ${ROOT} +tar -cj --numeric-owner -p -f "${PORTDIR}/distribution/${BUILDTARBALL}" . + +rm -rf ${ROOT} |