Skip to content

image: systemd with pcre2, so journalctl --grep works - #279

Merged
aledbf merged 1 commit into
mainfrom
systemd-pcre2
Nov 19, 2026
Merged

aledbf merged 1 commit into
mainfrom
systemd-pcre2

Conversation

@aledbf

@aledbf aledbf commented Nov 19, 2026

Copy link
Copy Markdown
Member

The stage1 profile turns pcre2 off. Without it, journalctl --grep in a workspace fails with "compiled without pattern matching support".

  • It costs a boot nothing: journalctl dlopens libpcre2 only when asked to grep (src/shared/pcre2-util.c).
  • Checked by running it: the build runs the journalctl it produced with --grep over an empty journal directory, and requires "No entries" back.
  • The library is named: mkosi.conf names libpcre2-8-0, as it names libpam-systemd, rather than trusting it to arrive with grep. It was already in the image; the image still has 217 packages, the seven systemd ones +spin1 and held.
  • acl in the build container: it quiets the journal install step's setfacl: not found, which is harmless (|| : in src/journal/meson.build).

Every other option stage1 turns off stays off. Their packages were not in the image before either, or they are dlopen-only libraries nothing here uses.

Checked: task image:build, boot:lockdown, boot:logind, task lint.

🤖 Generated with Claude Code

stage1 turns pcre2 off, and journalctl --grep in a workspace said
"compiled without pattern matching support". journalctl dlopens libpcre2
only when asked to grep, so a boot never loads it. The build runs the
journalctl it made with --grep over an empty journal directory; the
image names libpcre2-8-0. acl in the build container quiets the journal
install step's harmless "setfacl: not found".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@aledbf
aledbf merged commit 7299d2f into main Nov 19, 2026
3 checks passed
@aledbf
aledbf deleted the systemd-pcre2 branch November 19, 2026 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant