Bug 30350

Summary: pkg_version output was "?" only
Product: Base System Reporter: NINOMIYA Hideyuki <NINOMIYA Hideyuki <nin>
Component: binAssignee: Bruce A. Mah <bmah>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description NINOMIYA Hideyuki <NINOMIYA Hideyuki 2001-09-05 19:30:00 UTC
When ports tree was not in the default place.
pkg_version does not work normally.
$ pkg_version /foo/bar/ports/INDEX
Output is
ImageMagick    ?
........       ?
It seems to become the above.
This is because pkg_version does not refer to environmenti
variable ${PORTSDIR}.

Fix: pkg_version gets possible to refer to ${PORTSDIR} with this patch
and comes to turn over a right result even if I move with ports tree
from the place of default.
Furthermore, if INDEX is ${PORTSDIR}/INDEX, I do not need to give it
as command line option.

How-To-Repeat: $ mv /usr/ports /foo/bar/ports
$ setenv PORTSDIR /foo/bar/ports
$ pkg_version /foo/bar/ports/INDEX
Comment 1 Akinori MUSHA freebsd_committer freebsd_triage 2001-09-05 19:53:51 UTC
Responsible Changed
From-To: freebsd-bugs->bmah

Over to maintainer.
Comment 2 Bruce A. Mah freebsd_committer freebsd_triage 2001-09-18 18:56:54 UTC
State Changed
From-To: open->analyzed

Committed to -CURRENT, thanks!  I will merge this to 4-STABLE and close 
the PR in a few days.
Comment 3 Bruce A. Mah freebsd_committer freebsd_triage 2001-09-24 19:09:54 UTC
State Changed
From-To: analyzed->closed

I committed this to 4-STABLE but forgot to close the PR.  Thanks!