debian/control: add Depends on pipewire-pulse | pulseaudio
Without pulseaudio installed, starting a container fails with:
lxc-start: waydroid: ../src/lxc/utils.c: safe_mount: 1220 No such file or directory - Failed to mount "/tmp/sway/pulse/native" onto "/usr/lib/x86_64-linux-gnu/lxc/rootfs/run/xdg/pulse/native"
lxc-start: waydroid: ../src/lxc/conf.c: mount_entry: 2442 No such file or directory - Failed to mount "/tmp/sway/pulse/native" on "/usr/lib/x86_64-linux-gnu/lxc/rootfs/run/xdg/pulse/native"
waydroid init downloads from https URLs like
https://ota.waydro.id/system/lineage/waydroid_arm64/VANILLA.json which
will fail like this if the package ca-certificates is not installed:
ERROR: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c: 1029)>
The default behaviour for libdbus is to exit(1) on bus disconnect, which would
leave the container running in the background with Android bootlooping while
trying to establish a Wayland connection again.
Intercept the disconnect signal and gracefully stop the container instead.
Now that only the container manager can write to the log file, traces that were
previously being written by other commands no longer appear in the log file.
Add some logging to the session handling so that we still see these traces in
the log file.
* Update all desktop files on Android startup
* Remove non-existing applications on Android startup
* Preserve user comments and translations
* Preserve user modifications to Categories and Actions
* Preserve user modifications to NoDisplay
* Default system applications to NoDisplay=true
Mesa has been supporting GLES 3.2 forever.
Swiftshader in Android 11 does not, but it also did not support GLES 3.1;
starting from A13 swiftshader will be supporting GLES 3.2 too, thanks to ANGLE.
shell: Import CLASSPATH env that was generated by Android
The *CLASSPATH* environment variables change with every Android version.
We can get the correct values by peeking at /data/system/environ/classpath
inside the container, where Android has dumped the values we need.
Keep a static BOOTCLASSPATH value from Android 11 as a fallback.
Joey Riches [Fri, 23 May 2025 22:26:19 +0000 (23:26 +0100)]
data: Add a valid registered category to Waydroid.desktop for appstream
```
$ appstreamcli compose waydroid-install-prefix/
Automatically selected 'install/' as data output location.
WARNING: Metadata origin not set, using 'example'
Processing directory: install/
Composing metadata...
Run failed, some data was ignored.
Errors were raised during this compose run:
id.waydro.waydroid
E: no-valid-category
Refer to the generated issue report data for details on the individual problems.
```
This fixes composing waydroid into a catalog when using appstream.
Without it waydroid will fail to be included in the catalog for distros
that use `appstream-generator`.
Jami Kettunen [Fri, 23 May 2025 13:53:21 +0000 (16:53 +0300)]
arch: Separately identify arm64_only CPUs without AArch32 support
More and more modern AArch64 SoCs present both in computers and phones
can no longer run normal arm64 image builds which (currently anyway)
also ship various amounts of 32-bit executables that cannot be natively
executed; thus let's target an upcoming arm64_only OTA channel instead.
glob() returns results in an arbitrary order, making the getDriNode()
unpredictable.
The lower-numbered render node has a high chance of being the one used by the
compositor, which avoids possible issues when using DMA-BUFs from another GPU,
so let's default to that.
The previous string was wrong because we are not detecting the
presence of image files, but whether waydroid was initialized with
preinstalled images or with OTA images.
Jami Kettunen [Thu, 28 Dec 2023 13:22:53 +0000 (15:22 +0200)]
Make adb auto-connection opt-out
Just because you have ADB installed (for e.g. physical Android device
development) doesn't mean you necessarily want Waydroid to always also
get automatically connected, allow disabling this functionality.
HALIUM devices may use bind-mounts to override libraries over the
prebuild read-only vendor image. We want to keep those overrides
in our /vendor_extra mount.
user_manager: Respect user umask and use less code
chmod(0o644) is no longer necessary after umask(0) removal in da4772c4e54467920d642e2a792c5d16d3b7bf33 ("tools: Remove umask 0")
as the default umask is 0o022, but if the umask is stricter (e.g.
0o027), then the user would expect the created files to be 0o640.
Creating the directory with the correct mode already also avoids
potential race conditions on systems with insufficient umask.
While at it, also use templating strings for .desktop file creation to
simplify the logic and split the template from the actual code a bit.
Alfred Neumayer [Tue, 29 Aug 2023 19:22:21 +0000 (21:22 +0200)]
container_manager: Keep schedtune cgroup around in case nesting is supported
Certain devices with Ubunutu Touch make use of the schedtune cgroup boosting mechanism,
allowing for better performance system-wide with very little tweaking.
Some devices have trouble using this cgroup in a regular GNU/Linux setting because
their kernels are not carrying the necessary kernel patch for enabling nesting. [1]
To please both those that want Waydroid to stop dropping their performance as well as
those having unpatched kernels, probe the capability to nest schedtune cgroups.