head 1.11; access; symbols RELEASE_7_4_0:1.10 RELEASE_8_2_0:1.10 RELEASE_6_EOL:1.9 RELEASE_8_1_0:1.9 RELEASE_7_3_0:1.8 RELEASE_8_0_0:1.8 RELEASE_7_2_0:1.8 RELEASE_7_1_0:1.8 RELEASE_6_4_0:1.8 RELEASE_5_EOL:1.7 RELEASE_7_0_0:1.7 RELEASE_6_3_0:1.7 PRE_XORG_7:1.7 RELEASE_4_EOL:1.7 RELEASE_6_2_0:1.7 RELEASE_6_1_0:1.7 RELEASE_5_5_0:1.7 RELEASE_6_0_0:1.6 RELEASE_5_4_0:1.6 RELEASE_4_11_0:1.6 RELEASE_5_3_0:1.5 RELEASE_4_10_0:1.4 RELEASE_5_2_1:1.3 RELEASE_5_2_0:1.3 RELEASE_4_9_0:1.1 RELEASE_5_1_0:1.1 RELEASE_4_8_0:1.1; locks; strict; comment @# @; 1.11 date 2011.04.24.16.37.51; author flz; state dead; branches; next 1.10; 1.10 date 2011.02.05.16.42.00; author erwin; state Exp; branches; next 1.9; 1.9 date 2010.06.25.23.31.11; author linimon; state Exp; branches; next 1.8; 1.8 date 2008.07.26.14.02.55; author kris; state Exp; branches; next 1.7; 1.7 date 2005.12.11.04.35.04; author kris; state Exp; branches; next 1.6; 1.6 date 2004.10.25.04.31.14; author kris; state Exp; branches; next 1.5; 1.5 date 2004.07.14.10.41.03; author kris; state Exp; branches; next 1.4; 1.4 date 2004.01.19.22.30.53; author marcus; state Exp; branches; next 1.3; 1.3 date 2003.10.13.06.33.04; author kris; state Exp; branches; next 1.2; 1.2 date 2003.10.13.02.54.56; author kris; state Exp; branches; next 1.1; 1.1 date 2003.01.24.05.03.08; author kris; state Exp; branches; next ; desc @@ 1.11 log @Remove portbuild scripts from pcvs, as they now live in svn/projects. @ text @#!/bin/sh # # processfail arch=$1 branch=$2 pb=/var/portbuild . ${pb}/conf/server.conf ERRORLOGS_DIRECTORY="${WWW_DIRECTORY}/errorlogs" of=${ERRORLOGS_DIRECTORY}/.${arch}-${branch}-failure.html cd ${pb}/${arch}/${branch} if [ -e .newfailure.stamp -a $(echo $(find . -maxdepth 1 -newer .newfailure.stamp -name newfailure 2>&1 /dev/null | wc -l)) = "0" ]; then exit; fi touch .newfailure.stamp newfailure=${pb}/${arch}/${branch}/newfailure num=0 if [ -e ${newfailure} ]; then num=$(wc -l ${newfailure} | awk '{print $1}') fi header() { echo "New package building errors" >$of echo "

New package building errors

