Commit Graph
100 Commits
Author SHA1 Message Date
Clayton Craft 66fcd0230d main/postmarketos-initramfs: handle reboot/poweroff
Needed in both init stages since they both can call fail_halt_boot.

fixes #4003

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7128
2025-10-05 21:22:40 -04:00
Clayton Craft b4b65df84c main/postmarketos-ui-os-installer: use pmb's shallow clone option
This option was added in pmb 3.6, so the dependency is constrained to
that version and later

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7109>
2025-10-05 02:36:51 +00:00
Clayton Craft 7b710e42f8 temp/petitboot: drop aport
This is now packaged in aports:
https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/90929

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7127>
2025-10-02 08:48:14 -07:00
Clayton Craft 6180adfdf2 temp/iio-sensor-proxy: upgrade to 3.8
I dropped 2 patches that seem to have been merged upstream.
I also updated the pkgver format to follow what we do for other forked
pkgs, so hopefully the upstream compat monitoring thing will detect when
this pkg is out of date again

This adds a new patch to fix #3787

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7099>
2025-10-01 14:46:19 +00:00
Clayton Craft c5ca2e756a kconfigcheck: add 'immutable' category
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6949>
2025-10-01 14:14:05 +02:00
Clayton Craft bde9dca58c ci: apkbuild lint: allow all valid kconfigcheck categories
This only allowed categories that were aliases (and only categories
under those), but stuff like `pmb:kconfigcheck-uefi` was flagged as an
invalid option by the linting.

This change parses aliases AND all categories in the kconfigcheck and
allows those as options.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7101>
2025-10-01 12:11:05 +00:00
Clayton Craft fef14737eb kconfigcheck: use tristate values for options
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7080>
2025-09-30 14:00:12 -07:00
Clayton Craft 3c93972ece apple-mac-aarch64: new device
I chose this device pkg name because it's descriptive, this pkg doesn't
support the 'idevice' things or x86_64 or PPC Macs. I didn't include
"generic" because, while it supports Macbooks, (in theory) Mac Minis
and something called Mac Studio, it's not really *that* generic for Mac
computers AND by having the manufacturer be "Apple" it'll show up in pmb
init under "apple." This will make it more intuitive to find, I think.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7048>
2025-09-30 20:32:09 +00:00
Clayton Craft eddbe346c9 linux-postmarketos-asahi: new aport
Alpine's linux-asahi kernel is missing some config for booting on the
macbook M2, and is missing config for supporting other pmOS features /
kconfig checks. It's easier to maintain this kernel downstream for now
so changes can be made easily to support this hardware and functionality
we need.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7048>
2025-09-30 20:32:09 +00:00
Clayton Craft 95a1a60e4b ci: wiki: support only running for changed devices
The device wiki check currently runs for *all* devices in any given
MR, and can sometimes fail (e.g. if someone edits the wiki for some
unrelated device.) It's not fair to block MRs for devices when the
check fails on unrelated devices. This changes the default behavior to
only run on devices that are changed in the branch. This also adds an
`--all` flag that restores the previous behavior, this could be run on
the pmaports master branch to test general compliance for all devices
without blocking MRs where the check fails for unrelated devices.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7098>
2025-09-29 12:46:33 -07:00
Clayton Craft 2be943f936 main/f0rmz: new aport
This will be used for first boot setup in the initramfs

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7082>
2025-09-26 16:08:24 +00:00
Clayton Craft c4e1b0d448 systemd/systemd-services: add generator to set user for plasma-mobile service
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7057>
2025-09-26 07:35:29 -07:00
Clayton Craft d5fc83b7af systemd/systemd-services: add rtkit sysusers config
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7057>
2025-09-26 07:35:13 -07:00
Clayton Craft 4d97758b44 main/postmarketos-mkinitfs: upgrade to 2.7.0
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7087>
2025-09-26 12:39:46 +00:00
Clayton Craft a7aa4f979b main/postmarketos-install-recommends: upgrade to 0.2
Features:

