mpab: add a progress log that just shows which ports have been built and their status

git-svn-id: https://svn.macports.org/repository/macports/contrib/mpab@81516 d073be05-634f-4543-b044-5fe20cf6d1d6
This commit is contained in:
Joshua Root
2011-08-01 03:43:03 +00:00
parent 8dea8c2e48
commit 682c19cb79
2 changed files with 9 additions and 4 deletions
+5 -4
View File
@@ -62,6 +62,7 @@ function cleanBuildStuff()
cleanBuildStuff
PORTRESULTSDIR="/var/tmp/portresults"
PROGRESSLOG="/var/tmp/progress.log"
rm -rf ${PORTRESULTSDIR}
/bin/mkdir -p ${PORTRESULTSDIR}/success ${PORTRESULTSDIR}/fail
@@ -90,7 +91,7 @@ currentCount=1
for portName in ${portList}; do
trap "echo \"Canceled, cleaning up...\"; cleanBuildStuff" EXIT
echo "Building ${portName} (${currentCount} of ${portCount})...\c"
echo "Building ${portName} (${currentCount} of ${portCount})...\c" | tee -a ${PROGRESSLOG}
# If there's a package, don't build again
portVersion=`${PREFIX}/bin/port info --version --line ${portName}`
portRevision=`${PREFIX}/bin/port info --revision --line ${portName}`
@@ -111,10 +112,10 @@ for portName in ${portList}; do
${PREFIX}/bin/port -dv install $portName | tee ${PORTRESULTSDIR}/${portName}.log 2>&1
if [[ ${PIPESTATUS[0]} == 0 ]]; then
/bin/mv ${PORTRESULTSDIR}/${portName}.log ${PORTRESULTSDIR}/success
echo "success"
echo "success" | tee -a ${PROGRESSLOG}
else
/bin/mv ${PORTRESULTSDIR}/${portName}.log ${PORTRESULTSDIR}/fail
echo "failure"
echo "failure" | tee -a ${PROGRESSLOG}
${PREFIX}/bin/port clean --work $portName
fi
uninstallPorts
@@ -123,7 +124,7 @@ for portName in ${portList}; do
exit 2
fi
else
echo "skipping, ${skipPort} previously failed and is needed"
echo "skipping, ${skipPort} previously failed and is needed" | tee -a ${PROGRESSLOG}
echo "${portName} not built due to failed dependency ${skipPort}" > ${PORTRESULTSDIR}/fail/${portName}.log
fi
#fi