Page MenuHomeFreeBSD

pkgbase: Don't run scripts for some package types
AbandonedPublic

Authored by markj on Jan 25 2024, 7:03 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Apr 8, 10:28 AM
Unknown Object (File)
Sun, Apr 7, 7:07 AM
Unknown Object (File)
Tue, Mar 26, 11:45 PM
Unknown Object (File)
Mar 20 2024, 6:07 PM
Unknown Object (File)
Feb 23 2024, 9:14 AM
Unknown Object (File)
Feb 5 2024, 5:13 PM
Unknown Object (File)
Feb 1 2024, 5:51 AM
Unknown Object (File)
Jan 27 2024, 3:52 PM

Details

Reviewers
manu
Group Reviewers
pkgbase
Summary

See bugzilla PR 276115. Most base system packages have several
auxilliary packages. In general, if the package has a post-install
script, the auxilliary packages do not need to also run it.

Guard package scripts with a test so that it's possible to disable them
at package creation time. Do so for all -dev, -dbg, -man, -lib32
package types. If individual packages want to override this behaviour,
they can be more selective in their use of the %RUNSCRIPTS% guard.

PR: 276115

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 55608
Build 52497: arc lint + arc unit

Event Timeline

markj requested review of this revision.Jan 25 2024, 7:03 PM

This ensures that we don't do things like run certctl hash when certctl-man is upgraded, or run kldxref when kernel debug symbols are upgraded. While these redundant scripts are harmless, they slow down upgrades and are somewhat surprising.

(Only build-tested so far.)

If that works I think that the easiest approch.
Why was the comment lines on the top of the file deleted though ?

I haven't tested but I think we can have a simpler approach by using

.include(try=true) " "%PKG_NAME_PREFIX%-%PKGNAME%.script"

And move the whole scripts: {} block into certctl.script

In D43593#994484, @bapt wrote:

I haven't tested but I think we can have a simpler approach by using

.include(try=true) " "%PKG_NAME_PREFIX%-%PKGNAME%.script"

And move the whole scripts: {} block into certctl.script

It almost work I need to privide the full path and not relative path for it to work, I should have a proposal ASAP