From a6ec22b9a4d2fbd4fc686e13baa670a5c7987ae6 Mon Sep 17 00:00:00 2001 From: Luca Weiss Date: Mon, 7 Sep 2020 23:43:58 +0200 Subject: [PATCH] main/postmarketos-mkinitfs: use kmsdrm sdl backend for osk-sdl (MR 1625) --- main/postmarketos-mkinitfs/APKBUILD | 6 +++--- main/postmarketos-mkinitfs/init_functions.sh | 10 +++++++++- main/postmarketos-mkinitfs/mkinitfs_functions.sh | 11 +++++++++++ 3 files changed, 23 insertions(+), 4 deletions(-) diff --git a/main/postmarketos-mkinitfs/APKBUILD b/main/postmarketos-mkinitfs/APKBUILD index 5bbb06a19..318f0251f 100644 --- a/main/postmarketos-mkinitfs/APKBUILD +++ b/main/postmarketos-mkinitfs/APKBUILD @@ -1,6 +1,6 @@ # Maintainer: Oliver Smith pkgname=postmarketos-mkinitfs -pkgver=0.14.2 +pkgver=0.15.0 pkgrel=0 pkgdesc="Tool to generate initramfs images for postmarketOS" url="https://postmarketos.org" @@ -55,7 +55,7 @@ check() { sha512sums="5037cb7285bb7c0c40ca9e6df332d882ef9a8b379756c785f921e062dab1b7e7f3139d00897f69323a916d709ced4297fea8cbd3a13ebae575b873ec9e2cbfae 00-default.modules 7fc6ba96419628850984df3322b73bcf655cba03fe3e97ec7425e66e90f4b2a4de106b5cb2e3d46785a92557334288011334104285e2050c7a8e823b8fa5668c init.sh.in -e9bbf6850c0c44f10c8fe66ceb05ed454844646dd937b5fe614810a0cce7c7383febe5ee1b0830217bff71a29621d82aa57adbcd59cb24a72701504887513ff1 init_functions.sh +ce30c06d36c425668fd84a192b1c03162fca937b0c1d170247380309309bf486021a539cb70b2ebe96cb1a7ae4090dbdf55401970ee0f1140cb327b7e74ddd30 init_functions.sh dfc01ee0547ea88b7aa45a005e842b636e9e19bbf1705f3dad53a66d57af7c5c513c092b5469a06d9b00322e56a4d25f1b47e4c5324aafa99f5291679968d1f1 mkinitfs.sh -f82f301f11cbe797210c878762fd0f531af17706496c7721d6ef5b210221d46444886ceb07cd18a10f7d4742aa6a61c3486f49e02c149750158dc92838a24f9e mkinitfs_functions.sh +874b1bba86085a4b7707b3d1ac6534e2027b5783111b2f9c66c2595ada95113a95272c1be9d234b7957c785978de0c5352b4abd70819871caed9efcfbf703dac mkinitfs_functions.sh c7a3c33daeb12b33ac72207191941c4d634f15c22958273b52af381a70ebaba1d3a9299483f0c447d9e66c560151fe7b9588bb4bbef2c8914f83185984ee4622 mkinitfs_test.sh" diff --git a/main/postmarketos-mkinitfs/init_functions.sh b/main/postmarketos-mkinitfs/init_functions.sh index 4117fee9a..19044db20 100644 --- a/main/postmarketos-mkinitfs/init_functions.sh +++ b/main/postmarketos-mkinitfs/init_functions.sh @@ -455,8 +455,16 @@ setup_directfb_tslib() { } start_onscreen_keyboard() { - setup_directfb_tslib + # shellcheck disable=SC2154 + if [ -n "$deviceinfo_mesa_driver" ]; then + export SDL_VIDEODRIVER="kmsdrm" + else + setup_directfb_tslib + fi + osk-sdl -n root -d "$partition" -c /etc/osk.conf -v > /osk-sdl.log 2>&1 + + unset SDL_VIDEODRIVER unset DFBARGS unset TSLIB_TSDEVICE } diff --git a/main/postmarketos-mkinitfs/mkinitfs_functions.sh b/main/postmarketos-mkinitfs/mkinitfs_functions.sh index 8c088b325..4843938a2 100644 --- a/main/postmarketos-mkinitfs/mkinitfs_functions.sh +++ b/main/postmarketos-mkinitfs/mkinitfs_functions.sh @@ -17,6 +17,7 @@ deviceinfo_flash_offset_tags="" deviceinfo_flash_pagesize="" deviceinfo_generate_bootimg="" deviceinfo_generate_legacy_uboot_initfs="" +deviceinfo_mesa_driver="" deviceinfo_initfs_compression="" deviceinfo_kernel_cmdline="" deviceinfo_legacy_uboot_load_address="" @@ -225,6 +226,16 @@ get_binaries_extra() /usr/sbin/thd " + if [ -n "$deviceinfo_mesa_driver" ]; then + BINARIES_EXTRA=" + $BINARIES_EXTRA + /usr/lib/libEGL.so.1 + /usr/lib/libgbm.so.1 + /usr/lib/libudev.so.1 + /usr/lib/xorg/modules/dri/${deviceinfo_mesa_driver}_dri.so + " + fi + tmp1=$(mktemp /tmp/mkinitfs.XXXXXX) get_binaries > "$tmp1" tmp2=$(mktemp /tmp/mkinitfs.XXXXXX)