- Make prompting optional / disabled by default
- Implement shallow initial clone for pmaports
- Support running as root user

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7086>
2025-09-26 07:31:42 +00:00
Clayton Craft 2fe8c34193 ci: lib: check_changed_aports_versions: re-add upstream branch
This was effectively dropped in bc3fb78958, but broke later use of the
'upstream' branch.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6703>
2025-09-25 15:22:07 -07:00
Clayton Craft d752a57ce2 systemd: udev: explicitly depend on kmod-lib
This fixes an issue where the mkosi-generated initrd fails to load udev
because libkmod is not installed when systemd-udevd is installed.

For pmOS installs/initramfs stuff, this change should be a no-op,
libkmod is already pulled in by other things and our initramfs config
includes the library manually.

[ci:skip-build]: already built successfully in CI

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7079>
2025-09-25 16:15:49 +00:00
Clayton Craft 4e6ec748a4 main/postmarketos-ui-cosmic: add cosmic-initial-setup to pmb_recommends
This app/config wizard runs when COSMIC starts for the first time, and
it helpful for guiding folks through configuring the DE.

[ci:skip-vercheck] only changing pmb_recommends

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7067>
2025-09-23 09:56:14 +00:00
Clayton Craft 6485ca2e01 main/postmarketos-ui-os-installer: add support for COSMIC UI
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7054>
2025-09-22 16:04:05 +00:00
Clayton Craft efa6cb6376 main/postmarketos-ui-os-installer: update UI screenshots
This updates the UI pictures/screenshots to use the latest from
https://wiki.postmarketos.org/wiki/Category:Interface

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7055>
2025-09-16 21:31:01 +00:00
Clayton Craft 4f29f7a07e systemd/postmarketos-base-systemd: add missing preset config
The trigger runs `systemctl preset cups.service`, but then if it runs
preset on the other two *afterwards* it will disable them (because no
explicit preset and we default to disable). This helps ensure they're
kept enabled.

The same seems to also happen for NetworkManager-wait-online and the
other things here, leading to them being accidentally disabled.

This also removes cups.service, it should be socket-activatable now that
cups.socket is enabled.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7029>
2025-09-16 13:37:11 -07:00
Clayton Craft 17abfd5b93 main/boot-deploy: upgrade to 0.20.2
- Fix crash from passing empty --header_version arg to mkbootimg

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7046>
2025-09-14 15:35:33 -07:00
Clayton Craft df8113b676 systemd/pipewire: upgade to 1.4.8
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7036>
2025-09-12 16:32:51 +00:00
Clayton Craft ec97533995 systemd/cups: upgrade to 2.4.13
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7036>
2025-09-12 16:32:51 +00:00
Clayton Craft a8f9ec7f58 systemd/systemd-services: add generator for tinydm
Fixes #3897

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6903>
2025-09-12 13:51:17 +02:00
Clayton Craft ce67c46bd4 main/devicepkg-utils: initialize SOURCE_DEVICEINFO_ROOT
Otherwise things that `set -u` (like boot-deploy) fail

[ci:skip-build]: already built successfully in CI

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7028>
2025-09-10 09:18:57 -07:00
Clayton Craft 2a4d4f8b61 systemd/postmarketos-base-systemd: fix handling of added and removed units in trigger
Apparently the eval trick doesn't work for passing vars if the var to
set is the same as the var for the value, in this case the caller of
this function was using `added_paths` and `removed_paths`. Shell scripts
suck.

This was missed in the tests because the unit tests call
trigger_unit_presets directly.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7025>
2025-09-09 17:19:47 +00:00
Clayton Craft aed388ea63 systemd/cups: disable examples / ipptool on all archs
Apparently this fails on other archs when cross compiling, not just
riscv64. I hit it locally when building x86_64 on aarch64. bpo is
hitting it when trying to build aarch64 on x86_64. This is kinda of a
big hammer, but I think we'll be able to drop this cups fork when abuild
systemd split func support is upstreamed, and bpo is currently blocked
trying to build changes to support our effort to upstream that abuild
patch.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7023>
2025-09-09 14:46:02 +00:00
Clayton Craft 21a5b834e6 main/boot-deploy: upgrade to 0.20.1
Fixes a breaking regression in 0.20.0

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7021
[ci:skip-build]: bpo hasn't built an abuild update for all archs, and will take a while to be done
2025-09-08 12:15:47 -07:00
Clayton Craft 2c9a5d2d1c main/boot-deploy: upgade to 0.20.0
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7014

[ci:skip-build]: already built successfully in CI
2025-09-08 08:09:02 -07:00
Clayton Craft ef97fd8c60 systemd/cups: disable examples on riscv64
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892

[ci:skip-build]: already built successfully in CI
2025-09-08 07:33:54 -07:00
Clayton Craft 39922de34e ci/shellcheck: run on pmos-base-systemd's apk trigger
This trigger has a lot going on, so let's make sure it always passes
shellcheck. It's not picked up by the normal search for triggers in this
script because the actual logic for the trigger is broken out from the
.trigger file.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:54 -07:00
Clayton Craft 469aae3436 postmarketos-base-systemd: rework unit preset, reload/restart, and cleanup handling
This reworks the preset, reload/restart, and cleanup handling and moves
it from a (proposed [1]) abuild patch that would generate install
scripts for every -systemd package to a series of commit hooks and
a trigger that would exist in this package. This was made
possible by using `treescan`, which quickly[2] recursively scans
/usr/lib/systemd and allows the commit hook and trigger to diff units
before and after an install or uninstall transaction.

I chose to put the trigger and commit hook in pmos-base-systemd instead
of the systemd package because:

1) It's annoying to have to rebuild systemd just to update the logic in
   this script. Rebuilding this package is MUCH faster (nothing to
   compile)

2) IF the systemd package moves elsewhere (i.e. out of pmaports), it's
   unclear if this preset stuff would follow it, and it's safer for us to
   keep it separate so know it's always being included in pmOS+systemd
   installs. It can always be moved later if we decide to.

More info on how the three situations are handled by this patch:

Presets: Pre-commit hook captures current unit file list (using
treescan) before changes, then the trigger on /usr/lib/systemd/system
captures (using treescan) the state after changes and diffs them. It
picks out only unit files that were added, and runs systemctl preset to
apply any preset config that might exist for them.

Reload/restart: This relies on manual post-upgrade scripts in packages
that need it. post-upgrade scripts should mark units with systemctl
set-property ... Markers=+needs-reload/restart. Actual reload/restart
handled by the existing systemd.trigger that queries these markers...
This is going to be a bit annoying for package maintainers[3], but I
don't think many packages will *need* this. As of today, there are 0
packages explicitly requesting reload/restart on upgrade. This also
means there will be no automatic detection of whether a unit should be
reloaded/restarted. AFAIK Fedora doesn't support this, packages have to
explicitly request a reload or restart.

Cleanup: The pre-commit hook uses treescan to capture systemd unit
directory state before transactions and the trigger identifies removed
units (using treescan + diff). It then finds broken symlinks in
/etc/systemd/ that point to any newly removed unit files from the
transaction, and removes only them.

Benefits:

- Simple abuild patch for -systemd split func

- Uses existing APK mechanisms (commit hooks, triggers). Hooks can see
  before/after transaction state for cleanup.

- Logic updates don't require rebuilding all packages.

Tradeoffs:

- Requires additional per-package complexity to support
  reload/restart functionality.

- Moves unit discovery/parsing for preset and cleanup from build-time to
  runtime (every device does this work vs. once at build)

- Package behavior varies based on installed trigger/hook
  versions rather than being deterministic per package version.

- There's a (tiny) risk of some operations being race-y, e.g. if the
  user is actively enabling/disabling/adding unit files between apk
  running the pre-commit hook and the trigger firing... It seems
  unlikely this will cause issues, but 🤷‍♂️

1. https://gitlab.alpinelinux.org/alpine/abuild/-/merge_requests/394

2. I used hyperfine to measure performance of treescan on my laptop,
with lots of units installed, and it was ~20ms without disk caching

3. A post-upgrade that would mark a unit for reload might look like
this:

```
if [ -d "/run/systemd/system" ]; then
	echo "Marking sshd.service for reload..."
	systemctl set-property sshd.service Markers=+needs-reload
fi
```

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:54 -07:00
Clayton Craft 75d8dc9bd2 ci/testlib: add asserts for string contains/doesn't contain substring
For testing if a given string contains a given subtring, for example
`assert_contains "foo bar bazz" "bar"` would pass,
but `assert_contains "foobar bazz" "bar"` would fail.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:54 -07:00
Clayton Craft 7d84c11c52 ci/testlib: add asserts for file exists/not exists
For testing whether a given file exists or not exists

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:54 -07:00
Clayton Craft 0fab76b942 ci/testlib: add test root dir support
Allows creating (and cleaning up) a new root dir for tests, for tests
that deal with files on disk

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:54 -07:00
Clayton Craft 00a242b4e8 systemd/systemd: don't use old systemd_install_script logic
This also removes an old macro file that was left over from one of the
many previous attempts to integrate preset support...

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:53 -07:00
Clayton Craft e63c70b6e8 Rebuild -systemd subpkgs
These packages were previously built by a WIP abuild patch that added
install scripts to each -systemd subpkg for handling preset application
on install and symlink cleanup on uninstall. This functionality has been
replaced by a trigger/commit hook, so we need to rebuild these packages
to drop the install scripts that were previously generated.

[ci:ignore-count]

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:53 -07:00
Clayton Craft 0318e81fde temp/abuild: build with simple systemd split func patch
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6892
2025-09-08 07:33:53 -07:00
Clayton Craft 668933bec1 linux-postmarketos-qcom-laptop: enable dm-verity, erofs
See:
https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6949

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6948>
2025-08-19 21:32:32 +00:00
Clayton Craft a31e5d40b0 systemd/qemu-binfmt: new aport
This could be folded into aports/qemu.. but I'm not sure if
they'd accept it since the path these install to seems(?) to be
systemd-specific? Once there's -systemd split pkg support in abuild,
then maybe it'll make sense to move this to aports.

fixes #3394

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6950
[ci:skip-build]: already built successfully in CI
2025-08-19 10:34:57 -07:00
Clayton Craft ea6e5010c1 systemd: Don't ship /usr/share/factory
When building immutable images, we'll be putting /etc into
/usr/share/factory, and then using systemd-tmpfiles to symlink all of
that stuff under /etc. When systemd installs into this dir, it leads to
accidentally adding some "example" config to the system's runtime
config, e.g. adding pam config with a comment like this which completely
breaks login/auth for many UIs (Phosh, Plasma Mobile, etc) :

  # You really want to adjust this to your local distribution. If you use this
  # unmodified you are not building systems safely and securely.

I could technically just scrub this dir when building immutable images,
but tbh I can't think of any reason why we'd want to ship this in the
first place.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6915
2025-08-11 12:06:34 -04:00
Clayton Craft 1793892a4c qemu-{aarch64,amd64}: use zstd for initramfs compression
Fixes #3861

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6853
2025-08-08 13:16:05 +02:00
Clayton Craft da5a6ad928 main/postmarketos-mkinitfs: upgade to 2.6.4
Fixes:
  - Fix .zst fallback when including firmware

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6882
[ci:skip-build]: already built successfully in CI
2025-08-04 17:42:49 -07:00
Clayton Craft f55e636267 systemd: enable systemd-import
Used by systemd-sysupdate

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6840
2025-08-04 15:05:09 -04:00
Clayton Craft a8a325d80a systemd: enable sysupdate
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6840
2025-08-04 15:05:09 -04:00
Clayton Craft 35a3e6de05 systemd: enable bless-boot generator
This does a hack to removing the need to build the stuff in src/boot for
enabling bless-boot. Previously I tried to enable bless-boot by adding
-Dbootloader=enable, which would be required without this hack, but
cross-compiling systemd/src/boot failed on 32-bit archs and it seemed
unnecessary to go down that rabbit hole to debug/fix.

Why? Because:

1) It's not actually needed for building the stuff I care about enabling
in this MR (systemd-bless-boot and its generator). These things build
and work just fine without building stuff in src/boot.

2) Even if it worked, we would have to remove the artifacts made
from src/boot and not package them here. They would conflict with the
systemd-boot package in Alpine.

So it seems pointless to waste time fixing some weird cross-compiling
issue for some components that don't actually need to be built to enable
the extra features I want and would be discarded anyways in package()

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6840
2025-08-04 15:05:09 -04:00
Clayton Craft e48304b386 Revert "main/bootchart2: upgrade to 0.14.9_git20220807"
This reverts commit 6a62061056.

see: https://gitlab.postmarketos.org/postmarketOS/build.postmarketos.org/-/issues/164
2025-08-04 10:51:48 -07:00
Clayton Craft 26f0531efb main/postmarketos-mkinitfs: upgrade to 2.6.3
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6878

