Skip to content

Instantly share code, notes, and snippets.

@vmpartner
Last active August 25, 2025 23:04
Show Gist options
  • Save vmpartner/b7277956d9c90722c59f1a17805b8f35 to your computer and use it in GitHub Desktop.
Save vmpartner/b7277956d9c90722c59f1a17805b8f35 to your computer and use it in GitHub Desktop.
Ubuntu 24.04 + Wayland - Flameshot not work in Wayland
- Uninstall any flameshot that you installed early
- Add src to /etc/apt/sources.list.d/ubuntu.sources
Types: deb-src
URIs: http://ru.archive.ubuntu.com/ubuntu/
Suites: noble noble-updates
Components: main restricted universe multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
Types: deb-src
URIs: http://security.ubuntu.com/ubuntu/
Suites: noble-security
Components: main restricted universe multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
- Create script for compile flameshot for Wayland, because now it's work only when compiled with flag USE_WAYLAND_CLIPBOARD=true
#!/bin/bash
set -e
rm -rf build
mkdir -p build
cd build
sudo apt install devscripts equivs libkf5guiaddons-dev -y
sudo mk-build-deps -t'apt-get -y' -ir flameshot
apt source flameshot
SRC_DIR=`ls | cut -f1 | head -n1`
pushd ${SRC_DIR}
sed -i 's/-DFLAMESHOT_ABOUT_DEB_VERSION/-DUSE_WAYLAND_CLIPBOARD=1 -DFLAMESHOT_ABOUT_DEB_VERSION/' debian/rules
[email protected] dch -n ''
debuild -i -j -us -uc
popd
sudo apt purge flameshot-build-deps devscripts equivs libkf5guiaddons-dev --auto-remove -y
sudo dpkg -i flameshot_*.deb
rm -rf ../build
- Start your script bash install.sh
- Set Hotkey
sh -c "QT_QPA_PLATFORM=wayland flameshot gui"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment