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)
May 31 2024, 10:19 AM
Unknown Object (File)
May 28 2024, 7:47 PM
Unknown Object (File)
May 23 2024, 11:39 AM
Unknown Object (File)
May 22 2024, 10:27 PM
Unknown Object (File)
May 16 2024, 5:32 PM
Unknown Object (File)
May 12 2024, 6:14 AM
Unknown Object (File)
Apr 30 2024, 6:45 PM
Unknown Object (File)
Apr 26 2024, 2:20 AM

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