[ci:skip-build]: already built successfully in CI
2025-08-04 09:54:07 -07:00
Clayton Craft 5ef4d6143a systemd/gdm: add sysuser config
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6851
2025-08-02 00:13:21 -04:00
Clayton Craft 91aa907554 systemd/systemd-services: add sysuser conf for ssh and dnsmasq
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6851
2025-08-02 00:13:18 -04:00
Clayton Craft ff3eeeb4f8 device-asus-s5507q: remove module dropped in 6.16, remove dependency on wifi fw pkg
https://github.com/jhovold/linux/commit/8d3b5f6375466ffcd2cd98a0c84d31295470fe9d#diff-2b7af271e27fb81a02eab66d658da360e3803f8846224ab496d7424e0f54899a

This also drop dependency on wifi firmware pkg, for context see:
https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6709#note_494045

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6709
[ci:skip-build]: already built successfully in CI
2025-07-31 22:38:08 -07:00
Clayton Craft 2c713d1d93 device-postmarketos-trailblazer: remove module dropped in 6.16
https://github.com/jhovold/linux/commit/8d3b5f6375466ffcd2cd98a0c84d31295470fe9d#diff-2b7af271e27fb81a02eab66d658da360e3803f8846224ab496d7424e0f54899a
2025-07-31 22:31:19 -07:00
Clayton Craft 3422ba45dd device-qcom-rbx: remove module dropped in 6.16
https://github.com/jhovold/linux/commit/8d3b5f6375466ffcd2cd98a0c84d31295470fe9d#diff-2b7af271e27fb81a02eab66d658da360e3803f8846224ab496d7424e0f54899a
2025-07-31 22:31:19 -07:00
Clayton Craft c09b0dc4e7 linux-postmarketos-qcom-laptop: upgrade to 6.16
- Enable module for CH34x usb serial converters
- Enable module for VHOST_VSOCK (useful for `mkosi vm`)
2025-07-31 22:31:19 -07:00
Clayton Craft 63d2bc78f5 temp/abuild: update to latest version of -systemd split patch
A few minor changes/refactorings were made from feedback received in
https://gitlab.alpinelinux.org/alpine/abuild/-/merge_requests/394

Signed-off-by: Aster Boese <asterboese@mailbox.org>
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6713
2025-07-27 17:02:45 -04:00
Clayton Craft 1de3ea4e3d Revert "temp/eudev-compat: fork eudev from alpine to build systemd"
This reverts commit 61d0f3de8b.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6797
[ci:skip-build]: already built successfully in CI
2025-07-17 17:58:40 -07:00
Clayton Craft e05f990135 Revert hacks to get systemd to build again
This reverts commit cd60d78ac1.
This reverts commit d1ec69e1f2.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6797
2025-07-17 17:58:08 -07:00
Clayton Craft cd60d78ac1 systemd: add eudev-compat to makedepends
in order to build systemd when systemd-udev pkg is broken in binary repo

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6794
[ci:skip-build]: already built successfully in CI
2025-07-17 17:52:29 -07:00
Clayton Craft 61d0f3de8b temp/eudev-compat: fork eudev from alpine to build systemd
This is temporary, just to fix building systemd

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6794
2025-07-17 17:52:19 -07:00
Clayton Craft d1ec69e1f2 systemd: drop libfido2 dependency
This allows building systemd without pulling in udev, and should be
reverted once systemd is updated in the binary repos...

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6794
2025-07-17 17:04:37 -07:00
Clayton Craft 44688263bd Revert "systemd: provide -dev as elogind-dev"
This commit (and the one before it) seem to have broken building new
images, apk hits a conflict with udevd and systemd-udevd:

  systemd-udevd-257.7-r1:
    conflicts: systemd-257.7-r1[eudev=257.7-r1]
    satisfies: systemd-257.7-r1[systemd-udevd=257.7-r1]
  systemd-257.7-r1:
    conflicts: systemd-udevd-257.7-r1[eudev=257.7-r1]
    satisfies: postmarketos-base-systemd-48-r0[systemd]
               systemd-journald-257.7-r1[so:libsystemd-shared-257.so]
               systemd-logind-257.7-r1[systemd=257.7-r1]
               systemd-logind-257.7-r1[so:libsystemd-shared-257.so]
               systemd-timesyncd-257.7-r1[systemd=257.7-r1]
               systemd-timesyncd-257.7-r1[so:libsystemd-shared-257.so]
               systemd-udevd-257.7-r1[so:libsystemd-shared-257.so]

