When using evdev support the XKB keymap name (with variant) for Dvorak
users will be e.g. "US (Dvorak)". The Dvorak layouts are not described
in /usr/share/X11/xkb/rules/evdev.xml, so these are not added to
ply-keymap-metadata.h / keymap-render.png .
For the console-keymap case dvorak is handled specially in:
keymap-render.py:normalize_keymaps()
ply-keymap-icon.c:ply_keymap_normalize_keymap()
mapping all keymap-names with a lowercase dvorak in there to "dvorak",
change this special handling to be case-insensitive so that it also works
for the xkb-keymap case.
Note the keymap-render.py change really is a no-op since keymap-render.py
only calls normalize_keymaps() on console-keymaps which are always
lower-case. normalize_keymaps() should still be updated though to keep
the 2 functions in sync.
Link: https://bugzilla.redhat.com/show_bug.cgi?id=2341810
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
The first line here checked for the wrong variable and is a dupe
from two lines earlier anyway, and the second line isn't guarded
at all, which seems to cause the weird failure we've been seeing
in openQA testing.
Also add a couple more existence checks for the same variables
later.
Signed-off-by: Adam Williamson <awilliam@redhat.com>
Some minimal installs won't have fontconfig or xkb. In those cases,
the script should continue to work even if the initramfs will be
less featureful.
This commit fixes that.
The heuristic to check whether or not we're inside of a git checkout
or a tarball isn't working properly.
This commit changes it to use git rev-parse --is-inside-git-dir which
is pretty specifically designed for this use case.
Closes: https://gitlab.freedesktop.org/plymouth/plymouth/-/issues/232
Right now we call date directly from meson.build leading to
non-reproducible builds.
This commit makes it only call date when building from git,
otherwise it extracts the version from the tarball name.
script borrowed from accountsservice.
Closes https://gitlab.freedesktop.org/plymouth/plymouth/-/issues/188
Now that plymouth supports /dev/input directly, it's important
that the initramfs gains all the newly needed support files.
This commit adds the necessary changes to the script to ensure
those files get moved over.
Some contributions by n3rdopolis and Ray Strode.
At the moment the keyboard-render script only generates short
names for console layouts.
We're going to add /dev/input support to plymouth using
libxkbcommon, so we're going to need a list of of those keymaps
too.
This commit adds that.
Some contributions by n3rdopolis and Ray Strode.
Apparently the:
[x] Squash commits
box was checked when merge request plymouth/plymouth!177 was merged.
Oops.
We want good commit messages for such a big change, though, so people
doing code spelunking later have a fighting chance of following what's
going on.
This reverts commit dacfb36b57.
Subsequents commits will bring it back, peicemeal.
Now that there's a freetype plugin available, it should be installed in
the initramfs.
This commit adds the changes to plymout-populate-initrd to make that
happen.
Some contributions by Petr Vorel and Nathan Pratta Teodosio.
Reviewed-by: Petr Vorel <pvorel@suse.cz>
Signed-off-by: Fabian Vogt <fvogt@suse.com>
The formatting in the codebase isn't perfect, but there's no
reason to make it worse.
This commit adds a CI check to make sure new code is styled
right.
The moment it's possible to sneak in functions like:
static void
foo (int param1, int param2)
{
}
when the style requires parameters on separate lines.
This updates the uncrustify config to account for that.
Right now plymouth-set-default-theme only supports rebuilding the initrd if a theme
is passed explicitly.
This commit improves the script to also work for --reset and even in a
standalone mode where no theme is passed at all.
Closes https://gitlab.freedesktop.org/plymouth/plymouth/-/issues/174
Add a plymouth-switch-root-initramfs.service, which will call
"plymouth update-root-fs --new-root-dir=/run/initramfs" to switch back
to the initramfs (when applicable).
Systemd will run this service before plymouthd receives the SIGTERM on
shutdown, so this will cause the plymouthd-fd-escrow helper to run
from the initramfs.
This avoids the plymouthd-fd-escrow helper keeping the rootfs busy.
Changes by Hans de Goede:
- Fix a couple of typos
- Add Conflicts=dracut-shutdown.service to plymouth-switch-root-initramfs.service
dracut-shutdown.service restores the initramfs when it is _stopped_
use Conflicts to make sure its ExecStop has run before we do
- Add a check for switching back to the initramfs to on_newroot () and dump
the debug-buffer before the switch (while we still have access to /var/log).
- Also add plymouth-switch-root-initramfs.service to kexec.target.wants.
kexec.target.wants uses --mode=shutdown, so the plymouthd-fd-escrow helper
will run, so we need to switch to the initramfs.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
commit 04102125 removed a feature, only several versions of
GDM relied on for doing the splash to login screen transition.
but it missed a few spots in the build goo and documentation. So
this commit does another pass to fully clean up any lingering
references to obsolete GDM transition code.
There have been some small tweaks to the gnome lockscreen password
entry filed which we use as template for the diskcrypt password dialog,
adjust our dialog to match these tweaks.
Also move the keyboard indicator to be close to the entry, so that it
is clear it belongs to the entry.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Since plymouth concatenates boot logs one after the other in
/var/log/boot.log, causing it to grow endlessly. we need to logrotrate it.
Fixes#31
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Add a script for generating a png with the short-name (ignoring variants)
of all keymaps listed by "localectl list-keymaps" pre-generated.
This scripts also generates a ply-keymap-metadata.h file with info on
which pre-generated keymap name is where in the png.
This will be used in a follow-up commit to add support for a new
keyboard-keymap-icon control to libply-splash-graphics.
Note that this commit does not add the generated keymap-render.png file,
this file will be added to each themes image-dir separately as the color
of the pre-generated text may differ per theme.
Changes by Hans de Goede:
- Change generated metadata into a C header file
- Drop drawing of curved corners, we just want the text
- Add special handling for dvorak
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Before this commit plymouth-populate-initrd was only recursively copying the
/usr/share/plymouth/themes/$PLYMOUTH_THEME_NAME to the initrd, assuming
that ImageDir will point there.
This makes it impossible for 2 themes to share their ImageDir, which is
desirable for example for the spinner and bgrt themes, which use the same
images with slightly different settings.
This commit also makes plymouth-populate-initrd also copy the ImageDir
if it is different from the theme-dir, making it possible for ImageDir
to point to a different dir.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Not all distros use the upstream plymouth-populate-initrd
script to populate their initramfs. As a consequence,
some themes have been developed that use subdirectories,
(which is not supported by plymouth-populate-initrd).
This commit adds support for that feature, so that
preexisting themes get properly installed.
https://bugs.freedesktop.org/show_bug.cgi?id=103424
If you set PLYMOUTH_THEME_NAME to override the theme in an initrd
(as e.g. lorax does when building upgrade.img), plymouth-populate-initrd
tries to edit plymouthd.conf to enable that theme.
Unfortunately, the existing `sed` line doesn't work if your
plymouthd.conf is empty or all commented out - which is how we currently
ship it.
So before modifying the config, make sure it has a [Daemon] section
header, and a Theme=[placeholder] line for us to modify.
Resolves: RHBZ#1223344
Some themes like to keep their content in subfolders,
but plymouth-populate-initrd currently fails to copy
those subfolders over to the initrd.
This commit fixes that.
https://bugzilla.gnome.org/show_bug.cgi?id=94883
If plymouth is configured --with-system-root-install=no then the
systemd unitd files will write the paths of plymouth and plymouthd
relative to /usr . The script currently hardcodes installing them
to the initrd's /
This commit makes sure they get placed on the same part of the of
the initrd filesystem as systemd expects to find them.
https://bugs.freedesktop.org/show_bug.cgi?id=74174
plymouth-update-initrd is a script that should probably be eventually
dropped. It was originally created to unpack and initrd and graft
plymouth in. Later, it just became a thin wrapper around mkinitrd.
These days, very few (any?) distros use mkinitrd. Change it to call
dracut instead.
Relevant irc log:
<newfo> this is SO WRONG:
http://cgit.freedesktop.org/plymouth/tree/scripts/plymouth-update-initrd
<newfo> it won't work on any distro
<newfo> would you mind updating that please?
<newfo> replace the mkinitrd line in
/usr/libexec/plymouth/plymouth-update-initrd to dracut -f
/boot/initramfs-$(uname -r).img $(uname -r)
<-- newfo has quit (Client Quit)
<haraldh> halfline, can you add plymouth-start.service to
plymouth-populate-initrd ??
<halfline> haraldh: sure, can you give me details on the bug its fixing?
<haraldh> except, if you put yourself out of the plymouth cgroup
<haraldh> and the "@" in argv[0][0]
<haraldh> better put plymouth-start.service in the
initrd-switch-root.target
<haraldh> easier
<halfline> well we already do the "@" in argv[0][0]
<halfline> and we already put KillMode=none SendSIGKILL=no in the
service file
<halfline> but will add the change
<haraldh> hmm, ok
You can set PLYMOUTH_THEME_NAME when building initramfs to get a
different theme into initramfs, but this doesn't change the default
theme, so the resulting initramfs won't actually use the theme we
installed.
This patch makes plymouth-populate-initrd rewrite the 'Theme=XXX' line
in plymouthd.conf, so plymouth will use the theme we install.
the initrd hits the local-fs.target as part of its normal
boot process. We used to use local-fs.target as a way of
knowing the system / is read-write. This no longer is a
valid mechanism.
This commit:
1) Stops installing plymouth-read-write service in the initrd
2) Makes it so if it does end up in the initrd it won't be
used
Related to fedora bug 830482