diff options
author | Johannes Frankenau <johannes@frankenau.net> | 2017-07-29 11:35:49 +0200 |
---|---|---|
committer | Johannes Frankenau <johannes@frankenau.net> | 2017-08-27 00:35:47 +0200 |
commit | 9f9039983eb4b79106860cea51ceb8b0a155fa2f (patch) | |
tree | 20c37fdb33cb25083ad77e7639bd8fa1f154c191 /pkgs/tools | |
parent | 776de2556b154484be5a506f756c343d6721d99d (diff) | |
download | nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.tar nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.tar.gz nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.tar.bz2 nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.tar.lz nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.tar.xz nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.tar.zst nixlib-9f9039983eb4b79106860cea51ceb8b0a155fa2f.zip |
ddccontrol: Add desktop entry file for gddccontrol
Diffstat (limited to 'pkgs/tools')
-rw-r--r-- | pkgs/tools/misc/ddccontrol/default.nix | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/pkgs/tools/misc/ddccontrol/default.nix b/pkgs/tools/misc/ddccontrol/default.nix index 26c5a6b21395..fe47009eeb33 100644 --- a/pkgs/tools/misc/ddccontrol/default.nix +++ b/pkgs/tools/misc/ddccontrol/default.nix @@ -1,9 +1,10 @@ { stdenv, fetchurl, autoreconfHook, intltool, perl, perlPackages, libxml2 , pciutils, pkgconfig, gtk2, ddccontrol-db +, makeDesktopItem }: let version = "0.4.2"; in -stdenv.mkDerivation { +stdenv.mkDerivation rec { name = "ddccontrol-${version}"; src = fetchurl { @@ -32,6 +33,24 @@ stdenv.mkDerivation { sed -e "s/chmod 4711/chmod 0711/" -i src/ddcpci/Makefile* ''; + postInstall = '' + mkdir -p $out/share/applications/ + cp $desktopItem/share/applications/* $out/share/applications/ + for entry in $out/share/applications/*.desktop; do + substituteAllInPlace $entry + done + ''; + + desktopItem = makeDesktopItem { + name = "gddccontrol"; + desktopName = "gddccontrol"; + genericName = "DDC/CI control"; + comment = meta.description; + exec = "@out@/bin/gddccontrol"; + icon = "gddccontrol"; + categories = "Settings;HardwareSettings;"; + }; + meta = with stdenv.lib; { description = "A program used to control monitor parameters by software"; homepage = "http://ddccontrol.sourceforge.net/"; |