NetBSD Problem Report #31153

From  Mon Sep  5 03:06:19 2005
Return-Path: <>
Received: by (Postfix, from userid 31301)
	id 8A8DB63B84E; Mon,  5 Sep 2005 03:06:19 +0000 (UTC)
Message-Id: <>
Date: Mon,  5 Sep 2005 03:06:19 +0000 (UTC)
Subject: mk/scripts/mkreadme needs to handle large file lists more intelligently
X-Send-Pr-Version: www-1.0

>Number:         31153
>Category:       pkg
>Synopsis:       mk/scripts/mkreadme needs to handle large file lists more intelligently
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    asau
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Sep 05 03:07:00 +0000 2005
>Last-Modified:  Mon Nov 02 14:08:48 +0000 2009
>Originator:     Stuart Shelton
>Release:        n/a
IRIX64 octane 6.5 07010238 IP30 mips: IRIX 6.5.28
mk/scripts/mkreadme appears to have a couple of problems:

* It ignores an environment or mk.conf setting for $AWK
* In a couple of places it does "grep */*"-type operations, which fail with a "arg list too long" error.

The latter can be easily fixed by using ${FIND} or "for" to break up the list of files into manageable chunks.

As a suggestion for an enhancement, wouldn't it be a good idea to check for the current number of command-line arguments allowed to try to identify OS/installations likely to hit problems?  On IRIX this is "getconf ARG_MAX" - which outputs the number of allowed arguments without and additional characters or spaces.
bmake readme

I'd propose something similar to altering line 422 to read:

cat /dev/null > $ipv6
for FILE in */*/Makefile */*/; do
    ${GREP} -l -e '^BUILD_DEFS.*=.*USE_INET6' -e '^PKG_SUPPORTED_OPTIONS.*=.*inet6' $FILE | ${SED} -e 's;Makefile;;g' -e 's;;;g' >> $ipv6

... and changing lines 451-452 to:

    for d in `${FIND} -type d -maxdepth 2` ; do
        if [ ! -f ${d}/Makefile -a -f ${d}/README.html ]; then



Responsible-Changed-From-To: pkg-manager->asau
Responsible-Changed-When: Mon, 02 Nov 2009 14:08:48 +0000
I'll have a look.


NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD:,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.