summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--files/monty-python-peril.jpgbin0 -> 49405 bytes
-rw-r--r--posts/index.adoc2
-rw-r--r--posts/librem5:crimson-daily-driver.md133
3 files changed, 134 insertions, 1 deletions
diff --git a/files/monty-python-peril.jpg b/files/monty-python-peril.jpg
new file mode 100644
index 0000000..f686197
--- /dev/null
+++ b/files/monty-python-peril.jpg
Binary files differ
diff --git a/posts/index.adoc b/posts/index.adoc
index 6d6681c..76fe899 100644
--- a/posts/index.adoc
+++ b/posts/index.adoc
@@ -7,6 +7,7 @@ Home
[role="index"]
New Posts
---------
+* link:?p=librem5:crimson-daily-driver[Librem5:Crimson Daily Driver]
* link:?p=linux:switching-from-x11-to-native-wayland[Linux:Switching from X11 to Native Wayland]
* link:?p=librem5-tracker-store-high-cpu[Librem 5:tracker-store High CPU]
* link:?p=Security:Recent_SSH_Brute_Force_Botnet_Attack[Security:Recent SSH Brute Force Botnet Attack]
@@ -19,7 +20,6 @@ New Posts
* link:?p=librem5-timeline[Librem 5:Order Timeline]
* link:?p=benchmark:seagate-backup-plus-5tb[Benchmark:Seagate Backup Plus 5TB]
* link:?p=benchmark:samsung_bar_plus[Benchmark:Samsung Bar Plus 32 GB]
-* link:?p=building_a_reputable_mail_server[Building a Reputable Mail server]
[role="index"]
Purism Librem 5
diff --git a/posts/librem5:crimson-daily-driver.md b/posts/librem5:crimson-daily-driver.md
new file mode 100644
index 0000000..4c38a50
--- /dev/null
+++ b/posts/librem5:crimson-daily-driver.md
@@ -0,0 +1,133 @@
+Librem5: Crimson Daily Driver
+=============================
+
+If you have a Librem 5 phone and are like me, you are eagerly anticipating the
+release of Crimson, because you're stuck on Byzantium which has a super old
+version of just about every package, but most notably, phosh and chatty.
+
+A few weeks ago, I finally decided to try Crimson as a daily driver, and that
+caused me some great headache a couple of times. I am still using it as a daily
+driver however, but there are still some pretty sizeable issues which I have
+accepted for the tie being. The issues:
+
+The issues
+----------
+
+### No camera support yet
+
+Pretty self explanatory here. I imagine this has something to do with the
+libcamera api that is being worked on.
+
+### No SD card support yet
+
+...so if you use your SD card for your home directory, you'll have to rsync to
+internal storage and use that. In my case, I have too much on my card, so I had
+to be selective about what I put on internal storage.
+
+### You can have bluetooth audio, or phone call audio, but not both
+
+Essentially, the current config for _pulseaudio_ doesn't work with bluetooth,
+but audio generally works fine everywhere else. If you try switching to
+_pipewire_, bluetooth audio works mostly well (switching audio outputs has to
+be done manually from the settings), but you won't have any audio, microphone
+or earpiece, on phone calls. This is because of [a
+bug](https://gitlab.com/mobian1/callaudiod/-/issues/35) in _callaudiod_. This
+issue is fixed in version `1.1.10`, but Crimson currently releases with
+`0.1.9`, so pipewire support is broken as of 2024.10.22.
+
+
+### Installing upgrades is too perilous
+
+![Monty Python No, it's too perilous](/files/monty-python-peril.jpg)
+
+This actually isn't strictly true for me anymore. You just have to be diligent
+when installing updates. Currently, the package `libgl1-mesa-dri` wants to
+upgrade `24.2.4-1`, which breaks `phosh`, causing a crash loop. The only way to
+fix it is to plug in a keyboard, `ctrl + alt + f2`, then `sudo apt install -y
+libgl1-mesa-dri=22.3.6-1+deb12u1` to downgrade to `22.3.6-1`. Of course, while
+you're doing this, phosh is continuing to launch and crash every 5 seconds, so
+you have to keep doing the `ctrl + alt + f2` sequence as systemd takes you back
+to `tty1`. `<sarcasm>Isn't systemd great?</sarcasm>`
+
+To avoid the above shenanigans, every time you run `sudo apt upgrade`, _be
+absolutely sure_ to also run `sudo apt install
+libgl1-mesa-dri=22.3.6-1+deb12u1` before you reboot the phone, or you'll end up
+in a crash loop of phosh.
+
+
+I'll update this post with other caveats as they come to me. If you're fine
+with the above issues though,
+
+
+Hacks to get running
+--------------------
+
+Because I want to easily rebuild this phone if I need to, without following a
+long checklist of shell commands, I put all this in a clean shell script which
+handles everything for me/you.
+
+I do recommend putting this in its own directory, as it has to download and
+extract some of its own artifacts (alsa-ucm-conf) to complete.
+
+In short, the following script:
+
+* Overrides the system alsa-ucm-conf ucm2 directories with those from upstream
+ latest.
+
+* Adds a few additional apt repos to bring in "unstable" packages so the phone
+ can actually be updated.
+
+
+**~/crimson/fixup.sh**
+
+```
+#!/usr/bin/env bash
+
+set -euo pipefail
+export IFS=$'\n\t'
+
+# Deploy updated alsa-ucm-conf profiles.
+#
+# Solution discovered by [Kyle Evans]
+# https://source.puri.sm/Librem5/OS-issues/-/issues/346#note_264442)
+#
+fix_alsa_ucm() {
+ local name='alsa-ucm-conf'
+ local version='1.2.12'
+ local src="https://github.com/alsa-project/${name}/archive/refs/tags/v${version}.tar.gz"
+
+ if [ ! -f v${version}.tar.gz ]; then
+ printf 'Downloading %s version %s\n' "${name}" "${version}"
+ curl -o ".v${version}.tar.gz.tmp" -L -# "${src}"
+ mv ".v${version}.tar.gz.tmp" "v${version}.tar.gz"
+ fi
+ tar -xf "v${version}.tar.gz"
+
+ printf 'Deploying updated ucm2 profiles\n'
+ if [ -d /usr/share/alsa/ucm2 ]; then
+ sudo mv -v /usr/share/alsa/ucm2{,.$(date +%F)}
+ fi
+ sudo cp -r "${name}-${version}/ucm2" "/usr/share/alsa/ucm2"
+}
+
+# By default Crimson comes with the crimson repos, which is very broken last I
+# checked.
+# This adds landing, crimson-security, crimson-updates, and
+# crimson-updates-proposed repos. These might make things unstable in the long
+# run, but for now this is required to get things up and running.
+#
+apt_set_repos() {
+ sudo tee /etc/apt/sources.list <<EOF
+deb http://repo.pureos.net/pureos landing main
+deb http://repo.pureos.net/pureos crimson main
+deb http://repo.pureos.net/pureos crimson-security main
+deb http://repo.pureos.net/pureos crimson-updates main
+deb http://repo.pureos.net/pureos crimson-updates-proposed main
+EOF
+}
+
+fix_alsa_ucm
+apt_set_repos
+```
+
+Run that and most of the issues should be resolved.

Generated by cgit