This reverts commit a6a31b3fe7.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6794
2025-07-17 14:28:20 -07:00
Clayton Craft f10fb45ae5 Revert "systemd: versionize systemd-related provides"
This reverts commit 74f754ecef.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6794
2025-07-17 14:22:23 -07:00
Clayton Craft ac28c52eef main/postmarketos-ui-cosmic: depend on bluez
For working BT out of the box...

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6737
2025-07-05 09:31:45 +09:00
Clayton Craft 68c3ba73f1 linux-postmarketos-qcom-laptop: enable systemd BPF requirements
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6708

[ci:skip-build]: already built successfully in CI
2025-06-30 11:03:15 -07:00
Clayton Craft 682ad68e4c extra-repos/systemd: drop armhf
We currently don't build systemd for armhf anymore. Disable all other
packages in the systemd repo too, as these can't be built without the
systemd dependency.

FWIW all of Phosh, Gnome Mobile and Plasma Mobile already have major
packages not building for armhf so they couldn't be used on this arch
anyway.

Once pmb issue 2618 is resolved, we can re-enable systemd for armhf.

Co-authored-by: Oliver Smith <ollieparanoid@postmarketos.org>
Related to !6637
Fixes #3783
[ci:skip-build], [ci:skip-vercheck]: changing arch= only
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6710
2025-06-29 23:08:38 +02:00
Clayton Craft 0dc0c9f03e soc-qcom: run systemd splitfunc in pulseaudio-systemd subpkg
Just like when defining custom -openrc subpkgs, or prepare funcs, etc,
we *need* to manually the corresponding abuild function or else things
break.

fixes #3781

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6690
[ci:skip-build]: already built successfully in CI
2025-06-20 19:22:57 +02:00
Clayton Craft ed5f3dd73e systemd: disable armhf
This is a workaround for pmb#2618, basically.

To build systemd with BPF support (so things like unpriv. nspawn work),
we have to install linux-stable-dev to get a special header(vmlinux.h).
This kernel (linux-stable) isn't build in Alpine for armhf. Normally
that's not a problem, we could just add linux-stable-dev conditionally
to the makedepends, right? No... not possible until pmb#2618 is fixed.
Given this arch is used by only 3 devices in testing (the rest are in
`downstream` or `archive`), I think it makes sense to disable systemd on
this arch until someone has the motivation to fix the pmb bug.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6637
[ci:skip-build]: already built successfully in CI
2025-06-20 12:37:11 +02:00
Clayton Craft 1c4fd97318 systemd: enable BPF support for unprivileged systemd-nspawn
Partially fixes #3746, kernel options are required for systemd to
correctly enable support for this in systemd-nsresourced at runtime.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6637
2025-06-20 12:37:07 +02:00
Clayton Craft 32b1a6d9b6 systemd/xorg-server: upgrade to 21.1.18
Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6686

[ci:skip-build]: already built successfully in CI
2025-06-20 11:25:02 +02:00
Clayton Craft a9fe11c77f main/postmarketos-base-ui: always install sleep-inhibitor.conf
Installing this config only when elogind/openrc is installed means that
systemd versions of pmOS don't get the fix in !6612

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6682
[ci:skip-build]: already built successfully in CI
2025-06-18 15:22:00 -07:00
Clayton Craft 72c8e7c6c1 main/boot-deploy: upgrade to 0.19.0
Changelog: https://gitlab.postmarketos.org/postmarketOS/boot-deploy/-/tags/0.19.0

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6656
2025-06-15 00:17:35 -07:00
Clayton Craft 8734489c8b kconfigcheck: add UDMABUF to default kconfig
See:
https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6163#note_467983

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6167
[ci:skip-build]: already built successfully in CI
2025-06-13 17:05:24 -07:00
Clayton Craft 34d62b85da systemd: Always install X11 tmpfiles config
This is needed by some(all?) Xwayland implementations too, so don't make
installing it exclusive to having the actual X11 xorg-server installed.

