aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorTobias Geerinckx-Rice <me@tobias.gr>2018-08-30 16:53:24 +0200
committerTobias Geerinckx-Rice <me@tobias.gr>2018-08-30 19:28:10 +0200
commitaadd1d241cc9891a857dda9a5cf8389673b3c76c (patch)
treeb29923b4144a226dd2552bd30cda53cab766aa19 /gnu
parent7693f678d1de222e47af6b34ce62c41ea69934c8 (diff)
downloadguix-aadd1d241cc9891a857dda9a5cf8389673b3c76c.tar
guix-aadd1d241cc9891a857dda9a5cf8389673b3c76c.tar.gz
gnu: Add ddcutil.
* gnu/packages/hardware.scm: New file. (ddcutil): New public variable. * gnu/local.mk (GNU_SYSTEM_MODULES): Add the new file.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/hardware.scm75
2 files changed, 76 insertions, 0 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 7b980b2f20..3b92a7ac0e 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -213,6 +213,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/guile-wm.scm \
%D%/packages/gv.scm \
%D%/packages/gxmessage.scm \
+ %D%/packages/hardware.scm \
%D%/packages/haskell.scm \
%D%/packages/haskell-check.scm \
%D%/packages/haskell-crypto.scm \
diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm
new file mode 100644
index 0000000000..d3a99af358
--- /dev/null
+++ b/gnu/packages/hardware.scm
@@ -0,0 +1,75 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages hardware)
+ #:use-module (gnu packages compression)
+ #:use-module (gnu packages glib)
+ #:use-module (gnu packages libusb)
+ #:use-module (gnu packages linux)
+ #:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages xdisorg)
+ #:use-module (gnu packages xorg)
+ #:use-module (guix build-system gnu)
+ #:use-module (guix download)
+ #:use-module ((guix licenses) #:prefix license:)
+ #:use-module (guix packages))
+
+;; This is a module for packages related to physical hardware that don't (yet)
+;; have a more specific home like gps.scm, security-token.scm, &c.
+
+(define-public ddcutil
+ (package
+ (name "ddcutil")
+ (version "0.9.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.ddcutil.com/tarballs/"
+ name "-" version ".tar.gz"))
+ (sha256
+ (base32 "1b4bm3zhk5vnad6fxf0mn8nrlj3fngifl7nzxgxw0n56hlv7ccv0"))))
+ (build-system gnu-build-system)
+ (native-inputs
+ `(("pkg-config" ,pkg-config)))
+ (inputs
+ `(("eudev" ,eudev)
+ ("glib" ,glib)
+ ("libdrm" ,libdrm) ; enhanced diagnostics
+ ("libusb" ,libusb) ; support USB monitors
+ ("libx11" ,libx11) ; enhanced diagnostics
+ ("libxrandr" ,libxrandr)
+ ("zlib" ,zlib)))
+ (home-page "https://www.ddcutil.com/")
+ (synopsis "Control external monitor settings")
+ (description
+ "ddcutil can query and modify most external monitors' settings, such as
+brightness, colour levels, and input sources. Generally speaking, any setting
+that can be changed by pressing buttons on the monitor can be modified by
+ddcutil.
+
+ddcutil communicates directly with monitors implementing the Monitor Control
+Command Set (@dfn{MCCS}). It usually does so through the the Display Data
+Channel Command Interface (@dfn{DDC/CI}) protocol on the I2C bus, but can also
+communicate over USB as per the USB Monitor Control Class Specification.
+
+One particular use case is in colour profile management. Monitor calibration
+is relative to the monitor colour settings currently in effect, e.g. red gain.
+ddcutil allows colour-related settings to be saved at the time a monitor is
+calibrated, and restored when the calibration is applied.")
+ (license (list license:bsd-3 ; FindDDCUtil.cmake
+ license:gpl2+)))) ; everything else