Page MenuHomeFreeBSD

pkgbase: rework certctl package to only run rehash on the main package
ClosedPublic

Authored by bapt on Mar 15 2024, 5:03 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Nov 17, 9:09 AM
Unknown Object (File)
Sun, Nov 17, 8:52 AM
Unknown Object (File)
Thu, Nov 14, 2:34 AM
Unknown Object (File)
Mon, Nov 11, 9:09 AM
Unknown Object (File)
Mon, Nov 11, 3:10 AM
Unknown Object (File)
Mon, Nov 4, 10:07 PM
Unknown Object (File)
Oct 3 2024, 1:16 AM
Unknown Object (File)
Oct 2 2024, 10:21 AM
Subscribers

Details

Summary

Rework how ucl manifest are generated leveraging ucl features and flua

now the ucl generation is done via a lua script which uses libucl to
ingest the template and use variables as defined in its command line.

the template will include only if it exist a ucl file named after the
package name which will complement the template or overwrite what was
defined in the template if defined in this specific ucl file

this allows to overwrite license, but add script only to the packages
who actually needs them.

As a results the post install scripts are now only added to the right
package and not also added to the subpackages like -man or -dev

Diff Detail

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

Event Timeline

bapt requested review of this revision.Mar 15 2024, 5:03 PM

Add kernel and source packages

release/packages/binutils.ucl
1–17

This file is unused after all binutils removed from the base system - I deleted now in 1e4cd5ed54d73dcb8e9af92990e7bf005b9a5710

release/packages/generate-ucl.lua
7

This script is sort of internal use only so doesn't warrant a man page but some comment in here about usage would be good - indicate that args are variable value pairs

release/packages/generate-ucl.sh
33–34

is this a separate change that can be handled first?

release/packages/runtime.ucl
13

extra blank line?

Overall I like it, but maybe we need a way to define keys for all flavors of a package. See my inline comment about ssh.

As emaste pointed out, the removal of vital seems unrelated and should go into a separate patch.

Makefile.inc1
2112

Indentation is wrong here.

2121

Indentation is wrong here.

release/packages/generate-ucl.lua
6

You also want to check #arg >= 2 I think.

7
12
15
release/packages/ssh.ucl
0

Just picking an example - doesn't this mean that the FreeBSD-ssh-man package will be installed with licenses = [BSD2CLAUSE] instead of ISCL? Presumably that's not what we want. Or, at least we may want some way to specify keys for all flavors of a package without having to create ssh-man.ucl etc..

bapt marked an inline comment as done.

fix indentation

bapt marked 8 inline comments as done.Mar 18 2024, 9:09 AM
bapt added inline comments.
release/packages/generate-ucl.sh
33–34

actually no, the vital flag is supposed to be appended directly the to right ucl files, so there was a mistake, which is now fixed

markj added inline comments.
release/packages/generate-ucl.sh
158

Leftover debugging.

release/packages/template.ucl
18

IMO it is a bit weird to hard-code the path release/packages here.

This revision is now accepted and ready to land.Mar 19 2024, 6:40 AM
bapt marked an inline comment as done.

address @marjk last comments

This revision now requires review to proceed.Mar 19 2024, 6:50 AM
bapt marked 2 inline comments as done.Mar 19 2024, 6:51 AM

Please let me know if you'd like some testing.

This revision is now accepted and ready to land.Mar 19 2024, 6:52 AM
release/packages/generate-ucl.lua
2

Sorry - I only just thought of this: won't this break make packages on non-FreeBSD build hosts? Do we expect that to work? Should we use a bootstrapped flua executable?