diff options
author | 2011-12-18 20:34:36 +0000 | |
---|---|---|
committer | 2011-12-18 20:34:36 +0000 | |
commit | 2c2d3e47f39997341baba9445a6af43f15408a2f (patch) | |
tree | d31c699fca5932658cce20119df700ba38e7bfa3 /make-tarball.sh | |
parent | refactor qlist code so qmerge can call it directly rather than the top-level ... (diff) | |
download | portage-utils-2c2d3e47f39997341baba9445a6af43f15408a2f.tar.gz portage-utils-2c2d3e47f39997341baba9445a6af43f15408a2f.tar.bz2 portage-utils-2c2d3e47f39997341baba9445a6af43f15408a2f.zip |
include a final summary once tests have passed
Diffstat (limited to 'make-tarball.sh')
-rwxr-xr-x | make-tarball.sh | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/make-tarball.sh b/make-tarball.sh index f6495bd..92f6f32 100755 --- a/make-tarball.sh +++ b/make-tarball.sh @@ -2,12 +2,17 @@ set -e +if ! . /etc/init.d/functions.sh 2>/dev/null ; then + einfo() { echo " * $*"; } + eerror() { echo " * $*" 1>&2; } +fi + v() { printf '\t%s\n' "$*"; "$@"; } : ${MAKE:=make} if [[ $# -ne 1 ]] ; then - echo "Usage: $0 <ver>" 1>&2 + eerror "Usage: $0 <ver>" 1>&2 exit 1 fi @@ -18,25 +23,25 @@ p="portage-utils-$ver" rm -rf "${p}" mkdir "${p}" -echo "Checking out clean cvs sources ..." +einfo "Checking out clean cvs sources ..." cp -a CVS "${p}"/ cd "${p}" v cvs -Q up -echo "Building autotools ..." +einfo "Building autotools ..." sed -i "/^AC_INIT/s:cvs:${ver}:" configure.ac sed -i "1iPV := ${ver}" Makefile LC_ALL=C ${MAKE} -s autotools >/dev/null rm -rf autom4te.cache cd .. -echo "Generating tarball ..." +einfo "Generating tarball ..." find "${p}" -type d -name CVS -prune -print0 | xargs -0 rm -rf tar cf - "${p}" | xz > "${p}".tar.xz rm -r "${p}" du -b "${p}".tar.* -echo "Checking tarball (simple) ..." +einfo "Checking tarball (simple) ..." tar xf "${p}".tar.* pushd "${p}" >/dev/null v ${MAKE} -s @@ -44,7 +49,7 @@ v ${MAKE} -s check popd >/dev/null rm -rf "${p}" -echo "Checking tarball (autotools) ..." +einfo "Checking tarball (autotools) ..." tar xf "${p}".tar.* pushd "${p}" >/dev/null v ./configure -q @@ -53,4 +58,8 @@ v ${MAKE} -s check popd >/dev/null rm -rf "${p}" +echo +einfo "All ready for distribution!" +du -b "${p}".tar.* + exit 0 |