" >>$of if [ "$num" -eq "0" ]; then echo "No errors (yet)" >>$of else echo "" >>$of echo "$1" >>$of fi } footer() { echo "
" >>$of echo "" >>$of echo "" >>$of } # # Create "default" output, sorted on portname # header "PortBuild logFirst brokenLast tried# tries" dirname() { echo ${1%/*} } basename() { echo ${1##*/} } sort -r -n -k 4 -t \| failure > newfailure IFS='|' while read dir name ver date last count; do echo "" >> $of echo "$dir" >> $of if [ -L ${pb}/${arch}/${branch}/latest/${dir} ]; then err=$(readlink ${pb}/${arch}/${branch}/latest/${dir}) echo "$ver" >> $of else echo "$ver" >> $of fi # echo "$affby$4 Kb" >> $of # echo "$5" >> $of # echo "$6" >> $of # echo "" >> $of alphadate=$(date -jf %s ${date} "+%F %T") alphalast=$(date -jf %s ${last} "+%F %T") echo "${alphadate}" >> $of echo "${alphalast}" >> $of echo "$count" >> $of echo "" >> $of done < newfailure footer "" mv -f $of ${ERRORLOGS_DIRECTORY}/${arch}-${branch}-failure.html @ 1.10 log @Make table headers more selfexplanatory Submitted by: gerald Feature safe: yes @ text @@ 1.9 log @Generalize the packge building scripts to be able to be run on more than one 'head' node, rather than just pointyhat itself. Constants are factored out into installation-specific files known as portbuild/conf/server.conf and portbuild/conf/client.conf. There is only one server.conf file. Individual directories may have their own client.conf files, or may symlink to ../conf/client.conf. While here, fix error messages displayed on new runs. Feature safe: yes @ text @d47 1 a47 1 header "PortPackageBrokenLast#" @ 1.8 log @* Implement basename and dirname using shell builtins @ text @d9 1 d11 2 a12 1 of=/usr/local/www/data/errorlogs/.${arch}-${branch}-failure.html d21 4 a24 1 num=$(wc -l ${newfailure} | awk '{print $1}') d83 1 a83 1 mv -f $of /usr/local/www/data/errorlogs/${arch}-${branch}-failure.html @ 1.7 log @Don't use a lockfile, the script will be called with lockf -t0 instead to avoid problems with stale lockfiles after reboots. @ text @d44 8 @ 1.6 log @If the symlink under latest/ exists, then use that to find the most recent error log for the port, instead of assuming it exists in the current build. @ text @a13 4 find $of .failure.html.lock -mmin +60 -delete 2>/dev/null if [ -f $of -o -f .failure.html.lock ]; then exit; fi a16 1 touch .failure.html.lock a69 1 rm .failure.html.lock @ 1.5 log @Back out the attempt to list the error type in the failure summary; because this file is a chronological history of port builds that have failed, the files listed may not be present in the current set of error logs, and we currently have no easy way to find the most recent failure log to use instead. @ text @d54 6 a59 1 echo "$ver" >> $of @ 1.4 log @* Refactor processlogs so that new error types can be added easily to a new processonelog script, that contains all the per-errorlog logic [1] * Add new error checks, one for detecting CPU problems, and the other for checking for broken libgnugetopt support [2] * Add a new "munmap" error type to check for broken bindists * Add imake and pthread detection to processonelog [3] * Add errortype column to the bento "New Build Failures" report [4] PR: 50258 56859 [1] 54406 [2] 57067 [3] 59272 [4] Submitted by: linimon [1] [2] [3] [4] @ text @a7 3 scriptdir=$(dirname $0) errorscript=${scriptdir}/processonelog a43 6 geterrortype() { set $(echo `${errorscript} $logfile ./ports` | tr \| " ") reason=$(echo $7 | tr '_' ' ') echo "$reason" } d47 1 a47 1 header "PortPackageErrorBrokenLast#" a59 4 logfile=${ver}.log errortype=`geterrortype` echo "$errortype" >> $of @ 1.3 log @Condense the table a bit @ text @d8 3 d47 6 d56 1 a56 1 header "PortPackageBrokenLast#" d69 4 @ 1.2 log @* Generate newfailure file (sorted list by original failure date) from failure * Enhance HTML output to include both original and latest failure date, and number of times the build has failed. @ text @d47 1 a47 1 header "PortPackageBrokenLastCount" d61 2 a62 2 alphadate=$(date -jf %s ${date}) alphalast=$(date -jf %s ${last}) @ 1.1 log @First cut at a script to process the logfile maintained by 'buildsuccess' and 'buildfailure' and produce a HTML output listing ports with the date they became broken. The output can surely be made more useful (e.g. it always links to the ${branch}-latest logs, which may not exist when the build-in-progress has not yet attempted the build of that port). @ text @d24 1 a24 1 num=$(wc -l ${newfailure}) d47 1 a47 4 header "PortPackageDate broken" for i in `cat ${newfailure}`; do set $(echo $i | tr ' ' '_' | tr \| " ") d49 3 d53 2 a54 2 echo "$1" >> $of echo "$3" >> $of d61 5 a65 2 date=$(echo $4 | tr '_' ' ') echo "${date}" >> $of d68 1 a68 1 done @