A screensaver for GNOME that will turn on and off your HDMI-CEC enabled devices using a libcec compatible HDMI-CEC adapter. The application hooks into GNOME's screensaver event and detects when it has been activated/deactivated. All HDMI-CEC signals are broadcasted and are not device specific.
sudo dnf install -y git make libcec-devel glibmm2.68-devel gcc-c++
git clone https://github.com/Lamothe/gnome-cec-screensaver.git
cd gnome-cec-screensaver
make install
This will put the binary in the user's bin directory so it can be run on the command line with gnome-cec-screensaver
and copy the desktop file into the autostart directory so GNOME will run it at startup.
The application will log to the command line as well as .gnome-cec-screensaver.log
in the user's home direcory.
I have only tested this with the USB - CEC Adapter from Pulse-Eight connected to my NVIDIA GPU on Fedora 40.