Up to [cvs.NetBSD.org] / pkgsrc / pkgtools / pkg_install / files / lib
Request diff between arbitrary revisions
Keyword substitution: kv
Default branch: MAIN
pkg_install: fix null pointer dereference The pkg_add -m option crashes on null pointer dereference if the input has a slash but then no space. Patch by riastradh@ in PR pkg/59991.
pkg_install: fix bug in format string Addresses PR 59316 by Dr. Thomas Orgis Bump version.
pkg_install: allower overriding the 'required libraries' check with -f Bump version.
pkg_install: bump version for today's changes
pkg_add(8): Say `error', not `warning', if it's fatal. Break some overlong lines in the source code for these messages while here. PR pkg/58799: earm binary packages are actually compiled for earmv4, resulting in a fatal warning when adding packages
pkg_install: Update to 20241030. Fix the REQUIRES check to also work in destdir (pkg_add -P) mode.
pkgtools/pkg_install: Update to 20241025 * Accept epl-v2.0 by default.
pkg_install: update to 20240826 Fix previous: Only check REQUIRES after dependencies are installed. (My testing seems to only have happened for updates.)
pkg_install: check REQUIRES lines on installation Fail if any of the required libraries is missing; in particular, for files from the X set on NetBSD, suggest installing the X sets. Should fix PR 58433.
licenses/upl-1.0: Add Universal Permissive License (UPL) Version 1.0. FSF-approved: https://www.gnu.org/licenses/license-list.html#UPL This is a lax, permissive non-copyleft free software license, compatible with the GNU GPL. The license does provide the ability to license patents along with the software work, however, we still recommend the Apache 2.0 license for avoiding patent treachery when choosing to put your work under a lax license. OSI-approved: https://opensource.org/license/upl Text taken from: https://oss.oracle.com/licenses/upl/ Verified by wdiff(1) (wdiff-1.2.2nb1 from textproc/wdiff) to be identical, other than in the quotation marks, to: https://directory.fsf.org/wiki/License:UPL-1.0 https://opensource.org/license/upl No objection on tech-pkg: https://mail-index.netbsd.org/tech-pkg/2024/08/10/msg029762.html
pkg_install: Bump version to 20240307.
pkg_install: Fix mistake in previous: this is strchr, not strchrnul. Either if ((q = strchr(p, '/')) == NULL) or if (*(q = strchrnul(p, '/')) == '\0') will work, but not if (*(q = strchr(p, '/')) == '\0') which will crash with a null pointer dereference. Let's get the right version of this committed, not the wrong one! Oops. While here, reset PKGREVISION like I meant to do yesterday.
pkg_install-20240125: Extend `-m' syntax to allow OPSYS too.
- If there's no slash `/', take it all as ${MACHINE_ARCH}.
- If there is a slash, then split it by `/' and ` ' into:
${OPSYS}/${MACHINE_ARCH} ${OPSYS_VERSION}
For example:
NetBSD/aarch64 10.0
All the variables are restricted to lie in a safe set [a-zA-Z0-9._-],
so the notation can be extended later.
No change to existing syntax (no MACHINE_ARCH has `/' in it, or
anything outside the safe set), and `-m' is generally only used with
cross builds anyway, so this shouldn't break existing cross builds
and should have no impact on native builds.
Proposed on tech-pkg:
https://mail-index.netbsd.org/tech-pkg/2024/01/13/msg028825.html
pkg_install: Switch to posix_spawn() on newer macOS. vfork() no longer works on Monterey and causes serious intermittent issues when upgrading pkg_install. Forking the INSTALL and DEINSTALL scripts can sometimes fail, due to the underlying pkg_add/pkg_delete binaries having been changed or removed, leaving the system broken with no package tools. The manual page suggests using posix_spawn() instead and that appears to work correctly. The code has been laid out so that it's easy enough to switch other platforms to posix_spawn() too if required, or for improved performance, and has been verified to work successfully on SmartOS. Bump pkg_install version to 20211115.
pkg_install: Update to 20211021. Apply patch from Michal Maruska in NetBSD/pkgsrc#95 to ensure package files are correctly cleaned up should the POST-INSTALL script phase fail.
pkg_install-20210410: simplify checking for netbsd versions only care about the first number, unless it's -current
pkg_install-20210308 - update pkg_add's examples in its man page for 2021 compliance.
pkg_install-20201218 - Support continuing to install to /var/db/pkg if it exists and the new pkgdb doesn't. In the future, we can warn about this once we have tested advice that we can give to users who want to move the location of pkgdb. - Don't do anything about /var/db/pkg on non-NetBSD-base. This creates conflicts with other package managers that also install to /var/db/pkg.
pkg_install-20201212: handle error case better When pkg_delete fails, report it and error out.
pkg_install: Introduce support for CHECK_OS_VERSION. When set to "no", pkg_add will not issue a warning if the host OS version does not exactly match the OS version the package was built on. This can be useful on many OS where the kernel release version has nothing to do with userland compatibility, or where it may differ without being ABI incompatible. Ultimately it would be ideal if the version checks were smart enough across all our supported OS to not need this, but until then this is useful for users who know what they're doing. Bump version to 20201211.
pkg_install: update to 20201206 Convert a core dump I've been seeing into an error abort.
pkg_install: update to 20201205 Improve warning about old database to mention moving the refcount db too.
*: move default database directory from /var/db/pkg to ${PREFIX}/pkgdb
As discussed in August 2020 and previously on pkgsrcCon 2019.
Ok pkgsrc-pmc@
pkg_install: Update version to 20200701. Includes fixes to +REQUIRED_BY generation, performance improvements, build fixes against newer libnetpgpverify, and better error messages. When combined with newer pkgin releases, this should now eliminate the various "pkg_add: Can't open +CONTENTS of depending package ..." errors that users had frequently observed during upgrades (joyent/pkgsrc#158, joyent/pkgsrc#190, joyent/pkgsrc#256, and many IRC logs).
pkg_install-20191008: Add pkg_admin digest command
Bump date for switch to cdn.NetBSD.org
pkg_install-20180425: correctly detect package names in PKG_DBDIR If PKG_DBDIR is /foo and a path like /foobar is given, it is not below PKG_DBDIR, so don't translate it into a package name look up. The old logic for giving a path to PKG_DBDIR remains for legacy compat.
pkg_install: Update to 20180417. Fix an issue in pkg_create where we may have been using corrupted owner and group information. Noticed on macOS where libarchive would complain about the owner entry being too long. Reviewed by joerg. Also includes some manual page improvements committed recently.
Bump version for commits earlier this week. pkg_install-20180325 - pkg_add(1): Documentation fixes - pkg_delete: Add missing -A to usage()
pkg_install-20180226: - add option to include IGNORE_URL pkg_install.conf entries in audit but flagged as "ignored". - bump version to 20180226
pkg_install: Bump version to 20171030 for netpgpverify fixes.
pkg_install-20170419: - Convert to libarchive 3.x interfaces, avoiding the legacy glue. - Rename local copy of netpgpverify to match installed headers. - Shuffle bootstrap code to reduce special cases in pkg_add. - Always read/write file names in tar archives as binary. While they are supposed to be UTF-8, locale conversion creates more problems than it solves here. - Fix const correctness in gpg_verify. - Add format string annotation for xasprintf for GCC-like compilers. - Restrict supported archive formats for binary packages to ar (signed packages) and tar (actual content) with uncompressed/gzip/bzip2/xz as compression choices. This reduces the exposed libarchive surface. - The pkg-vulnerability file correspondingly supports only the same compression choices.
pkg_install-20160410: Remove pkgdb handling logic from pkg_create, where it should have never been in first place. Ignore former -U option as new default.
Implement inline package signature verification. This replaces calling out to an external gpg command for verification with inline verification using the security/netpgpverify library. Bump version to 20150901.
Pullup ticket #4709 - requested by agc pkgtools/pkg_install: bug fix update Revisions pulled up: - pkgtools/pkg_install/files/add/main.c 1.29 - pkgtools/pkg_install/files/lib/version.h 1.168 --- Module Name: pkgsrc Committed By: agc Date: Fri May 8 16:29:37 UTC 2015 Modified Files: pkgsrc/pkgtools/pkg_install/files/add: main.c pkgsrc/pkgtools/pkg_install/files/lib: version.h Log Message: Fix format string in pkg_add's help message - from J. Lewis Muir Bump version number for pkg_install to 20150508
Fix format string in pkg_add's help message - from J. Lewis Muir Bump version number for pkg_install to 20150508
Remove pkg_views support, second part: infrastructure.
pkg_install-20130902: Fix 'pkg_add -f'. Remove incorrect return value when in force mode, which was causing pkg_add to exit with failure even though the operation completed successfully. This also fixes the case where 'pkg_add -uf' would leave an update in an inconsistent state.
Shut up warnings about 6.0 packages on 6.0.1 (and similar). Welcome to 20130131.
Bump version for pkg_add bug fix.
pkg_install-20120128: - Explicitly stat(2) if mkdir failed. errno detection doesn't work e.g. on Solaris (PR 45289) - Provide a stable order for package names that only differe in the base name, not the version number.
Fix for pkg_delete on NFS from Anthony Mallet. Problem analysis from Anthony: On Wednesday, at 23:52, Anthony Mallet wrote: > # rm -rf ~tmp && mkdir ~/tmp > # pkg_add -K ~/tmp/var/db/pkg -p ~/tmp /usr/pkgsrc/packages/All/digest-20080510.tgz > # pkg_add -U -K ~/tmp/var/db/pkg -p ~/tmp /usr/pkgsrc/packages/All/digest-20080510.tgz > pkg_delete: Couldn't remove package directory in `/home/tho/tmp/var/db/pkg/digest-20080510' > Also, the dir var/db/pkg/digest-20080510.xxxxxxx is never cleaned. > > The problem apparently is that pkg_delete finds some stalled NFS entries > (.nfs*) in the var/db/pkg/digest-20080510 dir, so it does not delete the > directory. Is this due to pkg_add not correctly closing file descriptors before > exec'ing pkg_delete? For instance, I really don't understand the logic in > check_already_installed() (add/perform.c:375) regarding the open() of +CONTENTS > which is almost never closed (and never used as well...). Shouldn't this be > closed before running pkg_delete? ktrace shows that the +CONTENTS file is open() by pkg_add, I believe this is in check_already_installed(), add/perform.c:381. Then pkg_delete is run and when it comes to deleting the pkgdir entry, it finds that .nfs file and aborts. Bump version to 20110805
Pullup ticket 3356 - requested by aymeric functionality fix Revisions pulled up: - pkgsrc/pkgtools/pkg_install/files/admin/audit.c 1.17 - pkgsrc/pkgtools/pkg_install/files/lib/version.h 1.161 ----------------------------------------------------------------------------- Module Name: pkgsrc Committed By: aymeric Date: Fri Feb 18 15:59:52 UTC 2011 Modified Files: pkgsrc/pkgtools/pkg_install/files/admin: audit.c pkgsrc/pkgtools/pkg_install/files/lib: version.h Log Message: . fix audit-history subcommand to include patterns making use of [x-y] notation . bump version to 20110215 To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 pkgsrc/pkgtools/pkg_install/files/admin/audit.c cvs rdiff -u -r1.160 -r1.161 pkgsrc/pkgtools/pkg_install/files/lib/version.h
. fix audit-history subcommand to include patterns making use of [x-y] notation . bump version to 20110215
Don't warn about _ALPHA, _BETA, _PATCH, _RC, _STABLE mismatches when pkg_add'ing on NetBSD. Bump version to 20101212. Ok jym, gdt
pkg_install-20101122: Fix crash in pkg_info -X on hand-written packages
pkg_install-20100915: Allow https URLs. From mbalmer. Reset maintainership.
Add -D flag to pkg_install, to override the "pkg_add -U" check that all depending packages have their dependencies satisfied by the new package. Essentially, split off this particular behavior as a special case of -f, so that -f works as before, unforced works as before, and one can give -D to override exactly this check, leaving all other checks intact. The -D flag is in support of make replace, as the workflow for make replace is that inter-package dependencies are sometimes violated (but then one must replace the depending packages, which is what pkg_rolling-replace does via the unsafe_depends flags). Bump PKGTOOLS_VERSION. Add missing break statement in option parsing of "pkg_add -C", riding the version bump. Discussed extensively on tech-pkg@ over the summer. OK pkgsrc-pmc@.
pkg_install-20100616: - Recognize -C for pkg_add like the rest of the tools do - Do the existing check for pkg_add -f, it makes the combination of -f and -U a bit less surprising - Fix option handling for CHECK_VULNERABILITIES (from spz@) - Make end-of-life check the default. pkg_install.conf(5) can be used to override the default. The existing admin -e & co continue to work as before.
pkg_install-20100421: Fix an off-by-one in the check for properly sized pkgdb entries. It rejected perfectly valid entries.
pkg_install-20100420: Extract dependencies of libarchive from the pkgconfig file and thereby drop knowledge of the needed libraries. At least some versions of HP-UX are known to not support %zu, add a workaround. This is using the black list approach for now. Recognize xz as compression type for pkg_create. The first time an error is hit while fetching packages, try to reget from the same position. This works around the server closing the connection while fetching dependencies.
pkg_install-20100405: - Try to detect common forms of pkgdb corruption and issue a warning in that case. - Refactor the pkg_vulnerabilities logic to use the compression support from libarchive. This reduces the amount zlib/bzip2 interaction to the linkage.
Add man pages for audit-packages and download-vulnerability-list which point to pkg_admin and notes that the scripts are obsolete. Bump version to 20100319.
pkg_install-20100220: Try harder to give the user an idea which file failed. Addresses PR 42223.
pkg_install-20100204: Fix an enum to prevent crashes later (PR 42734)
pkg_install-20100203: - Restore PKG_PREFIX in pkg_delete (PR 42731) - Ensure that the current pkg_install version is at least as new as the version used to build the package
pkg_install-20100130: Add -U for pkg_add. It works similar to -u, but replaces an already installed version.
pkg_install-20100126: Actually support IPv6.
pkg_install-20100122:
- Refactor man pages:
- Move description of environmental variables into pkg_install.conf(5)
- Remove a bunch of dead references
- Avoid using hard-coded path names that can easily be overridden by
the user.
- Refactor pkgdb related logic, so that -K behaves consistently.
- Add some helper functions to isolate more places from the pkgdb
layout.
- Sync license list.
- Handle PKG_REFCOUNT_DBDIR consistently as option too.
- Utilize connection cache from libfetch.
- Add helper target for cat pages updates.
Stick the correct value of PKG_DBDIR into the manpages instead of pointing the user to /var/db/pkg, which may not be the right value if it was customized. Bump version to 20100121.
Update to 20100120: - Make PKG_DBDIR customizable through pkg_install.conf. Things seem to work fine after a few tests but... where are the tests for these tools?!
pkg_install-20091115: Completely ignore @src in pkg_create. Silently ignore the -L option. The combination of -I and -p are used by pkgsrc for the same result.
Pullup ticket #2921 - requested by joerg pkg_install: bug fix Revisions pulled up: - pkgtools/pkg_install/files/lib/pkgdb.c 1.36 - pkgtools/pkg_install/files/lib/version.h 1.142 --- Module Name: pkgsrc Committed By: joerg Date: Thu Oct 22 22:51:29 UTC 2009 Modified Files: pkgsrc/pkgtools/pkg_install/files/lib: pkgdb.c version.h Log Message: pkg_install-20091009: Do not overwrite a string with itself using snprintf. This breaks setting the pkgdb directory internally on Linux. Explicitly check if the string is the same and otherwise just use xstrdup.
pkg_install-20091022: Do not overwrite a string with itself using snprintf. This breaks setting the pkgdb directory internally on Linux. Explicitly check if the string is the same and otherwise just use xstrdup.
pkg_install-20091021: Add support to query arbitrary variables with pkg_admin config-var.
pkg_install-20091015: Use directory index caching by default.
pkg_install-20091008: - Fix German accent - Don't dereference a null pointer for pkg_admin add
pkg_install-20091006: - restore pkg_add -f functionality for missing dependencies (PR 42001) - pkg_admin rebuild should count packages correctly (he@), also count @pkgdb - fix gpg-sign-package syntax in pkg_admin(1) - change default URL for pkg-vulnerabilities to use HTTP
pkg_install-20090911: - Cleanup configure.ac to not check for headers and functions not used - Always use nbcompat/db.h on !NetBSD (PR 41865) - Don't bother setting termwidth in pkg_info, it is never used.
pkg_install-20090817: Add a new command for pkg_admin: findbest. It takes one or more patterns and searches for the best match in PKG_PATH, just like pkg_add would. It prints the URLs of the best match for each pattern to stdout. Rewrite the config file parser to read the file only once.
Fix a bug in pkg_add's -P handling. For dependencies the pkgdb path was computed incorrectly and included destdir more than once. Fix the ACTIVE_FTP option to actually set the "a" flag and not the old "p" flag.
pkg_install-20090806: - pkg_add: add support to check license conditions before installation - pkg_delete: add -k option to skip over preserve packages.
pkg_install-20090727: Make pkg_install WARNS=4 clean and fix a number of lint warnings. Based on reports from veego about warnings with older GCC releases in pkg_delete, where a variable is potentially used uninitialized.
Pullup ticket #2836 - requested by joerg
pkg_install: bug fix
Revisions pulled up:
- pkgtools/pkg_install/files/info/perform.c 1.58
- pkgtools/pkg_install/files/lib/license.c 1.7
- pkgtools/pkg_install/files/lib/pkg_install.conf.5.in 1.7
- pkgtools/pkg_install/files/lib/pkg_install.conf.cat5.in 1.7
- pkgtools/pkg_install/files/lib/version.h 1.132
---
Module Name: pkgsrc
Committed By: joerg
Date: Fri Jul 24 19:06:45 UTC 2009
Modified Files:
pkgsrc/pkgtools/pkg_install/files/info: perform.c
pkgsrc/pkgtools/pkg_install/files/lib: license.c pkg_install.conf.5.in
pkg_install.conf.cat5.in version.h
Log Message:
pkg_install-20070724:
- license handling: accept upper case letters. Keep license checks
case-sensitive as done in the older pkgsrc logic. Document this.
OK dillo@, schmonz@, wiz@
- pkg_info:
- fix handling of non-packages, that are valid archives
- invert order of pkg_info -r to better match the expectations of
make update.
pkg_install-20070724:
- license handling: accept upper case letters. Keep license checks
case-sensitive as done in the older pkgsrc logic. Document this.
OK dillo@, schmonz@, wiz@
- pkg_info:
- fix handling of non-packages, that are valid archives
- invert order of pkg_info -r to better match the expectations of
make update.
pkg_install-20090610: Improve diagnostic around license handling.
pkg_install-20090528: I can't remember why the original pkg_install-renovation code disabled extraction of ownership from packages, so reenable that.
pkg_install-20090527: Try harder to mimic the old pkg_delete behavior and provide a topologically sorted output for pkg_info -r. Bail out on dependency cycles based on recursion depth, currently 64K.
Sync default-accepted licenses with pkgsrc/mk/licenses.mk. Bump version to 20090518.
pkg_install-20090513: Add pkg_create -F, which explicitly provides the compression type.
Add new metadata: PREV_PKGPATH and SUPERSEDES. These will be available from pkg_summary(5) database. To be used to find previous packages when a package is moved or renamed. (Even though that is not recommended.) Documented in pkgsrc Guide and in the pkg_summary(5) manual page. Upcoming commit will have some packages modified to add them.
pkg_install-20090425: Add logic to evaluate license conditions. As frontend for pkgsrc, pkg_admin gets two new commands (check-license and check-single-license), which can be used to evaluate a given condition. pkg_add will be changed to honour licenses at a later point.
pkg_install-20090424: Make pkg_delete -d the default behavior, remove the option. Remove pkg_create -R support (reorder @dirrm entries). Introduce new plist command @pkgdir, which makes pkg_add add this directory if it doesn't exist already and pkg_delete remove it only if no other package has a @pkgdir entry for it. Otherwise directories are pruned when the last file or directory in them is removed. @dirrm is now a pure hint, if the directory doesn't exist, it will be silently skipped.
pkg_install-20090422: Consider EOF during signature scan a fatal error. At the very least, the package is missing the +CONTENTS file at that point. Correctly reset the entry pointer in that case and make the meta data extraction stricter, avoiding NULL dereferences for invalid archives. Fixes pkg_info -X crash on empty files as reported by Daniel Horecki.
Pullup ticket 2732 - requested by joerg Bug fix Revisions pulled up: - pkgsrc/pkgtools/pkg_install/files/add/perform.c 1.85 - pkgsrc/pkgtools/pkg_install/files/lib/version.h 1.121 Module Name: pkgsrc Committed By: joerg Date: Mon Apr 6 14:34:15 UTC 2009 Modified Files: pkgsrc/pkgtools/pkg_install/files/add: perform.c pkgsrc/pkgtools/pkg_install/files/lib: version.h Log Message: pkg_install-20090406: Remove premature return that broke dependency tracking for pkg_add -u. Fixes PR 41143. To generate a diff of this commit: cvs rdiff -u -r1.84 -r1.85 pkgsrc/pkgtools/pkg_install/files/add/perform.c cvs rdiff -u -r1.120 -r1.121 pkgsrc/pkgtools/pkg_install/files/lib/version.h
Remove mention to install security/audit-packages (which no longer exists) and suggest audit capabilities of pkg_admin instead. Update version. Regeneration of cat page also caught up with some previous cleanups.
pkg_install-20090406: Remove premature return that broke dependency tracking for pkg_add -u. Fixes PR 41143.
pkg_install-20090326: Fix diagnostic message to be less confusing to read.
pkg_install-20090309: Fix a double free. Reported by seb.
pkg_install-20090307: Simplify archive handling by depending on archive_read_finish and the close callback where needed. Fixes a file descriptor leak as side effect as reported by wiz.
pkg_install-20090302: Add new option -r to pkg_info, which works like -R, but expands it recursively.
pkg_install-20090301: Plug a number of file descriptor leaks.
pkg_install-20090228: Integrate the PKG_PATH logic for tightly with the find_archive logic: - remember initial current working directory from the time PKG_PATH is processed, it will be used as reference for all relative entries - remove now redundant fchdir dance in pkg_add - pass down to find_archive if this is a top-level package (e.g. requested on the command line) or not; the location of top-level packages is searched for packages first and for URLs or path names the PKG_PATH itself is not processed (e.g. pkg_add foo/bar not look into PKG_PATH for bar). This addresses PR 33884 in a different way. - document the rules for finding packages more explicitly - allow specifying PKG_PATH in pkg_install.conf as well; environment takes precendence. - remove PKG_PATH related logic in pkg_info(1), it doesn't deal with PKG_PATH anyway - remove PKG_PATH, PKG_TMPDIR and TMPDIR description in pkg_info(1), they are no longer used
pkg_install-20090226: Always try to preserve the +PRESERVE file from the old package, even when the new one has one as well. This fixes the update case for the special case of pkg_install itself as reported by tron@.
pkg_install-20090225: Rewrite pkg_delete to expand the list of packages to delete first and reorder it if necessary. It will bail out if it knows in advance that it can't remove a package. It will also fail for errors while removing one package, unless forced. Add an option to remove automatically installed packages that are no longer used. The pkgviews support is kept, but untested. The error handling for pkgviews most of all is as weak as before. Basic review from hubertf@, man page changes by bad@.
Tag as pkg_install-20090214 in preparation for updating NetBSD current.
pkg_install-20090213: Fix pkg_delete -d: - ignore @dirrm commands, directories are removed already on demand - use local copy of dir before changing it, the caller expects it unmodified for the call to pkgdb_remove
pkg_install-20090212: Print the error about missing build information even when the +BUILD_INFO file is missing instead of segfaulting. The problem is from PR 30276, a solution in the form of just installing it will not be implemented.
pkg_install-20090205: - Restrict audit related commands to the documented set and/or fix the documention. - Add support for conditional fetch-pkg-vulnerabilities via -u option.
Merge pkg_install-20090201 from pkg_install-renovation branch.
- DB support is always included from libnbcompat if needed
- pkg_view and linkfarm are not installed any more; they are not moved
into the attic yet, so they can easily be installed as separte package
- common configuration file to customise the behavior of various
components; this supersedes the old audit-packages.conf
- support for PKSC7 signatures (using X509 certs) and GPG signatures for
packages in a secure way. See pkg_admin(8) for how to create them and
pkg_install.conf(5) for the options to use them
- audit-packages and download-vulnerability-list are wrapper scripts
around pkg_admin. They try to mimic the classic options if used sanely.
"pkg_admin audit" is now an order of magnitude faster than before
- pkg_add uses libarchive and libfetch instead of external ftp and tar:
- progress bar is currently missing for downloads
- "pkg_add -" is no longer supported
- no adhoc check for conficts between dependencies and already
installed packages
- "pkg_add -s" has been replaced with an option in pkg_install.conf,
verification of plain detached GPG signatures is no longer supported
- optional check for vulnerabilities before adding a package
- if /var and /usr/pkg are on different fileystems it is twice as fast
now
- conflicts due to overlapping plists are checked before installation
- pkg_add no longer plays with the process limits
- pkg_add and pkg_delete have a new destdir option; scripts have to
either be modified to use PKG_DESTDIR or should be disabled
- pkg_add -u for now can't be used to update to the exact same version
- internal "rm -rf" and "mkdir_p" code
- all memory allocation failures are not explicitly fatal
- if a file is not removed due to a failed checksum, still remove the
entry from pkgdb
pkg_install-20090201: - sync DESCR and MESSAGE with HEAD and the branch state - sync Makefile - regen configure - cleanup __RCSID - merge audit logic in pkg_add and pkg_admin into new audit_packages function. As side effect, pkg_add will list all vulnerabilities before asking the user whether it should continue - sort config_variable array
pkg_install-20090127: Add options to specify user-id and keyrings for GPG operations.
pkg_install-20090108: pkg_add optionally checks for vulnerable packages and bails out.
pkg_install-20081230: Add initial support for secure GPG signatures.
pkg_install-20081127: Correctly deal with short reads from fetchIO_read when loading pkg-vulnerabilities.
Fix strip_txz() so it actually works even when the extension found isn't going to be returned. This fixes some issues with automatic installation of dependencies.
Merge time_t fix from HEAD and call it pkg_install-20081003.
pkg_install-20081002: Explicitly cast time_t values to long and print them as such. Reported by bjs@.
pkg_install-20080916: Merge from changes for read_plist from pkg_install-renovation to always initialize the plist and add append_plist for the one case where this is not desired. Fixes PR 39276.
pkg_install-20080916: Quote arguments of @exec and @unexec correctly.
20080915: Merge a number of bugfixes from the pkg_install-renovation branch: - explicit include of nbcompat/md5.h - use errx when dealing with libfetch as it doesn't set errno - avoid optind = 0 as GNUish getopt will reset itself otherwise
pkg_install-20080825: Fix an inverted test for fake mode. The check stopped +REQUIRED_BY and friends from being moved to the new package, thereby breaking both the delete and the dependency tree. Fix a fexec to fexec_skipempty to silence pkg_delete: package '' is not installed, /var/db/pkg//+CONTENTS missing when updating packages with prefix or destdir being set.
pkg_install-20080821: - Recognize file:// urls to prevent double quoting. - Fix some err/errx botchups. - Add configuration options for verbose logging of net IO, enabling of active FTP (switching to passive FTP as default) and for ignoring proxy settings. - When iterating over PACKAGES to find a match, warn if an entry can't processed (e.g. bad URL).
pkg_install-20080806: Provide and use internal implementation of rm -rf.
Bump to pkg_install-20080805 for today's chdir related changes.
pkg_install-20080730: Add destdir installation support for pkg_add and pkg_delete. This does not chroot install/deinstall scripts, they have to support it directly (using PKG_DESTDIR) or they have to be disabled.
pkg_install-20080727: When using the libnbcompat version of getopt, make sure to not use optind = 0. For GNU getopt compatibility, it does a partial reset. This fixes PR 39181.
pkg_install-20080718: Fix OpenSSL usage so that the key usage check can actually work. Teach pkg_info about signed packages.
pkg_install-20080705: Based on a discussion with tls@, make the key validation stricter. Don't allow CA keys for packages or pkg-vulnerabilities. Require CODE SIGN as key usage attribute for packages. Require that no key usage attribute is set for pkg-vulnerabilities. The latter is not finalised and might change again.
pkg_install-20080627: Restore current directory before processing a package on the command line to allow installing more than one package with full filename.
pkg_install-20080604: As reminded by an old make replace commit, keep +INSTALLED_INFO around for pkg_add -u. Refactor the code a bit.
pkg_install-20080603: pkg_admin check-signature exits with 0 only if all given packages have a valid signature. pkg_add will keep the preserve state of a package when updating.
pkg_install-20080526: Add pkg_install.conf.5 man page from Thomas Klausner, reference it from pkg_add and pkg_admin. Fix a build issue for the !SSL case.
pkg_install-20080524: Stop installation the pkg_view and linkform script as part of pkg_install. They are the only remaining user of the pax dependency. This was discussed was agc@ and the consensus is that if someone really wants them, they should be pulled into a separate less essential package.
Merge license changes from the HEAD.
Add support PKCS7 signatures in packages and pkg-vulnerabilities. The support for non-native OpenSSL still needs to be done, e.g. ensure static linkage for that. Documentation is essentially missing.
2-clause my license.
pkg_install-20080423: Make the linkresolver code more robust.
pkg_install-20080422: Make use of the linkresolver from libarchive and thereby fix the permissions of hardlinks in archives. This wasn't a problem so far as nbpax is (incorrectly) ignoring the permissions of the other entries.
pkg_install-20080415: Add audit-history subcommand for pkg_admin, that lists all known vulnerabilities for a given base package name. E.g. if you run a web server, don't run "pkg_admin audit-history php" before going to bed.
pkg_install-20080407: Add command to print effective value of configuration variables. Remove FETCH_CMD variable from pkg_admin, it is not used.
pkg_install-20080404: Switch pkg_info to use libfetch for remote access.
pkg_install-20080313: Audit functionality for pkg_admin. This uses the backend in libpkg_install and will be extended to check for vulnerabilities at pkg_add time later.
pkg_install-20080311: If the package db directory doesn't exist, handle it like an empty pkgdb and just return.
pkg_install-20080309: - When loading meta data for a package and a file is needed for the current operation and is a required file, complain. - Include the name of the package the meta data could not be loaded from. This addresses PR 38166.
pkg_install-20080223: Redo the check for incomplete packages by annotating which meta data field are required and count which were found during reading the binary package. The original approach didn't work as loads from pkgdb are reduced to the minimal set.
pkg_install-20080222: Free libarchive's side of the package before closing the file descriptor. This stops leaking up to 1MB / package when using bzip2 and addresses PR 38082. Check that at least +COMMENTS, +CONTENTS and +DESC can be extracted, otherwise skip the entry. This stops pkg_info -X from dumping core on non-package files.
pkg_install-20080219: Add new parser for pkg_vulnerabilities, that handles decompress transparently and internally. Preliminary tests with a modified audit-packages show a speed increase by 2 for common operations like listening all vulnerable installed packages.
pkg_install-20080208: Explicitly check in show_var that the buffer is non-NULL. This can stops pkg_info -Q foo from segfaulting for explicitly installed packages. Reported by Stoned Elipot.
pkg_install-20080204: Try to remove all +* files from the pkgdb first. If the log directory is not empty afterwards, be noisy, but try rm -rf on it for the force case.
pkg_install-20080202: Convert pkg_info to use libarchive instead of tar for binary package handling. As a side effect pkg_info on remote packages will use one FTP instance per argument, but will try to fetch only the meta data. This reduces time for pkg_info -X on a full binary repository from 36.9s to 18.1s for the cache hot case (PKG_TMPDIR on tmpfs for the old pkg_info). Thanks to tnn@ for testing.
pkg_install-20080126: Make pkg_add pass down -I and -m when recursively adding packages.
Prepare for update of NetBSD and pkgsrc-2007Q4 by tagging current state as 20071224. Changes include: - better diagnostic for conflicting packages - explicitly check already installed packages for conflicts with to-be-installed package - document pkg_admin rebuild-tree in usage - man page fixes - forcefully remove pkgdb entries (needed for user-usage in some cases)
Don't use the build time version to find packages, we want to pick up the newest version. Bump version to 20071109.
Bump version or revision of all packages that have a runtime dependency on gzip.
Tag pkg_install as 20071103.
- Be less aggressive when resizing the version field, just resize if the old size is not enough. Fixes PR 37031. - Disable dependency tracking in libarchive build. Supposed to address PR 36953. Bump version to 20070927.
Fix a major memory leak in Dewey that existed sine ~forever. This was made a lot more critical with the changes to use the iteration API, as that is running a lot more Dewey comparisions. Thanks to adrianp and wiz for the reports. Bump to 20070916.
Bump to 20070911 for pkg_add -u fixes.
* When adding or checking a package using pkg_admin(1), give a more
meaningful warning if the file is a symlink whose target doesn't exist.
The message has now been changed from:
pkg_admin: netbsd32_compat30-extras: File `/usr/pkg/emul/netbsd32/usr/lib/libm387.so' is in +CONTENTS but not on filesystem!
to:
pkg_admin: Symlink `/usr/pkg/emul/netbsd32/usr/lib/libm387.so' exists and is in +CONTENTS but target does not exist!
* Pass values for --sysconfdir (and --prefix) to the configure script
instead of passing them through CPPFLAGS. Both SYSCONFDIR and PREFIX
are only used by audit-packages, and the audit-packages Makefile
already handles passing these values inherited from the configure
script. This avoids compiler warnings that, e.g. SYSCONFDIR has been
redefined on the command line.
* Fix quoting for arguments to the configure script -- :Q instead of
\"\".
Bump version to 20070828. Reviewed by <joerg>.
When looking for a package with a wildcard pattern, don't add the suffix. find_best_matching_file does that already and doing it twice is actually counterproductive. Bump to 20070821.
Add new option -m to pkg_add. This allows to override MACHINE_ARCH for the purpose of installing a package and enables cross-compiled pkgsrc to not use -f all the time. Bump version to 20070815.
pkg_admin: when retrying with a wildcard pattern, use the computed pattern and not the base name. pkg_info: add -E option to return the best matching installed package. Bump to 20070813.
- Introduce find_best_matching_file and match_local_files. This replace the functionality offered by findmatchingname and findbestmatching name. They optionally strip the suffix from the filename before matching it, instead of modifying the pattern directly. Drop the old functions. - Fix a bug in pkg_order where the version strings where inverted - Make pkg_admin lsbest and lsall use the new functions. - Make ftpio use pkg_order directly. Bump version to 20070812.
Add "rebuild-tree" command to pkg_admin. It recomputes the dependencies and builds the +REQUIRED_BY files from that. Bump to 20070810.
Fix segmentation fault when the package has no variables set and no info file. Patch from Dieter Baron in pkg/36741. Bump version to 20070809 for today's fixes.
Replace note_whats_installed, add_to_list_fn and generally most users of findbestmatchingname and findmatching name with more descriptive and easier to use iterator functions. This functions are a first step to abstract away pkgdb layout from most parts of the code. It also helps to reduce side effects and point out potential bugs in this code. Fix a potential, but practically irrelevant buffer overflow. No longer allow symbolic links directly in pkgdb to store the meta data of individual packages outside. E.g. /var/db/pkg/atk-1.18.0 must be a directory and not point to it. This is not yet enforced in all parts of the code, more changes will follow. Bump version to 20070808.
Correctly handle ordering NULL -- this greatly simplifies using it in iteration functions. Fix a major thinko that prevented the actual order rules from being used. Bump to 20070804.
- only build pkg_admin, pkg_create and pkg_info for --enable-bootstrap - for pkg_create, split-off the package creation from the plist processing. package creation is disabled for --enable-bootstrap - change package creation to use libarchive - add two options (-u and -g) to override file system ownership - pkg_create now creates files in the tarball with correct owner/group based on -u/-g or @owner/@group - add a function to compute the +CONTENTS file in memory Bump version to 20070802. Review of a slightly older version by jlam@
Remove first obstactle in pkg_add for switching to libarchive: MASTER/SLAVE mode is gone now. Bump version to 20070730.
Mostly deorbit mtree support: - pkg_create bails out with -m - pkg_add ignores mtree specs in packages and prints a warning. It does not remove the file like before. - remove now obsolete documentation. pkg_info still prints the information and pkg_admin ignores the files. Make the dependency on the tools a runtime dependency. Take maintainership of pkg_install and bump version to 20070725.
Pullup ticket 2142 - requested by joerg remove PKG_TOOLS_PREFIX handling from bootstrap tools Revisions pulled up: - pkgsrc/pkgtools/mtree/Makefile 1.22 - pkgsrc/pkgtools/mtree/Makefile.common 1.3 - pkgsrc/pkgtools/pax/Makefile 1.15 - pkgsrc/pkgtools/pkg_install/Makefile 1.131 - pkgsrc/pkgtools/pkg_install/files/lib/version.h 1.65 - pkgsrc/pkgtools/tnftp/Makefile 1.3 Module Name: pkgsrc Committed By: joerg Date: Tue Jul 10 15:19:18 UTC 2007 Modified Files: pkgsrc/pkgtools/mtree: Makefile Makefile.common pkgsrc/pkgtools/pax: Makefile pkgsrc/pkgtools/pkg_install: Makefile pkgsrc/pkgtools/pkg_install/files/lib: version.h pkgsrc/pkgtools/tnftp: Makefile Log Message: Remove PKG_TOOLS_PREFIX handling for mtree, pax, pkg_install and tnftp. Modifying files and possibly removing them from the base system is doing more harm than use. Bump revision or version of each package.
Split pattern related functions from lib/str.c off into lib/opattern.c. Rename pmatch to pkg_match and add new function pkg_order that implements the order logic used by pkg_add internally. Change the interface of findmatchingname's callback to take the pattern used for the matching as first argument. The new pkg_order function takes it and it doesn't hurt in other cases. Adjust callers and corresponding callbacks accordingly. Remove an unused matchfn typedef in dewey.c. Bump to 20070720. OK jlam@
Merge 1.75 of lib/ftpio.c from NetBSD: When fixing vsftpd, other FTP server were broken as they return different error codes for unmatching glob patterns. Basically ignore the error code and just try the other pattern. chdir errors are still considered fatal. Bump version to 20070715.
Bump pkg_install
Remove PKG_TOOLS_PREFIX handling for mtree, pax, pkg_install and tnftp. Modifying files and possibly removing them from the base system is doing more harm than use. Bump revision or version of each package.
Sync with NetBSD base: Some FTP server don't expand [] in NLIST, most noticable is vsftpd. Avoid this by splitting the wildcard search pattern into two commands. Sync some other minor changes. Bump to 20070416.
Sync with NetBSD base version: - obsolete support for require scripts - nuke support for the following options of pkg_create: -X (excludefile) -r (require script) -h (Force follow symlink) - add option for pkg_create to specify additional @blddep packages. This brings us to version 20070308.
Merge add/extract.c, rev 1.39: If a plist contains @owner or @group entries and first rename failed, pushout was called with NULL argument. This has the semantic of using a working directory of "/", even though already read plist entries are relative to prefix. The calls to chown and chgrp therefore end up with the wrong arguments for the current directory. To compensate for this, don't pushout the first time. As plists are not supposed to have multiple @cwd entries anymore, this could most likely be simplified, but that is outside the scope of this commit. Merge lib/plist.c, rev 1.51: When processing symlinks in pkg_delete and the call to readlink failed, it often helps to know why, so use warn instead of warnx. Bump version to 20061103.
Import the following change to add/perform.c from src to pkgsrc: Fix uninitialized variable which was causing pkg_add -u to randomly dump core. This may fix PR pkg/30292. Also bump the pkgsrc PKGTOOLS_VERSION to 20060720.
Pull across from source: Fix pkg_info -Q on binary packages; noted by rillig. Bump version to 20060701. Okayed during freeze by wiz.
Sync with src, version 20060424: Add support for creating summary file containing all information about a package repository needed by package managing software. This allows better use of remote binary package repositories. Discussed on tech-pkg.
Sync with NetBSD's src/usr.sbin/pkg_install Version 20060418, mostly for the timeout fix in ftpio.c.
Welcome to version 20060405. pkg_add also check for USE_ABI_DEPENDS. Check if USE_ABI_DEPENDS or IGNORE_RECOMMENDED was set when this package was built. IGNORE_RECOMMENDED is now historical. For the cat man page, I manually made it say "pkgsrc" instead of "NetBSD". I committed to NetBSD's src/usr.sbin/pkg_install/ first :)
Bump date, so that version in src and pkgsrc have the same version _and_ the same code.
Fix -uu handling so recursive updates of already installed packages work, even if the initial package to install isn't installed yet. Bump the version to 20060313.
Add conditional code to ignore the non-numeric part of an OS version
for the sake of compatibility tests in pkg_add.
E.g. DragonFly versions like
1.4.0-RELEASE
are reduced to
1.4.0
This code is currently enabled for DragonFly only.
Handle newer versions of Berkeley DB. Our algorithm is: - if you have > db1 the probably you have db_185.h which means that dbopen is really __db185_open, and we'll prefer that. - else if you have db1, then you have db1/db.h and dbopen - else if you have db.h, then this is either the one from db1 and it will work with -ldb having dbopen, or it will not. Note that the compatibility option on __db185_open() will actually not create or update db1.85/1.86 files, but it will use the current format of the db library. This compatibility layer is source code only.
Reduce the use of the system() function in pkg_install to avoid quoting problems. Instead, use exec*() functions. Replace PUSHOUT() macro and string buffers with a function that operates on data structures. If it is necessary to copy files into place from staging area, then use pax to copy them. Add functions in pexec.c to create a pipe for sending data to a child process. Replace pipe code in create/perform.c with these functions. Use these functions instead of command-line arguments when copying files into place from staging area. Three system() references remain: @exec, @unexec, and vsystem().
Sync with src/usr.sbin/pkg_install:
Fix first part of PR 32068: pkg_info -Q broken for local binary packages
Add BUILD_INFO_FNAME to the files to extract for SHOW_BI_VAR.
Bump version.
Update to 20051107: Fix pkg_info -B against binary packages.
Sync with base system as of Sat Nov 5 13:19:32 UTC 2005. Welcome to 20051103! Now with "automatic" support.
Treat FTP error 450 like 550, otherwise pkg_add from a proftpd server can hang. Submitted-by: Eirik Nygaard
Sync over files from src/usr.sbin/pkg_install to fix PR pkg/30658: Warn, but don't error out on pkgs that were built with IGNORE_RECOMMENDED. Bump version to 20050718.
add autoconf test for missing (like in openbsd-3.6) or broken (like in AIX-4.3.2) PRIu64. If it is missing or broken, provide one. Should address PR30375. Welcome to pkg_install-20050607
Update to 20050530: Sync with base system: Ranges support and some other stuff that wasn't pulled over.
Sync with 20050529 in src/. If a pattern does not have any suffix, assume that it matches both ".tbz" and ".tgz". This allows to install binary package dependencies that are not exact matches, but satisfy requirements.
- pull in the changes from usr.sbin which prevent an over flow of a 32 bit signed number when pkg_add-ing a binary package file larger than 512 Mb. - Bump PKGTOOLS_VERSION (NOT!!! PKGTOOLS_REQD) to 20050527
Address PR pkg/24744 by Jarmo Jaakkola <jarmo.jaakkola@iki.fi>: * ftp.fi.netbsd.org returns "257" in return to a "cd" command, accept that (in addition to 250 and 550). Seems to be allowed per RFC 959. * Make buffer for reply bigger (not too big, as it may hit performance). * Bump PKGTOOLS_VERSION (NOT!!! PKGTOOLS_REQD) to 20050318
Pullup ticket 272 - requested by Robert T. Retzlaff
pkg_add preserve modes of entries in binary packages
Revisions pulled up:
- pkgsrc/pkgtools/pkg_install/files/lib/ftpio.c 1.14
- pkgsrc/pkgtools/pkg_install/files/lib/version.h 1.39
Module Name: pkgsrc
Committed By: agc
Date: Fri Jan 7 11:58:12 UTC 2005
Modified Files:
pkgsrc/pkgtools/pkg_install/files/lib: ftpio.c version.h
Log Message:
Sync changes with src/:
+ extract files on ftp pkg_adds with the 'p' flag to tar, to preserve
modes of entries in the binary package. (Addresses PR 28826 from
Tyler Retzlaff)
Bump version to 20050106
pull in binary pkg handling changes from src:
rework pkg_info(8) operating on binary packages, deprecating the `-.'
argument as it is no longer required (but is retained as a no-op for
backward compatibility).
the behaviour is now what is expected and intended:
- when the pkg argument is path (absolute or relative) to a
binary pkg, pkg_info operates on it.
- when no pkg argument is given, or the argument is not a
binary pkg path, pkg_info operates on the installed packages.
`pkg_info foo-1.0.tgz', `pkg_info /path/to/foo-1.0.tgz', etc. now work
correctly when foo-1.0.tgz is in the cwd.
bump PKGTOOLS_VERSION to 20050210.
Update pkgtools/pkg_install to 20050204 (latest release from the HEAD
branch of src). Changes from version 20050106:
Teach pkg_add(1) and pkg_delete(1) to pass PKG_METADATA_DIR and
PKG_REFCOUNT_DBDIR in the environment when running the +* scripts.
PKG_METADATA_DIR is the location of the +* files after the package is
registered. PKG_REFCOUNT_DBDIR is the location of the reference counts
database directory. If PKG_REFCOUNT_DBDIR is left unset, then it
defaults the the location of the package database directory with
".refcount" appended to the path, e.g. /var/db/pkg.refcount.
pkgviews users should explicitly set PKG_REFCOUNT_DBDIR in the shell
environment to ensure that all packages will use the same refcount
database.
These changes allow the +INSTALL and +DEINSTALL script to keep state
in +* files within ${PKG_METADATA_DIR}, and to store reference counts
in ${PKG_REFCOUNT_DBDIR} to handle usage of resources outside of
${LOCALBASE}.
Sync changes with src/: + always echo the command which is about to be executed during a pkg_add or pkg_delete, not just when verbose mode is on. + extract files on ftp pkg_adds with the 'p' flag to tar, to preserve modes of entries in the binary package. (Addresses PR 28826 from Tyler Retzlaff) Bump version to 20050106
Pull in portability changes from src, and bump version to 20041226: Introduce a new abstraction in the C code, called MaxPathSize. All previous occurrences of MAXPATHLEN and FILENAME_MAX have been changed to use MaxPathSize instead. If MAXPATHLEN is not defined, then assume a default value of 1024 (this is primarily for use on the Hurd). The reason for this is that some older platforms define FILENAME_MAX to be 14, although MAXPATHLEN is 1024. On BSD-derived systems, FILENAME_MAX And MAXPATHLEN are both 1024. Bump pkg_install version to 20041226. These modifications have been tested so far on a NetBSD-current bulk build.
Document the double "-u" option for updating dependant packages. Bump the version to 20041210.
Recognize "pre" as pre-release version. Bump version to 20041110.
Add a -N option to pkg_delete to delete registration information for a package but not its files. Override PKG_DELETE when building this package so -N can be used to upgrade an existing install. Bump version to 20041101.
sync with src: don't explicitly call gunzip, just pass the right arguments to tar. fixes package decompression on Solaris where gunzip is not available (but gzip is), and also decompression of bzip2 packages on non-NetBSD.
Update pkgtools/pkg_install to 20040813 (latest release from the HEAD
branch of src). Changes from version 20040730 include:
Modify pkg_info so that it will only print information on uninstalled
binary packages in the current working directory if -. is given on
the command line. If no -. is given, pkg_info will look for its
information in the ${PKG_DBDIR}. This addresses a long-held gripe on
the part of a number of people, including myself (agc), which completely
violated the POLS.
Add a -q switch to pkg_admin, which allows it to work in a quiet
manner. Fixes the change request in PR 26583, but in a different
manner, preserving existing behaviour and making the new behaviour
dependent upon a command line option.
Sync with version 20040730 from src/usr.sbin/pkg_install on the HEAD: > Re-work the code which checks the recorded build versions of a binary > package to make pkg_add work properly when no +BUILD_INFO file exists. > > Modify the return value from read_buildinfo() to return 1 for success > and 0 for failure. > > Use symbolic constants, rather than integers. > > If we can't read the build information, always tell of this fact. > > Bump version to 20040730 > > Addresses PR 26429; a different version of these mods were verified to > allow a +BUILD_INFO-less binary package to be added by Martin Husemann.
Import 20040601. - Handle symlinks in a view correctly. - Remove superfluous escapes in BRE. This closes PR pkg/24190.
Import pkg_install-20040508. Fixes the -N flag to not cause the -Q codepath to be executed by correcting the SHOW_* macro definitions. Also fix up some function prototypes so this builds with -Wall. Fixes from pkg/25494.
Import pkg_install-20040507 from src/usr.sbin/pkg_install: Add a new flag -Q (for "query") to pkg_info(1) to query the build information for the definitions of specific variables that were saved from build time, e.g. $ pkg_info -Q PKGPATH glib devel/glib $ pkg_info -Q PROVIDES glib /usr/pkg/lib/libglib.so.13 /usr/pkg/lib/libgmodule.so.13 /usr/pkg/lib/libgthread.so.13
20040428: In pkg_add, set the umask nice and early, and remove an absolute setting of mode in a mkdir command.
Sync to 20040421: fix an uninitialized array member access in pkg_add.
Update pkg_install to 20040411, pulling up the changes in the NetBSD source tree: Make pkg_add recognise binary packages built with ignored recommendations (IGNORE_RECOMMENDED set in the presence of RECOMMENDED pre-requisites). This change is fully backward-compatible: binary packages have set the corresponding BUILD_INFO since RECOMMENDED was implemented. Packages built before that time will install as before. Bump PKGTOOLS_VERSION to 20040411. This closes PR pkg/24712 by Thomas Klausner.
Merge 20040409: Parameterize the umask calls so that defs.*.mk can change it on a per-opsys basis (and so that mk.conf can override it to match what the pkgsrc builder is using).
Sync with 20040330.
sync with NetBSD-current's pkg_install from 20040207.
Update pkgtools/pkg_install to 20040114. Changes from version 20040106
include:
* use ${MACHINE_ARCH} instead of what uname() puts into utsname.machine.
the former represents the CPU architecture, which is what is recorded
in binary packages; also allow the OS name to be overridden, as pkgsrc
doesn't always use the value of utsname.sysname.
* allow adding depoted packages if another package with the same
${PKGBASE} is already installed as this is explicitly allowed for in
pkgviews.
pkg_install now prints post-install message by default, if available.
In the "quick depends pre-scan", first print all bad matching depends, then exit (instead printing one conflicting pkg/version on each run).
Sync pkgtools/pkg_install with src/usr.sbin/pkg_install from 20031220. New features include OS/arch/version checking and a large speed improvement to pkg_info.
Sync pkgtools/pkg_install with src/usr.sbin/pkg_install from 20031121.
Sync pkgtools/pkg_install with src/usr.sbin/pkg_install from 20031003. New features include fetching binary packages using HTTP (thanks wiz!) and some minor speed optimizations for pkg_delete.
sync with NetBSD-current's pkg_install-20030923.
Update pkg_install to 20030914. Changes from version 20030913 are ensuring that recursive pkg_delete'ing works by using the correct pkg_dbdir to find packages. This fixes recursive deleting if the -K flag is passed to pkg_delete(1), and the named dbdir differs from the default dbdir (/var/db/pkg).
Update pkg_install to 20030913. Changes from version 20020912 are quieting the file removal when deleting linkfarms if the expected file doesn't exist. Since the symlink isn't there, the mission is already accomplished, so why bother with the warning?
Update pkg_install to version 20030912. Changes from 200230907 are
adding two new options to pkg_admin(1) to simply using this utility to
list the bare package names that match patterns when looking in PKG_DBDIR:
-b Print only the basenames when matching package names for
lsall and lsbest.
-d lsdir
Set lsdir as the path to the directory in which to find
matching package names for lsall and lsbest.
Bump version to 20030907. Changes from previous version include:
* Teaching pkg_add(1) to be smarter about how to add a depoted packge.
* "pkg_delete foo" only deletes foo if it's a unique package.
* Make "pkg_delete -O foo" for delete file entries for foo from
pkgdb.byfile.db actually work.
* Teach pkg_admin(1) two new commands "add" and "delete" for working
with pkgdb.byfile.db.
* pkg_view(1) uses the new pkg_admin(1) commands to keep the
pkgdb.byfile.db files consistent in each view.
* Man page fixes.
Update to pkg_install-20030824. Changes from the previous version include:
* Check for errors in reading from the file descriptor for the ftp
process, and correct the error messages.
* Nuke some code for older NetBSDs that's better handled in
pkgtools/libnbcompat.
* Don't prevent user from using views other than the default view.
Update pkg_install to 20030823, which has the changes to support package views. Pkgsrc changes include: * Convert to use pkgtools/libnbcompat so that it's easier to keep this in sync with src/usr.sbin/pkg_install. * Add a src2nbcompat script that converts src/usr.sbin/pkg_install into an appropriate start for pkgtools/pkg_install. The script removes the Makefiles, adds CPP inclusion guards around each #include <...> line, and includes <nbcompat.h> at the top of each *.c file. This should make it even easier to keep sources in sync with the HEAD.
Update to version 20030423 via patch from src/usr.sbin/pkg_install. >Log Message: >pkg_add fix: >When doing quick pre-check if any conflicting dependencies are installed >and a dependency is not found installed do not try to search for a wildcarded >(-[0-9]* suffix) package if the dependency was already wildcarded. > >This prevent something like 'p5-Net-DNS-0.33' reported as an already >installed version of 'p5-Net-[0-9]*' as a dependency. >Before this fix 'p5-Net-[0-[0-9]*' would have been incorrectly searched for. > >Reviewed by hubertf@. > >Bump PKGTOOLS_VERSION to 20030423. > > >To generate a diff of this commit: >cvs rdiff -r1.81 -r1.82 src/usr.sbin/pkg_install/add/perform.c >cvs rdiff -r1.26 -r1.27 src/usr.sbin/pkg_install/lib/version.h
sync with bootstrap and -current: - pkg_admin getcwd() fix. - pkg_delete checksum mismatch warning. - crank PKGTOOLS_VERSION.
catch up to bootstrap. bump PKGTOOLS_VERSION to 20030411.
Synch with main sources: Changes by hubertf and seb; these changes tested on NetBSD, Linux and Irix. Modified Files: src/usr.sbin/pkg_install/add: perform.c pkg_add.1 Log Message: Implement remaining TODO item in pkg upgrade (pkg_add -u): * Upgrade step 1/4: Check if the new version is ok with all pkgs * (from +REQUIRED_BY) that require this pkg Inspired by bsd.pkg.mk's upgrade(?) target. Modified Files: src/usr.sbin/pkg_install/admin: main.c src/usr.sbin/pkg_install/info: main.c perform.c Log Message: Consistently check findmatchingname() return value for error condition. Among other this fixes 'pkg_info -e whateverpkg' exit status when /var/db/pkg is missing: it is now 1 and not 0. Modified Files: src/usr.sbin/pkg_install/lib: version.h Log Message: Bump to "20030325" after today's changes from seb and me
Sync with main sources:
Date: Sat Mar 15 20:49:27 UTC 2003
Introduce a pkgdb_dump() function, which dumps the cache file of
(filename, package) pairs.
Modify calling functions to use pkgdb_dump() directly, rather than
sequences of
pkgdb_open
{ pkgdb_iter, pkgdb_retrieve }
pkgdb_close
calls.
Remove the now unnecessary pkgdb_iter function.
Date: Sat Mar 15 20:50:15 UTC 2003
Bump version string for pkgdb_dump changes.
Date: Sat Mar 15 20:54:26 UTC 2003
Catch one more place that could result in Current not being set properly
(and thus in the execution of "rm -fr /") if ^C is pressed at the wrong time.
See also PR 19436.
belatedly sync with src: Allow '%D' to be used when no last_file available. Fixes binary package installation of gnome-dirs. crank PKGTOOLS_VERSION to 20030202.
On NetBSD, man pages were getting installed into /usr/man. That's, like, so 80's! Pass a value more appropriate for the current decade to --mandir via CONFIGURE_ARGS, and let ./configure set this in the Makefiles. Install catted man pages with the suffix ".0" rather than ".1". Bump PKGTOOLS_VERSION.
Define NO_PKGTOOLS_REQD_CHECK, which will mean something in a moment. Rather than override LOCALBASE, set PREFIX (after including bsd.pkg.mk). Bump PKGTOOLS_VERSION (many changes since 20021123).
Import autoconf'd pkg_install source from
othersrc/bootstrap-pkgsrc/pkg_install into ${FILESDIR}.
Using autoconf greatly simplifies maintenance of this package across
multiple platforms. Placing the extracted source under ${FILESDIR}
will eventually let us use the same source for bootstrapping as
well, though we're not ready for this yet.
Initial revision