Wednesday, June 24, 2026

Re: pkg_add: show -n updates without a progress meter

On Fri, 05 Jun 2026 12:24:01 +0200, Kirill A. Korinsky <kirill@korins.ky> wrote: > > ports@, > > it is changes in base, but I think pkg_add is more related to ports@, so > I've used that mail list. > > I'd like to let pkg_add -Iunx report which packages would be updated, so > scripted dry run checks no longer need progress meter output. > > I have in /etc/daily.local pkg_add -un like check to catch outdated > packages. > > Current pkg_add needs -Iunm and some "magic" to strip progress bar and ESC > codes from output to be useful. > > Suggested version needs only pkg_add -Iunx | grep -v ^quirks- > > Also, while here, clarify in pkg_add(1) that -I only disables prompts and > that -n reports package additions or updates because that required to read > the code to understand. > > Thoughts? Ok? > Just friendly ping. Index: usr.sbin/pkg_add/pkg_add.1 =================================================================== RCS file: /home/cvs/src/usr.sbin/pkg_add/pkg_add.1,v diff -u -p -r1.170 pkg_add.1 --- usr.sbin/pkg_add/pkg_add.1 22 May 2025 01:40:21 -0000 1.170 +++ usr.sbin/pkg_add/pkg_add.1 4 Jun 2026 20:53:16 -0000 @@ -374,7 +374,10 @@ which is more discriminating. Force update even if dependencies no longer match. .El .It Fl I -Force non-interactive mode. +Force non-interactive mode, disabling prompts. +This does not affect progress meter output; use +.Fl x +to disable it. Default is to be interactive when run from a tty. .It Fl i Force interactive mode, even if not run from a tty. @@ -416,8 +419,8 @@ Causes .Nm to always display the progress meter in cases it would not do so by default. .It Fl n -Don't actually install a package, just report the steps that -would be taken if it was. +Don't actually install a package, just report package additions or updates +that would be performed. Will still copy packages to .Ev PKG_CACHE if applicable. Index: usr.sbin/pkg_add/OpenBSD/PkgAdd.pm =================================================================== RCS file: /home/cvs/src/usr.sbin/pkg_add/OpenBSD/PkgAdd.pm,v diff -u -p -r1.152 PkgAdd.pm --- usr.sbin/pkg_add/OpenBSD/PkgAdd.pm 6 May 2025 18:36:20 -0000 1.152 +++ usr.sbin/pkg_add/OpenBSD/PkgAdd.pm 4 Jun 2026 20:45:49 -0000 @@ -831,8 +831,12 @@ sub really_add($set, $state) $set, $state)); } }); - $set->setup_header($state); - $state->progress->next($state->ntogo(-1)); + my $shown = $set->setup_header($state); + my $todo = $state->ntogo(-1); + $state->progress->next($todo); + if ($state->{not} && !$shown) { + $state->say("#1: #2", $state->{setheader}, $todo); + } for my $handle ($set->newer) { my $pkgname = $handle->pkgname; my $plist = $handle->plist; -- wbr, Kirill

Re: fix-build: net/nchat

On Wed, 24 Jun 2026 10:51:32 +0200, Nazarenko Mykyta <mykyta@nazarenko.sbs> wrote: > > Buenos dias ports@! > > As naddy@ reported, at the time the port failed to build in bulk-build; > as it turned out later, this was due to the absence of the > -DPHP_EXECUTABLE=OFF flag. I added this flag to completely disable the > generation of comments in the headers of the built-in tdlib and to fix > the port’s build when it is built in a dpb environment. > > OK? > Thanks, commited. > Index: Makefile > =================================================================== > RCS file: /cvs/ports/net/nchat/Makefile,v > diff -u -p -u -r1.1.1.1 Makefile > --- Makefile 1 Jun 2026 19:27:34 -0000 1.1.1.1 > +++ Makefile 24 Jun 2026 08:48:24 -0000 > @@ -30,6 +30,7 @@ LIB_DEPENDS = databases/sqlite3 \ > graphics/png > > CONFIGURE_ARGS = -DCCACHE_FOUND=OFF \ > + -DPHP_EXECUTABLE=OFF \ > -DCCACHE_PROGRAM=OFF \ > -DCMAKE_DISABLE_FIND_PACKAGE_Git=ON -- wbr, Kirill