Subject: pkg/16145: minor pkg_chk problems on zoularis
To: None <gnats-bugs@gnats.netbsd.org>
From: None <dbj@netbsd.org>
List: netbsd-bugs
Date: 03/31/2002 14:40:00
>Number: 16145
>Category: pkg
>Synopsis: pkg_chk problems on zoularis
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sun Mar 31 11:43:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: Darrin B. Jewell
>Release: -current updated via cvs ~20020330T1932Z
>Organization:
>Environment:
System: SunOS marcela.zlz.net 5.8 Generic_108528-13 sun4u sparc SUNW,UltraAX-i2
>Description:
The pkg_chk utility from ${PKGSRCDIR}/pkgtools/pkgchk has some
minor problems on Zoularis. Specifically:
. It should use the PKG_INFO, PKG_ADD, PKG_DELETE make variables
instead of invoking those utilities directly. Under zoularis
these are much less likely to be in the path.
. It doesn't work with solaris nawk. Presumably it assumes a
feature provided by gawk, which is default on NetBSD.
. Although it explicitly adds /usr/sbin to the PATH, it doesn't
add /usr/bin to the path. It uses getopt from the PATH, which
can be found in /usr/bin on both solaris and netbsd.
>How-To-Repeat:
# PATH="" /usr/pkg/sbin/pkg_chk -uan
/usr/pkg/sbin/pkg_chk: getopt: not found
# PATH=/usr/bin /usr/pkg/sbin/pkg_chk -uan
/usr/pkg/sbin/pkg_chk: pkg_info: not found
[ Update...]
[ Install...]
# PATH=/usr/bin:/usr/pkg/bsd/bin /usr/pkg/sbin/pkg_chk -uan
/usr/bin/nawk: newline in string devel/gtex... at source line 1
/usr/bin/nawk: newline in string devel/gtex... at source line 1
/usr/bin/nawk: newline in string devel/gtex... at source line 1
# PATH=/usr/bin:/usr/pkg/bsd/bin AWK=/usr/pkg/bin/gawk /usr/pkg/sbin/pkg_chk -uan
[ Update...]
[ Install...]
# PATH=/usr/bin:/usr/pkg/bsd/bin sh -x /usr/pkg/sbin/pkg_chk -uan
PATH=/usr/sbin:/usr/bin:/usr/pkg/bsd/bin
+ getopt BC:D:U:abcfhiknrsuv -uan
args=-u -a -n --
+ [ 0 != 0 ]
+ set -- -u -a -n --
+ [ 4 != 0 ]
opt_u=1
opt_i=1
+ shift
+ [ 3 != 0 ]
opt_a=1
opt_c=1
+ shift
+ [ 2 != 0 ]
opt_n=1
+ shift
+ [ 1 != 0 ]
+ break
+ [ -z -a -z ]
opt_b=1
opt_s=1
+ [ -z 1 -a -z 1 -a -z 1 ]
+ [ -n -o 1 != 1 ]
+ test -n
MAKE=/usr/pkg/bsd/bin/bmake
+ echo testing\c
+ echo 1,2,3
+ grep c
ac_t= ac_c=\c ac_n=
+ extract_variables
+ [ -z ]
+ [ -f /etc/mk.conf ]
+ printf BSD_PKG_MK=1\nx:\n\t@echo PKGSRCDIR=${PKGSRCDIR}\n
+ /usr/pkg/bsd/bin/bmake -f - -f /etc/mk.conf x
+ eval PKGSRCDIR=/export/spare/dist/anoncvs.netbsd.org/pkgsrc
PKGSRCDIR=/export/spare/dist/anoncvs.netbsd.org/pkgsrc
+ [ -z /export/spare/dist/anoncvs.netbsd.org/pkgsrc ]
+ [ ! -d /export/spare/dist/anoncvs.netbsd.org/pkgsrc ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgtools/pkgchk
+ extract_make_vars AWK GREP SED PACKAGES PKGCHK_CONF PKGCHK_TAGS PKGCHK_NOTAGS
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n\t@echo SED=${SED}\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n\t@echo SED=${SED}\n\t@echo PACKAGES=${PACKAGES}\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n\t@echo SED=${SED}\n\t@echo PACKAGES=${PACKAGES}\n\t@echo PKGCHK_CONF=${PKGCHK_CONF}\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n\t@echo SED=${SED}\n\t@echo PACKAGES=${PACKAGES}\n\t@echo PKGCHK_CONF=${PKGCHK_CONF}\n\t@echo PKGCHK_TAGS=${PKGCHK_TAGS}\n
MAKEDATA=x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n\t@echo SED=${SED}\n\t@echo PACKAGES=${PACKAGES}\n\t@echo PKGCHK_CONF=${PKGCHK_CONF}\n\t@echo PKGCHK_TAGS=${PKGCHK_TAGS}\n\t@echo PKGCHK_NOTAGS=${PKGCHK_NOTAGS}\n
+ printf x:\n\t@echo AWK=${AWK}\n\t@echo GREP=${GREP}\n\t@echo SED=${SED}\n\t@echo PACKAGES=${PACKAGES}\n\t@echo PKGCHK_CONF=${PKGCHK_CONF}\n\t@echo PKGCHK_TAGS=${PKGCHK_TAGS}\n\t@echo PKGCHK_NOTAGS=${PKGCHK_NOTAGS}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval AWK=/usr/bin/nawk GREP=/usr/bin/grep SED=/usr/xpg4/bin/sed PACKAGES=/export/spare/dist/anoncvs.netbsd.org/pkgsrc/packages PKGCHK_CONF= PKGCHK_TAGS= PKGCHK_NOTAGS=
PKGCHK_NOTAGS= PKGCHK_TAGS= PKGCHK_CONF= PACKAGES=/export/spare/dist/anoncvs.netbsd.org/pkgsrc/packages SED=/usr/xpg4/bin/sed GREP=/usr/bin/grep AWK=/usr/bin/nawk
+ [ -z /export/spare/dist/anoncvs.netbsd.org/pkgsrc/packages ]
+ [ -z ]
PKGCHK_CONF=/export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgchk.conf
+ [ -n ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc
+ pwd
real_pkgsrcdir=/export/spare/dist/anoncvs.netbsd.org/pkgsrc
+ [ -n 1 ]
+ pkg_info -B *
+ /usr/bin/nawk /PKGPATH= /{print $2}
PKGDIRLIST=devel/gtexinfo
devel/cvs
lang/gcc
pkgtools/pkgchk
pkgtools/digest
lang/gawk
devel/libtool-base
security/tcp_wrappers
lang/perl5
devel/zlib
security/ssh
+ [ -n 1 ]
+ [ ! -r /export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgchk.conf ]
+ hostname
+ sed -e s,\..*,,
+ uname -srm
+ /usr/bin/nawk {print $1"-"$2"-"$3","$1"-"$2","$1"-"$3","$1","$2","$3}
TAGS=marcela,SunOS-5.8-sun4u,SunOS-5.8,SunOS-sun4u,SunOS,5.8,sun4u
+ [ -f /usr/X11R6/lib/libX11.so -o -f /usr/X11R6/lib/libX11.a ]
+ [ -n ]
+ [ -n ]
+ [ -n ]
+ [ -n ]
+ /usr/bin/nawk -v alreadyset=devel/gtexinfo
devel/cvs
lang/gcc
pkgtools/pkgchk
pkgtools/digest
lang/gawk
devel/libtool-base
security/tcp_wrappers
lang/perl5
devel/zlib
security/ssh -v setlist=marcela,SunOS-5.8-sun4u,SunOS-5.8,SunOS-sun4u,SunOS,5.8,sun4u -v unsetlist=
BEGIN {
split(alreadyset, tmp, " ");
for (tag in tmp) { skip[tmp[tag]] = 1; }
split(setlist, tmp, ",");
for (tag in tmp) { taglist[tmp[tag]] = 1; }
split(unsetlist, tmp, ",");
for (tag in tmp) { skip[tmp[tag]] = 1; delete taglist[tmp[tag]] }
taglist["*"] = "*"
}
function and_expr_with_dict(expr, dict, ary, i, r) {
split(expr,ary,/\+/);
r = 1;
for (i in ary)
if (! (ary[i] in dict))
{ r = 0; break ;}
return r;
}
{
sub("#.*", "");
if (skip[$1])
{ next; }
need = 0;
for (f = 1 ; f<=NF ; ++f) { # For each word on the line
if (sub("^-", "", $f)) { # If it begins with a -
if ($f ~ /\+/) { # If it is a ANDed tag expression
if (and_expr_with_dict($f, taglist))
next; # If it is true, discard
} else { # If it is a simple tag
if ($f in taglist) # If match, discard
next;
}
} else {
if ($f ~ /\+/) { # If it is a ANDed tag expression
if (and_expr_with_dict($f, taglist))
need = 1; # If it is true, note needed
} else { # If it is a simple tag
if ($f in taglist) # If match, note needed
need = 1;
}
}
}
if (NF == 1 || need)
{ print $1 }
}
/usr/bin/nawk: newline in string devel/gtex... at source line 1
/usr/bin/nawk: newline in string devel/gtex... at source line 1
/usr/bin/nawk: newline in string devel/gtex... at source line 1
PKGDIRLIST=devel/gtexinfo
devel/cvs
lang/gcc
pkgtools/pkgchk
pkgtools/digest
lang/gawk
devel/libtool-base
security/tcp_wrappers
lang/perl5
devel/zlib
security/ssh
+ check_packages_installed devel/gtexinfo devel/cvs lang/gcc pkgtools/pkgchk pkgtools/digest lang/gawk devel/libtool-base security/tcp_wrappers lang/perl5 devel/zlib security/ssh
UPDATE_TODO=
MISSING_TODO=
MISMATCH_TODO=
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/gtexinfo/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/gtexinfo
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=gtexinfo-4.0
PKGNAME=gtexinfo-4.0
+ [ -z gtexinfo-4.0 ]
+ [ ! -d /var/db/pkg/gtexinfo-4.0 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/cvs/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/cvs
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=cvs-1.11nb2
PKGNAME=cvs-1.11nb2
+ [ -z cvs-1.11nb2 ]
+ [ ! -d /var/db/pkg/cvs-1.11nb2 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/lang/gcc/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/lang/gcc
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=gcc-2.95.3
PKGNAME=gcc-2.95.3
+ [ -z gcc-2.95.3 ]
+ [ ! -d /var/db/pkg/gcc-2.95.3 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgtools/pkgchk/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgtools/pkgchk
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=pkgchk-1.27
PKGNAME=pkgchk-1.27
+ [ -z pkgchk-1.27 ]
+ [ ! -d /var/db/pkg/pkgchk-1.27 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgtools/digest/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/pkgtools/digest
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=digest-20010807
PKGNAME=digest-20010807
+ [ -z digest-20010807 ]
+ [ ! -d /var/db/pkg/digest-20010807 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/lang/gawk/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/lang/gawk
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=gawk-3.0.4
PKGNAME=gawk-3.0.4
+ [ -z gawk-3.0.4 ]
+ [ ! -d /var/db/pkg/gawk-3.0.4 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/libtool-base/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/libtool-base
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=libtool-base-1.4.20010614nb8
PKGNAME=libtool-base-1.4.20010614nb8
+ [ -z libtool-base-1.4.20010614nb8 ]
+ [ ! -d /var/db/pkg/libtool-base-1.4.20010614nb8 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/security/tcp_wrappers/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/security/tcp_wrappers
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=tcp_wrappers-7.6.1nb1
PKGNAME=tcp_wrappers-7.6.1nb1
+ [ -z tcp_wrappers-7.6.1nb1 ]
+ [ ! -d /var/db/pkg/tcp_wrappers-7.6.1nb1 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/lang/perl5/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/lang/perl5
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=perl-5.6.1nb7
PKGNAME=perl-5.6.1nb7
+ [ -z perl-5.6.1nb7 ]
+ [ ! -d /var/db/pkg/perl-5.6.1nb7 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/zlib/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/devel/zlib
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=zlib-1.1.4
PKGNAME=zlib-1.1.4
+ [ -z zlib-1.1.4 ]
+ [ ! -d /var/db/pkg/zlib-1.1.4 ]
+ [ -n ]
+ [ -n ]
+ [ ! -f /export/spare/dist/anoncvs.netbsd.org/pkgsrc/security/ssh/Makefile ]
+ cd /export/spare/dist/anoncvs.netbsd.org/pkgsrc/security/ssh
+ [ -n ]
+ extract_make_vars PKGNAME
MAKEDATA=x:\n
MAKEDATA=x:\n\t@echo PKGNAME=${PKGNAME}\n
+ printf x:\n\t@echo PKGNAME=${PKGNAME}\n
+ /usr/pkg/bsd/bin/bmake -f - -f Makefile x
+ eval PKGNAME=ssh-1.2.27nb2
PKGNAME=ssh-1.2.27nb2
+ [ -z ssh-1.2.27nb2 ]
+ [ ! -d /var/db/pkg/ssh-1.2.27nb2 ]
+ [ -n ]
+ [ -n ]
+ [ -n -a -n ]
+ [ -n ]
+ [ -n ]
+ [ -n 1 ]
+ pkg_installlist Update
INSTALL=Update
+ shift
+ echo [ Update...]
[ Update...]
+ [ 0 != 0 ]
+ [ -n 1 ]
+ pkg_installlist Install
INSTALL=Install
+ shift
+ echo [ Install...]
[ Install...]
+ [ 0 != 0 ]
+ [ -n ]
+ [ -n ]
+ [ -n ]
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: