summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authoragc <agc@pkgsrc.org>2004-07-22 14:26:42 +0000
committeragc <agc@pkgsrc.org>2004-07-22 14:26:42 +0000
commit047727a34186d2934e066ee97504d2ed4d6c9071 (patch)
tree36171beb85c0479f9ad1e0c76eb45275b3e964b8 /mk
parentcbfa54886966e32c247f336656cc2c448af67cff (diff)
downloadpkgsrc-047727a34186d2934e066ee97504d2ed4d6c9071.tar.gz
Abstract out the "nice -n 20" clause, so that it can be set to something
else if desired. Print out dates in the form: yyyy/mm/dd
Diffstat (limited to 'mk')
-rw-r--r--mk/bulk/build11
-rw-r--r--mk/bulk/build.conf-example5
2 files changed, 12 insertions, 4 deletions
diff --git a/mk/bulk/build b/mk/bulk/build
index 9d555ca470e..149f9900069 100644
--- a/mk/bulk/build
+++ b/mk/bulk/build
@@ -1,5 +1,5 @@
#!/bin/sh
-# $NetBSD: build,v 1.40 2004/04/29 02:23:26 dmcmahill Exp $
+# $NetBSD: build,v 1.41 2004/07/22 14:26:42 agc Exp $
#
# Copyright (c) 1999, 2000 Hubert Feyrer <hubertf@NetBSD.org>
@@ -282,6 +282,11 @@ cd ${USR_PKGSRC}
# make sure we have something to grep in in the build loop
touch $BUILDLOG
+# set the nice level for bulk builds
+#case "${NICE_LEVEL}" in
+#"") NICE_LEVEL="nice -n 20" ;;
+#esac
+
# Loop over every package in the correct order. Before building
# each one, check to see if we've already processed this package
# before. This could happen if the build got interrupted and we
@@ -299,9 +304,9 @@ do
if [ $? -ne 0 ]; then
built=`wc -l $BUILDLOG | ${AWK} '{print $1}'`
percent=`echo $built $tot | ${AWK} '{printf("%4.1f%%",$1*100/$2);}'`
- (cd $pkgdir && nice -n 20 ${BMAKE} USE_BULK_CACHE=yes $target \
+ (cd $pkgdir && ${NICE_LEVEL} ${BMAKE} USE_BULK_CACHE=yes $target \
$makeargs </dev/null | \
- ${SED} "s;^;`date '+%m/%d/%y %H:%M:%S'` $built/${tot}=$percent $pkgdir @ ${MACHINE_ARCH}> ;g")
+ ${SED} "s;^;`date '+%Y/%m/%d %H:%M:%S'` $built/${tot}=$percent $pkgdir @ ${MACHINE_ARCH}> ;g")
echo "$pkgdir" >> $BUILDLOG
fi
done
diff --git a/mk/bulk/build.conf-example b/mk/bulk/build.conf-example
index d7de0a329ff..df451a6e70e 100644
--- a/mk/bulk/build.conf-example
+++ b/mk/bulk/build.conf-example
@@ -1,5 +1,5 @@
# build.conf
-# $NetBSD: build.conf-example,v 1.20 2004/04/19 18:39:09 hubertf Exp $
+# $NetBSD: build.conf-example,v 1.21 2004/07/22 14:26:42 agc Exp $
#
# config file in /bin/sh syntax for {,pre,post}-build
#
@@ -54,6 +54,9 @@ UPDATE_VULNERABILITY_LIST=yes
RSYNC_DST=$CVS_USER@ftp.NetBSD.org:/pub/NetBSD/packages/pkgsrc-200xQy/NetBSD-a.b.c/i386
RSYNC_OPTS='-e ssh'
+# Nice level for builds
+NICE_LEVEL=nice -n 20
+
###########################################################################
### No changes should be needed below this line !!!
###########################################################################