README.html generation are broken. It will not find vulnerabilities in any
packages that have complex names in the pkg-vulnerabilties file.
e.g. php{4,5}-perl and sun-{jdk,jre}15
Post pkg_install-20070714 this is now fixed and only currently known
vulnerabilities are shown in the generated README.html files for packages.
You will need to update to pkg_install>=20070714 to get this fix.
* Add the necessary changes to allow genreadme.awk to process the v1.1.0
format pkg-vulnerabilities file.
* Changes are fully backward compatable i.e. mkreadme should be able to
parse v1.0.0 and v1.1.0 format files.
As data for a given binary package is loaded, increment a count
stored with PKGPATH as the index. Then use a psuedo-multidimensional
array with PKGPATH and the # as the index. This allows for much
faster lookups and scales linearly with the number of packages.
The old way scaled as the product of the number of pkgsrc entries
and the total number of binary packages. Not a pretty value.
This makes the actual README.html generation part run about 3x faster.
Approach suggested by soda.
some of the older packages on ftp.netbsd.org. For example,
pkg_info -B ftp://ftp.netbsd.org/pub/NetBSD/packages/1.5.2/vax/All/cascade-1.4.tgz
will give
OPSYS= NetBSD
instead of
OPSYS=NetBSD
- completely redo the code which decides on the machine architecture,
operating system, and operating system version for the binary packages.
The old way just used to directory names to take a guess. The new
way creates a cache file containing meta-data for all the binary packages
in each "All" directory. This cache file is consulted when generating
the lists of available binary packages. The meta-data is obtained with
pkg_info so it should always be correct even if you do something silly
like mix OS_VERSION or MACHINE_ARCH packages up in the same directory.
Among the benefits are: works when PACKAGES is not $PKGSRC/packages,
works with a more or less arbitrary subdirectory structure, works
when there are subdirectories for multiple operating systems.
This portion of the fix should address PR25390.
The cache files are only updated when the contents of an "All" directory
changes or if the cache file format changes. There is some room for
improving the updating of the cache files, but its not too bad the way
it is.
- fix up some of the awk code so that generadme.awk works with Solaris
nawk as well as NetBSD's nawk and gawk (for pre-2.0 systems).
- remove some "if ! foo" shell constructs to increase portability.
- be more consistent with what variables get passed to mkreadme from
make and which ones are determined automatically. Mostly this meant
moving stuff into mkreadme to make it easier to run it standalone.
- fix a bug in which caused only packages listed as DEPENDS to show
up in the 'packages needed to build' section. Now the BUILD_DEPENDS
are also shown. Thanks to Christian Hattemer for noting this.
- fix a bug which caused error messages claiming that category and top
level README.html files could not be created even though they were
created. This bug only showed up if an old README.html file did not
exist. As part of this, clean up and unify the code which handles
comparing the new README.html file to a possibly pre-existing one and
only copying it over if there is a change.