This fixes an issue where Xwayland doesn't work on COSMIC.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6658
[ci:skip-build]: already built successfully in CI
2025-06-13 17:02:32 -07:00
Clayton Craft d336e2f0ef firmware-lenovo-21bx: drop aport
All firmware that this used to provide is now upstream in
linux-firmware 🎉

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6660
[ci:skip-build]: already built successfully in CI
2025-06-13 11:42:00 -07:00
Clayton Craft 2c2e4e8895 device-lenovo-21bx: drop dependency on firmware-lenovo-21bx
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6660
2025-06-13 11:42:00 -07:00
Clayton Craft 9d7f74090c device-lenovo-21bx: use dtbloader, remove bootmac
bootmac is no longer necessary for configuring bluetooth MAC when using
dtbloader.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6603
[ci:skip-build]: already built successfully in CI
2025-06-13 08:51:13 -07:00
Clayton Craft aae0373b2d kconfigcheck: add missing option dependencies
These options are things that other required kconfig depend on, found
when creating a new config from scratch and noticing a few required
kconfig wasn't making it into the final config.

I don't expect this to have any impact on existing kernel packages that
already pass the kconfig check, because they would already need to have
these options enabled.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6641
2025-06-11 23:27:04 +02:00
Clayton Craft 492fead1ce main/postmarketos-base-ui: stop inhibiting sleep/suspend during audio playback
This test is apparently wrong a lot now, so let's disable it. Audio
apps should inhibit sleep/suspend on their own, or worst case you can do
something like `systemd-inhibit <audio app>`.

We still want sleep-inhibitor around for now to inhibit sleep/shutdown
when an SSH client is connected or when apk is running.

Fixes #3745

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6612
[ci:skip-build]: already built successfully in CI
2025-06-10 12:17:36 +02:00
Clayton Craft 7bf6a9da16 systemd/systemd-services: fix zram_swap unit
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6614

[ci:skip-build]: already built successfully in CI
2025-06-09 13:02:30 +02:00
Clayton Craft b524646bde device-generic-x86_64: depend on hwdata
This is useful for having more hardware work OOTB when using
this generic image. On openrc installs, which pulls in eudev-hwids.

Fixes #3744

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6611
[ci:skip-build]: already built successfully in CI
2025-06-09 12:59:14 +02:00
Clayton Craft 832128c3db systemd: fix udevd symlink
On a merged /usr system, this results in a broken symlink since
sbin/udevd is really usr/sbin/udevd, and usr/sbin/../usr/lib/ is not a
real thing. This should have no effect on unmerged /usr systems, since
sbin/../../usr/lib/.... is still a correct (if ugly) path.

It's quite difficult to create a relative symlink for these things
that works reliably on a merged AND unmerged /usr install, so for now
I'm going to make the symlink source path absolute so that we can be
confident it'll work on either type of installation, and we can revisit
making them relative after usr merge is done/deployed on all installs.

Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6598
2025-06-05 15:44:30 +02:00
Clayton Craft d0e480eda1 systemd/systemd-services: add sshd@.service unit
This is inspired by the units shipped by Fedora and Debian:
https://salsa.debian.org/ssh-team/openssh/-/blob/master/debian/systemd/sshd@.service
https://src.fedoraproject.org/rpms/openssh/blob/rawhide/f/sshd%40.service

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6566
[ci:skip-build]: already built successfully in CI
2025-06-04 20:24:35 +02:00
Clayton Craft a3e5f4cda7 systemd/systemd-services: Fix zram_swap unit
This change makes the zram_swap service depend on a deviceinfo being
present in the rootfs (which may not always be the case, e.g. when
building an image with mkosi), and it replaces the ExecStartPre with
a dependency on modprobe@zram.service so that modprobe is only called
once if other services happen to also depend on this module (which is
unlikely, but a nicer way to handle this)

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6566
2025-06-04 20:24:31 +02:00
Clayton Craft 0dabd564d1 systemd/postmarketos-base-systemd: replace pmos-baselayout
Some files overwritten by this package are in pmos-baselayout now

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6565
[ci:skip-build]: already built successfully in CI
2025-06-04 09:09:37 -07:00
Clayton Craft c9790be804 main/postmarketos-base: add -release and -baselayout subpkgs
This splits off two new subpackages in postmarketos-base, allowing for
tools (e.g. mkosi) to build a very small "postmarketOS" rootfs.

