From e259e5f420cca938023ac1066108aeefa533607b Mon Sep 17 00:00:00 2001 From: Daniele Debernardi Date: Wed, 31 Jul 2019 01:25:27 +0200 Subject: [PATCH] device-nokia-n900: various improvements (!534) - rename 'ch-de' keymap to 'ch' as in X keyboard config file - add PMOS_NO_OUTPUT_REDIRECT to kernel cmdline (fixes debug-shell) - add all keymap files in initramfs - load default us keymap in initramfs --- .../device-nokia-n900/10-initfs-keymap.files | 3 ++ device/device-nokia-n900/10-initfs-keymap.sh | 4 +++ device/device-nokia-n900/APKBUILD | 28 ++++++++++++------- device/device-nokia-n900/deviceinfo | 2 +- .../keymaps/{rx51_ch-de.map => rx51_ch.map} | 0 device/device-nokia-n900/uboot-script.cmd | 2 +- 6 files changed, 27 insertions(+), 12 deletions(-) create mode 100644 device/device-nokia-n900/10-initfs-keymap.files create mode 100644 device/device-nokia-n900/10-initfs-keymap.sh rename device/device-nokia-n900/keymaps/{rx51_ch-de.map => rx51_ch.map} (100%) diff --git a/device/device-nokia-n900/10-initfs-keymap.files b/device/device-nokia-n900/10-initfs-keymap.files new file mode 100644 index 000000000..afcbda354 --- /dev/null +++ b/device/device-nokia-n900/10-initfs-keymap.files @@ -0,0 +1,3 @@ +/usr/share/bkeymaps/us/rx51_us.bmap.gz +/usr/share/bkeymaps/ch/rx51_ch.bmap.gz +/usr/share/bkeymaps/it/rx51_it.bmap.gz diff --git a/device/device-nokia-n900/10-initfs-keymap.sh b/device/device-nokia-n900/10-initfs-keymap.sh new file mode 100644 index 000000000..8b5496af0 --- /dev/null +++ b/device/device-nokia-n900/10-initfs-keymap.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +echo "Loading keymap..." +gunzip -c /usr/share/bkeymaps/us/rx51_us.bmap.gz | loadkmap diff --git a/device/device-nokia-n900/APKBUILD b/device/device-nokia-n900/APKBUILD index cae829a74..3a1e5b18f 100644 --- a/device/device-nokia-n900/APKBUILD +++ b/device/device-nokia-n900/APKBUILD @@ -1,6 +1,6 @@ pkgname=device-nokia-n900 pkgver=4 -pkgrel=6 +pkgrel=7 pkgdesc="Nokia N900" url="https://postmarketos.org" arch="armv7" @@ -23,7 +23,7 @@ source=" acpi_handler.sh acpi.map keymaps/rx51_us.map - keymaps/rx51_ch-de.map + keymaps/rx51_ch.map keymaps/rx51_it.map keymaps/40-xkb.conf pointercal @@ -36,6 +36,8 @@ source=" i3wm/protip_shell.sh xorg.conf 10-noroot-suspend + 10-initfs-keymap.files + 10-initfs-keymap.sh " options="!check !archcheck" @@ -44,8 +46,8 @@ build() { mkdir "$srcdir"/keymaps loadkeys -b "$srcdir"/rx51_us.map > "$srcdir"/keymaps/rx51_us.bmap gzip "$srcdir"/keymaps/rx51_us.bmap - loadkeys -b "$srcdir"/rx51_ch-de.map > "$srcdir"/keymaps/rx51_ch-de.bmap - gzip "$srcdir"/keymaps/rx51_ch-de.bmap + loadkeys -b "$srcdir"/rx51_ch.map > "$srcdir"/keymaps/rx51_ch.bmap + gzip "$srcdir"/keymaps/rx51_ch.bmap loadkeys -b "$srcdir"/rx51_it.map > "$srcdir"/keymaps/rx51_it.bmap gzip "$srcdir"/keymaps/rx51_it.bmap return 0 @@ -62,6 +64,10 @@ package() { "$pkgdir"/etc/pointercal install -D -m644 "$srcdir"/asound.state \ "$pkgdir"/var/lib/alsa/asound.state + install -Dm644 "$srcdir"/10-initfs-keymap.files \ + "$pkgdir"/etc/postmarketos-mkinitfs/files/10-initfs-keymap.files + install -Dm644 "$srcdir"/10-initfs-keymap.sh \ + "$pkgdir"/etc/postmarketos-mkinitfs/hooks/10-initfs-keymap.sh # Udev rules install -D -m644 "$srcdir"/90-touchscreen-dev.rules \ @@ -79,8 +85,8 @@ package() { # Keymap install -D -m644 "$srcdir"/keymaps/rx51_us.bmap.gz \ "$pkgdir"/usr/share/bkeymaps/us/rx51_us.bmap.gz - install -D -m644 "$srcdir"/keymaps/rx51_ch-de.bmap.gz \ - "$pkgdir"/usr/share/bkeymaps/ch/rx51_ch-de.bmap.gz + install -D -m644 "$srcdir"/keymaps/rx51_ch.bmap.gz \ + "$pkgdir"/usr/share/bkeymaps/ch/rx51_ch.bmap.gz install -D -m644 "$srcdir"/keymaps/rx51_it.bmap.gz \ "$pkgdir"/usr/share/bkeymaps/it/rx51_it.bmap.gz } @@ -122,15 +128,15 @@ nonfree_firmware() { mkdir "$subpkgdir" } -sha512sums="8c5dc7bb9c3d5c8b1128689493789200f4e3eb434ef9827eca3be306109f5853ebde8bd6730ae55c6075613ec430c2fc10f3f3f565a02b5058fc00882ebc2502 deviceinfo -8f5b68b86f5345698114a2d70fd174699e5729f6c157659e4e57bef1dcab8c1209c13b30df6f5c2e8f31fee077039ffbc7817ca201f0745467b693e7550eaf6b uboot-script.cmd +sha512sums="36bb56878b94eebd21313aba0357365e1026b2264d2a0e02473e3caad65eff6b5e1ac3dc5bf19b8d7c8762bff9dad32fdf3b7f9dfc642d5a5bc2607e4b92fca3 deviceinfo +1558d02269b011e42e1d3969215b9dbd73658ffbf6ddb38c05f55915c0ff890306a2f56bb8155c825a430cad1e98f887475a40d9c2ae40b1892f964e1d395843 uboot-script.cmd 3d55e34b95791636e44a5f41754f3d0de039dbba41f7a556d43a95c9e64afcfa930046b4b96b40020b6f196096ffba93514682927e32fa4488686fdd19c6da5a backlight-enable.sh c6012aef28b096141b924fced226ec99fb93eb53b69c064a8887d8fecdf8dc08a3ba3db399e18d88374c6ef4c59013a30699c7e4d76e5cb771040582573a0527 90-touchscreen-dev.rules 9e72035c88632d12895534e5aa5746f2c130c7dcdafa8702748d62b71ed0e1b5911b6e1f07f9b9e39b6072bbb662f66aead585baa1dcacb7d8c8953ca89b6762 10-nokia-modem.rules df5dcae9a32d04ba2fed8b4dbb8722f8d56d063a288dfbaeca37806bdbb8ba4de639b392859b9f24040a1032456d5dcd754f51314e3ab66515b91ae1e03c93a7 acpi_handler.sh 7761aec6e6e219245b006e7bdc1d19812e9c5915cf3e64bb3dd46bb4b5570c1715650b53a1fc1007cb814076b5d81be0a66ba7ebf06d9a1fa4e364725c3ee633 acpi.map c9ff8b5968fe94007e1139db5ae76f3ee6c214356bff297b9672276c6adb332ba2342b6ca54cf7992d6556f3c68a13ef49ae5e61abe86154935514034170e228 rx51_us.map -dc585e11bf4e06e36c5c62bcc024eaacecc30437d9da5257df14be05e247a2f2bc208874be3058edc6f87cc2877da2ecafd2f627d9b465d4fd24475fc21fdc71 rx51_ch-de.map +dc585e11bf4e06e36c5c62bcc024eaacecc30437d9da5257df14be05e247a2f2bc208874be3058edc6f87cc2877da2ecafd2f627d9b465d4fd24475fc21fdc71 rx51_ch.map 082a5166e38296b097e873b0b4aeaf007e594d3bf4470c74e91ee3efedcf28ad25cd55c23dd63e460339898ae08e77e111b0e1092fa5e661db90bb40732103a1 rx51_it.map 181187db6d88b872233f594759373f32fd08065ee340b60f0c3ff06396d99f4b1250192d70a054fcc9e51e067f6cc063c62b7d8dfff3427b292f1d0c766db206 40-xkb.conf 143c21f0b18a016d37cb44178e9daea09f128a90769b48353c03c3f245cb9b1f7e773b9ccee084973fc78ddd7a18c2642e54888a85bda7c7daecddc9a8c62eff pointercal @@ -142,4 +148,6 @@ e2c6d818c61398af56fd2245639ecb0d528a7ec78951eb3ab1745f62f118884a09eb96b382c50c2f 3bed8554400d6bbebf7e61b14f347a0f3e24b29be296c56fc829ed655cf67fa547c09bb715589b716d6c3f04492e9f3a12473dce6c7151bc15562b9d102bac2f i3status.conf 0b80af9fd1f36e6bc06bdfdf48352897234ac7457210649016665da8570a5a64b8a0841b4fbeb64fd7054a5246a64718cf4412f8a53024ce39b28a80984972d8 protip_shell.sh a91f98daa60efa2beb2ff6b405097f92edca5f1bbb9e7675499139be52ca2570712f8f06f9032ef29f636f99c8f8da8b992f746eab6424aac04260c16158bcc2 xorg.conf -38ecdf876b5aa9df2e5ea61c7ebb6f9ca871bdf433029808d028d563dfd740232b3dc21dba098a7622453212af1272e2e782be861b4a96a49fd475a618442d45 10-noroot-suspend" +38ecdf876b5aa9df2e5ea61c7ebb6f9ca871bdf433029808d028d563dfd740232b3dc21dba098a7622453212af1272e2e782be861b4a96a49fd475a618442d45 10-noroot-suspend +ae5c4c2452d8da66174d4eef9644796b29b0188ad683a6516be3710e0893db5447583f8b46ec9b76144e030c1ce4d9c316542af25b9369d9f27b8c026f6e0fe1 10-initfs-keymap.files +4656d3b3ced0a86e2d6315c89322899f646a689e9cb64609aa8ad5a676b23d93706d8a37f3be6f6b12c6b1e8501b7d26ecafecf27322333850513a6805c61910 10-initfs-keymap.sh" diff --git a/device/device-nokia-n900/deviceinfo b/device/device-nokia-n900/deviceinfo index 645355db4..42c3b5abd 100644 --- a/device/device-nokia-n900/deviceinfo +++ b/device/device-nokia-n900/deviceinfo @@ -7,7 +7,7 @@ deviceinfo_manufacturer="Nokia" deviceinfo_codename="nokia-n900" deviceinfo_date="" deviceinfo_keyboard="true" -deviceinfo_keymaps="us/rx51_us ch/rx51_ch-de it/rx51_it" +deviceinfo_keymaps="us/rx51_us ch/rx51_ch it/rx51_it" deviceinfo_nonfree="????" deviceinfo_dtb="omap3-n900" deviceinfo_append_dtb="true" diff --git a/device/device-nokia-n900/keymaps/rx51_ch-de.map b/device/device-nokia-n900/keymaps/rx51_ch.map similarity index 100% rename from device/device-nokia-n900/keymaps/rx51_ch-de.map rename to device/device-nokia-n900/keymaps/rx51_ch.map diff --git a/device/device-nokia-n900/uboot-script.cmd b/device/device-nokia-n900/uboot-script.cmd index 15796fddb..71df7f7bb 100644 --- a/device/device-nokia-n900/uboot-script.cmd +++ b/device/device-nokia-n900/uboot-script.cmd @@ -2,7 +2,7 @@ setenv mmcnum 0 setenv mmcpart 1 setenv mmctype ext2 setenv setup_omap_atag 1 -setenv bootargs init=/init.sh rw console=tty0 console=tty02 +setenv bootargs init=/init.sh rw console=tty0 console=tty02 PMOS_NO_OUTPUT_REDIRECT setenv mmckernfile /uImage-postmarketos-stable setenv mmcinitrdfile /uInitrd-postmarketos-stable setenv mmcscriptfile