Release 23.12.0.
Require valid certs for https:// repositories.
New `-i' option to allow insecure transport.
Requires libfetch>=2.40.
Release 23.8.1.
Fix keep/unkeep regression in 23.8.0.
Changing pkg_keep() to accept a single argument broke running "keep" and
"unkeep" with multiple arguments. While here, fix the exit status so
that failures are now reported correctly.
Release 23.8.0.
Update CHECK_DB_LATEST to the latest pkgin.sql.
Order downloads alphabetically and print counters.
Plug various memory leaks.
Avoids globs in -[0-9]* patterns.
Fixes issue seen with e.g. postgresql9[01235-9]-[0-9]* where an
incorrect pkgbase was computed.
Use a Plistarray for conflicts handling.
Also add DISTINCT to the LOCAL_CONFLICTS query, reduces the number of
distinct CONFLICTS entries by around 50% on the test system. Overall,
improves performance of "pkgin -n upgrade" by around 20%.
Improve and fix record_supersedes().
Fix logic error with strcmp() checking that meant we were only ever
handling a maximum of one SUPERSEDES match, and use the optional PKGBASE
returned by the SQL query to speed up find_local_pkg() searching.
Implement hashed lookups for the majority of lists.
Add a new array type which is an array of SLISTs, and use them where we
will often look up packages by name. djb_hash() is used as the hashing
function for good distribution, and each type of hash has its own size
based on performance analysis on the test system.
Many parts of the depends and impact code needed altering to work with
this, and along the way a number of bugs were fixed, mainly around
partial installs where previously we did not correctly consider reverse
dependencies and what happens if they themselves are updated. Partial
upgrades now correctly recurse both ways for upgraded packages.
As well as fixing bugs, the main benefit of hashed lookups is
performance, and this commit speeds up "pkgin -n upgrade" by 10x on the
test system, and "pkgin -n install zlib" by 5x.
Improve performance of add_required_by().
This is the optimisation as described in my tech-pkg review request:
https://mail-index.netbsd.org/tech-pkg/2023/08/07/msg027952.html
where pkgdb iterations can be configured to be ignored after finding the
first valid match. Saves many unnecessary calls to pkg_order() and
improves performance by around 12x on my test system.
Gather up all conflicts before printing them.
Avoids the user having to type "y" for each of them just to see if there
are any other conflicts. While here tidy things up a bit and simplify.
Implement counters for downloads.
Add counter for removals too.
Various compiler warning fixes.
Plug a bunch of memory leaks.
Found using the macOS leaks(1) command running against the test suite.
Add pkgfs to Pkglist, path to downloaded file.
Saves a duplicate string in different places. While here ensure all
char Pkglist entries are freed.
Print a simple progress counter when installing.
Improve output messages when reducing disk usage.
Also go back to using defines for these messages, it's getting a little
messy.
Clean up ancilliary table handling.
Be consistent in how DEPENDS, CONFLICTS, etc are handled. Avoid magic
queries that force them to have the same column names, and instead
rename the columns so they make sense for each. Start using lowercase
column names for readability.
As an example the PROVIDES/REQUIRES tables now have a "filename" column
given they represent file paths, instead of e.g. REMOTE_REQUIRES_PKGNAME
which made no sense.
Ensure all relevant indexes are created, speeding up database queries.
New "switch-repo" test in the test suite verifies correct database
handling.
Remove more unused queries.
Remove DESCRIPTION column, unused.
Add some more database indexes.
Also stop using "dewey" for patterns, just call them patterns as they
have nothing to do with dewey decimals.
Implement initial SUPERSEDES support.
This is enough to get at least basic replacements working, for example
nodejs superseding npm, and also cleans up some of the remove path.
Remove unused "type" entry from struct Pkglist.
Give actions a proper type.
Sort output package lists alphabetically.
Should be the final issue raised in NetBSDfr/pkgin#17.
Avoid local database update messages on startup.
This can essentially corrupt some output such as "pkgin export" if
performed after a pkgdb update, as described in NetBSDfr/pkgin#97.
Output is retained for operations which themselves modify the pkgdb.