postmarketos-base depends on these two new packages, so there should be
no functional change outside of enabling this specific use case.

The versioned replaces is meant to fix installing this new package on
existing installs. In some cases apk installs this package *before*
installing the `postmarketos-base-systemd` update that accompanies this
patch.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6565
2025-06-04 09:09:36 -07:00
Clayton Craft 97b9d77632 main/postmarketos-qemu-common: disable hw cursors on wlroots
This partially works around #2246

This is setting a var specific to wlroots, BUT many UIs use wlroots and some
(phosh) vendor it so adding a single text file with 1 line in it seems better
than having at least 2 extra subpackages (1 for installing if phoc, 1 for
installing if wlroots, and others?)

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6508
Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6508
2025-06-03 12:27:58 +02:00
Clayton Craft 68ed2f96a1 device-qemu-*: depend on postmarketos-qemu-common
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6508
Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6508
2025-06-03 12:27:57 +02:00
Clayton Craft 6272fcbf15 main/postmarketos-qemu-common: new aport
This package contains common config shared between all qemu "devices"

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6508
Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6508
2025-06-03 12:27:57 +02:00
Clayton Craft 5747b80ab1 linux-postmarketos-qcom-laptop: upgrade to 6.15
- Enable boot_delay support (can help with debugging)

Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6414
[ci:skip-build]: already built successfully in CI
2025-06-03 12:08:31 +02:00
Clayton Craft c9c7583282 main/devicepkg-utils: add missing makedepend
pmb is more strict about this

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6583
[ci:skip-build]: already built successfully in CI
2025-06-01 12:46:01 +02:00
Clayton Craft fd96e65267 cross/busybox-static-*: upgrade to 1.37.0-r18 2025-05-29 14:18:10 -07:00
Clayton Craft 2e9e6ddbf9 temp/abuild: upgrade to 3.15.0
APKBUILD was also rebased onto the latest version in aports

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6569
[ci:skip-build]: already built successfully in CI
2025-05-29 21:35:12 +02:00
Clayton Craft 4edb3d9cbc main/postmarketos-base-ui-gnome: add gapless to pmb_recommends
This seems to be a nice, featureful music player to ship by default for
GNOME-based UIs that works well on mobile and desktop

Fixes #3544

[ci:skip-vercheck] pmb_recommends change

Part-of: https://gitlab.postmarketos.org/postmarketos/pmaports/-/merge_requests/6558
2025-05-27 11:50:42 +02:00
Clayton Craft 10f9386920 main/swclock-offset: upgrade to 0.2.6
Small bugfix release, see upstream changelog:
https://gitlab.postmarketos.org/postmarketOS/swclock-offset/-/tags/0.2.6

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6545
[ci:skip-build]: already built successfully in CI
2025-05-24 20:23:39 -07:00
Clayton Craft 891093fd9e linux-wiko-lenny{3,5}: add shared patches to fix build issues
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6542

[ci:skip-build]: already built successfully in CI
2025-05-22 22:59:46 -07:00
Clayton Craft 3b0f9a1b82 systemd/postmarketos-base-systemd: fix issue with locale.conf being ignored
Shells (and DEs!) that set environment from /etc/profile.d will end
up sourcing 20locale.sh from alpine-baselayout. This file will set
`LANG=C.UTF8`, and this will override whatever systemd-localed/systemd
sets LANG to. In other words, locale.conf is effectively ignored. I
hit this issue when debugging why the date in COSMIC was always `M05`
instead of `May`, and why various COSMIC components failed to detect the
locale (because it was set to C.UTF8)

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6535
[ci:skip-build]: already built successfully in CI
2025-05-22 17:10:47 -07:00
Clayton Craft 3592e6dcee main/postmarketos-mkinitfs: upgrade to 2.6.2
Includes an important fix for /usr merged installs

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6539
[ci:skip-build]: already built successfully in CI
2025-05-20 14:33:07 -07:00
Clayton Craft d2631ed229 device-generic-x86_64: depend on systemd-boot-x86
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6506

[ci:skip-build]: already built successfully in CI
2025-05-15 22:48:30 +02:00
Clayton Craft f80528b498 cross/systemd-boot-x86: new aport
fixes #3711

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6506
2025-05-15 22:48:30 +02:00