Skip to content

Add Ubuntu/Debian installer and auto-detection#15

Open
Neil-Lunavat wants to merge 2 commits intoBatuhan4:mainfrom
Neil-Lunavat:ubuntu-support
Open

Add Ubuntu/Debian installer and auto-detection#15
Neil-Lunavat wants to merge 2 commits intoBatuhan4:mainfrom
Neil-Lunavat:ubuntu-support

Conversation

@Neil-Lunavat
Copy link
Copy Markdown

Summary

  • Adds ubuntu-install.sh: a full installer for Ubuntu/Debian-based distros, mirroring the Fedora installer but using apt. Tested on Ubuntu 24.04 LTS with GNOME 46 on an HP Victus 16.
  • install.sh now auto-detects Ubuntu/Debian via /etc/os-release (matching ubuntu, debian, linuxmint, pop) with an apt-get fallback, routing to ubuntu-install.sh.

What the Ubuntu installer does

Same pipeline as fedora-install.sh:

  1. Installs deps via apt-get: meson, ninja-build, libgtk-4-dev, linux-headers-$(uname -r), dkms, g++, git
  2. Creates victus / victus-backend groups and victus-backend system user
  3. Installs helper scripts and sudoers rules
  4. Clones and builds the hp-wmi-fan-and-backlight-control DKMS module
  5. Builds and installs the GTK4 app + backend via meson
  6. Installs udev rules and starts victus-backend.service

Hardware tested

Model OS GNOME Result
HP Victus 16 Ubuntu 24.04 LTS 46.0 ✅ Working

Secure Boot note

Users with Secure Boot enabled must either:

  • Disable Secure Boot in BIOS (simplest), or
  • Enroll the shim MOK key: sudo mokutil --import /var/lib/shim-signed/mok/MOK.der, then reboot and confirm in the MokManager screen

Test plan

  • sudo ./install.sh completes without errors on Ubuntu 24.04
  • systemctl is-active victus-backend.service returns active
  • Fan mode switching works in the GTK app and GNOME extension
  • gnome-extensions enable victus-control@victus enables the panel extension

Neil-Lunavat and others added 2 commits March 23, 2026 22:28
Adds ubuntu-install.sh, a full installer for Ubuntu and Debian-based
distros mirroring the Fedora installer but using apt. Tested on
Ubuntu 24.04 LTS (GNOME 46) with an HP Victus 16.

- install.sh now auto-detects Ubuntu/Debian via /etc/os-release and
  falls back to apt-get detection, routing to ubuntu-install.sh
- Dependencies: meson, ninja-build, libgtk-4-dev, linux-headers-$(uname -r)
- Remaining steps identical to the Fedora path: DKMS, meson build,
  udev rules, systemd services, GNOME extension

Note: Secure Boot users must either disable Secure Boot or enroll the
shim MOK key (mokutil --import /var/lib/shim-signed/mok/MOK.der)
before the DKMS module will load.
@Batuhan4
Copy link
Copy Markdown
Owner

@Neil-Lunavat I pushed a follow-up commit onto this PR branch (c85c135) to address the review blockers.

Changes in that commit:

  • make hp_wmi DKMS detection accept both /extra and /updates/dkms
  • keep the same module-path check consistent in the boot-time healthcheck
  • add sudo to the Ubuntu installer dependency list
  • sync the README with the new Ubuntu/Debian installer path

Can you please re-test on the Ubuntu 24.04 machine you used originally, ideally from a clean state, and confirm these specifically?

  • sudo ./install.sh completes without manual fixes
  • modprobe --show-depends hp_wmi resolves to the DKMS-installed module and install does not fail on /updates/dkms
  • systemctl is-active victus-backend.service is active
  • fan mode switching still works in the GTK app / GNOME extension
  • if Secure Boot is enabled, whether the MOK flow is still the only extra step needed

If you have access to another Debian-based distro as well, one extra smoke test there would help validate the broader auto-detection claim.

@selvatharrun
Copy link
Copy Markdown

Hi @Batuhan4 tried the fix, after u fixed the DKMS detection, and the one before, neither of them worked both resulting in the same error

"""
dkms is already the newest version (3.2.2-1ubuntu1).
g++ is already the newest version (4:15.2.0-5ubuntu1).
sudo is already the newest version (1.9.17p2-1ubuntu3).
linux-headers-7.0.0-15-generic is already the newest version (7.0.0-15.15).
Solving dependencies... Done
The following packages were automatically installed and are no longer required:
linux-headers-7.0.0-14 linux-headers-7.0.0-14-generic linux-image-unsigned-7.0.0-14-generic linux-main-modules-zfs-7.0.0-14-generic linux-modules-7.0.0-14-generic linux-tools-7.0.0-14 linux-tools-7.0.0-14-generic
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
--> Creating secure users and groups...
Group 'victus' already exists.
Group 'victus-backend' already exists.
User 'victus-backend' already exists.
--> Installing helper scripts and sudoers...
--> Installing patched hp-wmi kernel module...
From https://github.com/Batuhan4/hp-wmi-fan-and-backlight-control

  • branch master -> FETCH_HEAD
    HEAD is now at 6368256 docs: expand tested laptop matrix
    Module hp-wmi-fan-and-backlight-control/0.0.2 for kernel 7.0.0-15-generic (x86_64):
    Before uninstall, this module version was ACTIVE on this kernel.
    Deleting /lib/modules/7.0.0-15-generic/updates/dkms/hp-wmi.ko.zst
    Restoring archived original module /lib/modules/7.0.0-15-generic/kernel/drivers/platform/x86/hp/hp-wmi.ko.zst
    Running depmod... done.

Deleting module hp-wmi-fan-and-backlight-control/0.0.2 completely from the DKMS tree.
Creating symlink /var/lib/dkms/hp-wmi-fan-and-backlight-control/0.0.2/source -> /usr/src/hp-wmi-fan-and-backlight-control-0.0.2
Sign command: /usr/bin/kmodsign
Signing key: /var/lib/shim-signed/mok/MOK.priv
Public certificate (MOK): /var/lib/shim-signed/mok/MOK.der

Building module(s)... done.
Signing module /var/lib/dkms/hp-wmi-fan-and-backlight-control/0.0.2/build/hp-wmi.ko
Found pre-existing /lib/modules/7.0.0-15-generic/kernel/drivers/platform/x86/hp/hp-wmi.ko.zst, archiving for uninstallation
Installing /lib/modules/7.0.0-15-generic/updates/dkms/hp-wmi.ko.zst
Running depmod... done.
--> Reloading patched hp-wmi module...
Error: Patched hp_wmi fan target controls are missing under /sys/devices/platform/hp-wmi/hwmon/hwmon6.
Error: Patched hp_wmi fan target controls are missing under /sys/devices/platform/hp-wmi/hwmon/hwmon6.
Error: Patched hp_wmi fan target controls are missing under /sys/devices/platform/hp-wmi/hwmon/hwmon6.
selvatharrun@selvatharrun-Victus-by-HP-Laptop-16-d0xxx:~/victus-control$
"""

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants