Skip to content

Add cachyos_setup.sh for DAMX driver setup#135

Closed
scorpionTaj wants to merge 1 commit into
PXDiv:mainfrom
scorpionTaj:patch-1
Closed

Add cachyos_setup.sh for DAMX driver setup#135
scorpionTaj wants to merge 1 commit into
PXDiv:mainfrom
scorpionTaj:patch-1

Conversation

@scorpionTaj
Copy link
Copy Markdown

This script automates the process of building, signing, and installing the DAMX driver for CachyOS. It includes checks for required keys, builds the driver using Clang, signs the driver, and provides installation instructions.

This script automates the process of building, signing, and installing the DAMX driver for CachyOS. It includes checks for required keys, builds the driver using Clang, signs the driver, and provides installation instructions.
Copilot AI review requested due to automatic review settings January 4, 2026 02:39
@scorpionTaj
Copy link
Copy Markdown
Author

Request for Release Inclusion

Could you please also include this script (scripts/cachyos_setup.sh) in the release archives (.tar.xz or .zip) for the next version?

Currently, users downloading the release via the "Releases" tab won't get this script unless they clone the repository manually. Including it in the release package would ensure a seamless experience for CachyOS and Secure Boot users who prefer downloading the stable release.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces a specialized setup script for CachyOS users to build, sign, and install the Linuwu Sense driver with Clang compiler support. The script automates the driver compilation process, handles Secure Boot signature requirements, and provides clear installation instructions for both new installations and driver updates.

Key changes:

  • Automated driver building using Clang/LLD toolchain specific to CachyOS
  • Secure Boot key discovery and driver signing functionality
  • Post-installation guidance for integrating with the main DAMX setup

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
Comment thread scripts/cachyos_setup.sh
@Krak8
Copy link
Copy Markdown

Krak8 commented Jan 13, 2026

Hey @scorpionTaj I am trying to install this on cachyos which has secureboot using sbctl how do I use your script to install this?

@scorpionTaj
Copy link
Copy Markdown
Author

@Krak8 so sorry for being late :-) , you can install the latest release build from the repo and put that script in the driver "Linuwu Sense" directory and then run it like in the screenshot
image

@Krak8
Copy link
Copy Markdown

Krak8 commented Jan 14, 2026

thanks for this

@scorpionTaj
Copy link
Copy Markdown
Author

@Krak8 you are welcome 👍🏼

@Mukilan473
Copy link
Copy Markdown

sorry if I sound dumb but how do I install it I have the AN17-42 model and I have a seperate copy of the driver modified for my laptop (just added quirks with the help from FAQ) I downloaded the script seperately and copied it to the Linuwu-Sense and I get this error ensure sbctl is installed (which I installed) and verify keys are generated the thing is I verified the secure boot key from the bios during installation as the bios doesn't load if it's not a signed os any help is appreciated and sorry for the bad english
~/Documents/DAMX-0.9.1/scripts ❯ ./cachyos_setup.sh 🔒 Root privileges are required to sign drivers. 🔑 Please enter your password to continue... 🔧 Preparing to build for CachyOS... ❌ Error: Secure Boot keys (db.key/db.pem) not found. Ensure you have sbctl installed and keys generated.

@scorpionTaj
Copy link
Copy Markdown
Author

scorpionTaj commented Jan 27, 2026

Troubleshooting the "Keys Not Found" Error

Don't worry, you don't sound dumb at all! Secure Boot on Linux is notoriously tricky. The error happens because the script can't find your db.key and db.pem files, which are needed to sign the driver so your BIOS will trust it.

1. Fix the Script Location

The error in your terminal shows you are running the script from inside the scripts folder:
~/Documents/DAMX-0.9.1/scripts ❯ ./cachyos_setup.sh

Move the script up one level into the main Linuwu-Sense folder. It must be in the same folder as the Makefile and the src folder to work.

2. Verify/Generate your Keys

Even if sbctl is installed, you must ensure the keys actually exist on your system and are enrolled in your BIOS.

Follow the steps in that wiki to create and enroll your keys. Once sbctl status shows that your keys are enrolled and Secure Boot is active, you can proceed.

3. Help the Script find the Keys

Sometimes the script's "search" function misses the sbctl folder. If you have confirmed your keys exist but the script still fails, you can tell it exactly where they are.

Open cachyos_setup.sh in a text editor and change lines 20 and 21 to:

KEY="/var/lib/sbctl/keys/db/db.key"
CERT="/var/lib/sbctl/keys/db/db.pem"
image

4. Run the Script again

Once the keys are ready and the script is in the main folder, run:

sudo ./cachyos_setup.sh

@Mukilan473
Copy link
Copy Markdown

that did the trick thank you friend

@Krak8
Copy link
Copy Markdown

Krak8 commented Jan 28, 2026

this is pretty useful for users with secureboot on !
I will request the author to add this useful script on main repo thx (merge)

@scorpionTaj
Copy link
Copy Markdown
Author

scorpionTaj commented Jan 28, 2026

I’ll be opening a new one shortly to reflect the updated local-setup.sh and the new build process for Secure Boot files across all distributions. this is it #152

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.

4 participants