naccyde / rpms / systemd

Forked from rpms/systemd a year ago
Clone
2aacef
From bec9d65390249d4e88f5095e751283645a2a4c08 Mon Sep 17 00:00:00 2001
2aacef
From: Frantisek Sumsal <frantisek@sumsal.cz>
2aacef
Date: Mon, 7 Nov 2022 12:07:27 +0100
2aacef
Subject: [PATCH] test: fix keymaps installation on Arch
2aacef
2aacef
Where the keymaps live under /usr/share/kbd/keymaps/.
2aacef
2aacef
(cherry picked from commit 1edad89399e7cbee230878589ac618103c157ec7)
2aacef
2aacef
Related #2138081
2aacef
---
2aacef
 test/test-functions | 25 +++++++++++++------------
2aacef
 1 file changed, 13 insertions(+), 12 deletions(-)
2aacef
2aacef
diff --git a/test/test-functions b/test/test-functions
2aacef
index 45ca472916..194cd682bb 100644
2aacef
--- a/test/test-functions
2aacef
+++ b/test/test-functions
2aacef
@@ -2007,7 +2007,8 @@ install_locales() {
2aacef
 install_keymaps() {
2aacef
     local i p
2aacef
     local -a prefix=(
2aacef
-        "/usr"
2aacef
+        "/usr/lib"
2aacef
+        "/usr/share"
2aacef
     )
2aacef
 
2aacef
     dinfo "Install console keymaps"
2aacef
@@ -2016,7 +2017,7 @@ install_keymaps() {
2aacef
             && [[ "$(meson configure "${BUILD_DIR:?}" | grep 'split-usr' | awk '{ print $2 }')" == "true" ]] \
2aacef
             || [[ ! -L /lib ]]; then
2aacef
         prefix+=(
2aacef
-            ""
2aacef
+            "/lib"
2aacef
         )
2aacef
     fi
2aacef
 
2aacef
@@ -2025,12 +2026,12 @@ install_keymaps() {
2aacef
             # The first three paths may be deprecated.
2aacef
             # It seems now the last three paths are used by many distributions.
2aacef
             for i in \
2aacef
-                "$p"/lib/kbd/keymaps/include/* \
2aacef
-                "$p"/lib/kbd/keymaps/i386/include/* \
2aacef
-                "$p"/lib/kbd/keymaps/i386/qwerty/us.* \
2aacef
-                "$p"/lib/kbd/keymaps/legacy/include/* \
2aacef
-                "$p"/lib/kbd/keymaps/legacy/i386/qwerty/us.* \
2aacef
-                "$p"/lib/kbd/keymaps/xkb/us*; do
2aacef
+                "$p"/kbd/keymaps/include/* \
2aacef
+                "$p"/kbd/keymaps/i386/include/* \
2aacef
+                "$p"/kbd/keymaps/i386/qwerty/us.* \
2aacef
+                "$p"/kbd/keymaps/legacy/include/* \
2aacef
+                "$p"/kbd/keymaps/legacy/i386/qwerty/us.* \
2aacef
+                "$p"/kbd/keymaps/xkb/us*; do
2aacef
                     [[ -f "$i" ]] || continue
2aacef
                     inst "$i"
2aacef
             done
2aacef
@@ -2039,10 +2040,10 @@ install_keymaps() {
2aacef
         # When it takes any argument, then install more keymaps.
2aacef
         for p in "${prefix[@]}"; do
2aacef
             for i in \
2aacef
-                "$p"/lib/kbd/keymaps/include/* \
2aacef
-                "$p"/lib/kbd/keymaps/i386/*/* \
2aacef
-                "$p"/lib/kbd/keymaps/legacy/i386/*/* \
2aacef
-                "$p"/lib/kbd/keymaps/xkb/*; do
2aacef
+                "$p"/kbd/keymaps/include/* \
2aacef
+                "$p"/kbd/keymaps/i386/*/* \
2aacef
+                "$p"/kbd/keymaps/legacy/i386/*/* \
2aacef
+                "$p"/kbd/keymaps/xkb/*; do
2aacef
                     [[ -f "$i" ]] || continue
2aacef
                     inst "$i"
2aacef
             done