diff options
author | tron <tron> | 2000-09-15 08:35:15 +0000 |
---|---|---|
committer | tron <tron> | 2000-09-15 08:35:15 +0000 |
commit | 18951687561294ad967b76e6ab19770e4e54b783 (patch) | |
tree | 0f98435f263b897eca04e822c9af8fc1c923f23a /mk | |
parent | e688e00026efdaadd0fd2e6432135d9e1f048fd1 (diff) | |
download | pkgsrc-18951687561294ad967b76e6ab19770e4e54b783.tar.gz |
Because "awk" keeps getting overflows on "arm32" while calculating the
size of a large package we use "dc" now.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/bsd.pkg.mk | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index dce7273568b..6f0f9b04d01 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.571 2000/09/14 11:27:56 tron Exp $ +# $NetBSD: bsd.pkg.mk,v 1.572 2000/09/15 08:35:15 tron Exp $ # # This file is in the public domain. # @@ -508,6 +508,7 @@ CHOWN?= /usr/bin/chown CHGRP?= /usr/bin/chgrp CP?= /usr/bin/cp CUT?= /usr/bin/cut +DC?= /usr/bin/dc ECHO?= /usr/ucb/echo EGREP?= /usr/xpg4/bin/egrep FALSE?= /usr/bin/false @@ -551,6 +552,7 @@ CHOWN?= /usr/sbin/chown CHGRP?= /usr/bin/chgrp CP?= /bin/cp CUT?= /bin/cut +DC?= /usr/bin/dc ECHO?= /bin/echo EGREP?= /bin/egrep FALSE?= /bin/false @@ -594,6 +596,7 @@ CHOWN?= /usr/sbin/chown CHGRP?= /usr/bin/chgrp CP?= /bin/cp CUT?= /usr/bin/cut +DC?= /usr/bin/dc ECHO?= echo # Shell builtin EGREP?= /usr/bin/egrep FALSE?= false # Shell builtin @@ -2854,9 +2857,10 @@ print-pkg-size-this: | sort -u \ | ${SED} -e 's, ,\\ ,g' \ | xargs ls -ld \ - | ${AWK} 'BEGIN { sum=0; } \ - { sum+=$$5; } \ - END { printf("%d\n", sum); }' + | ${AWK} 'BEGIN { print("0"); } \ + { print($$1, " +"); } \ + END { print("p"); }' \ + | ${DC} # Sizes of required pkgs (only) # @@ -2864,15 +2868,16 @@ print-pkg-size-this: # dependencies are all installed print-pkg-size-depends: @${MAKE} ${MAKEFLAGS} print-pkg-size-depends-help \ - | ${AWK} 'BEGIN { sum=0; } \ - { sum+=$$1; } \ - END { printf("%d\n", sum); }' + | ${AWK} 'BEGIN { print("0"); } \ + { print($$1, " +"); } \ + END { print("p"); }' \ + | ${DC} # need this in a make look to prevent the shell clobbering the depends # also includes size of depends of depends (XXX) print-pkg-size-depends-help: .for dep in ${DEPENDS} @pkg="${dep:C/:.*//}"; \ - ${PKG_INFO} -qS "$$pkg" + ${PKG_INFO} -qS "$$pkg" | ${HEAD} -1 .endfor |