;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; ;;; 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 . (define-module (gnu packages hardware) #:use-module (gnu packages compression) #:use-module (gnu packages gcc) #:use-module (gnu packages glib) #:use-module (gnu packages libusb) #:use-module (gnu packages linux) #:use-module (gnu packages ncurses) #: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 git-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.8") (source (origin (method url-fetch) (uri (string-append "https://www.ddcutil.com/tarballs/" "ddcutil-" version ".tar.gz")) (sha256 (base32 "13ccxbqgyz4ah9jwbcylnfkgl8j3ida8xd00xkcq4xnfyyv5mg6v")))) (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 ;; Distinct from memtest86, which is obsolete. (define-public memtest86+ (package (name "memtest86+") ;; Update the description when/if UEFI support is released. (version "5.01") (source (origin (method url-fetch) (uri (string-append "https://www.memtest.org/download/5.01/memtest86+-" version ".tar.gz")) (sha256 (base32 "0fch1l55753y6jkk0hj8f6vw4h1kinkn9ysp22dq5g9zjnvjf88l")))) (build-system gnu-build-system) (arguments `(#:system "i686-linux" ; the result runs outside of any OS #:tests? #f ; no way to test this #:phases (modify-phases %standard-phases (delete 'configure) ; no configure script (replace 'build ;; The default 'make all' does wonderful things, like scp(1) a file to ;; 192.168.0.12. Build the bootable images and nothing more. (lambda _ (invoke "make" "memtest" ; ELF executable "memtest.bin"))) ; DOS/MBR boot sector (replace 'install
index c900a055d5..9dd41e832b 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -657,6 +657,51 @@ normally do not detect. The goal is to detect only real errors in the code
(i.e. have zero false positives).")
(license license:gpl3+)))
+(define-public cukinia
+ (package
+ (name "cukinia")
+ (version "0.6.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/savoirfairelinux/cukinia")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1i92b37w8kb0rzkazlnnhjjbh1l1nmk2yrjvar7rpl97i9gn212m"))))
+ (build-system gnu-build-system)
+ (arguments
+ (list
+ ;; The test suite assumes the host system runs systemd, has a root user,
+ ;; among other things (see:
+ ;; https://github.com/savoirfairelinux/cukinia/issues/51).
+ #:tests? #f
+ #:phases
+ #~(modify-phases %standard-phases
+ (delete 'configure) ;no configure script
+ (delete 'build) ;no build system
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "./cukinia" "tests/testcases.conf"))))
+ (replace 'install
+ (lambda _
+ (install-file "cukinia" (string-append #$output "/bin")))))))
+ (home-page "https://github.com/savoirfairelinux/cukinia")
+ (synopsis "Simple on-target system test framework")
+ (description "Cukinia is designed to help GNU/Linux-based embedded
+firmware developers run simple system-level validation tests on their
+firmware. Cukinia integrates well with embedded firmware generation
+frameworks such as Buildroot and Yocto, and can be run manually or by your
+favourite continuous integration framework. Among Cukinia features are:
+@itemize
+@item simple to use
+@item no dependencies other than BusyBox or GNU Coreutils
+@item easy integration with CI/CD pipelines.
+@end itemize")
+ (license (list license:gpl3+ license:asl2.0)))) ;dual license
+
(define-public cxxtest
(package
(name "cxxtest")
)) #:phases (modify-phases %standard-phases (delete 'configure) ; no configure script (add-before 'install 'create-output-directory (lambda* (#:key outputs #:allow-other-keys) ;; 'make install' assumes that sbindir exists. (let* ((out (assoc-ref outputs "out")) (sbin (string-append out "/sbin"))) (mkdir-p sbin) #t)))) #:tests? #f)) ; no test suite (native-inputs `(("unzip" ,unzip))) ;; These registers and the CPUID instruction only exist on (most) x86 chips. (supported-systems (list "i686-linux" "x86_64-linux")) (home-page "https://01.org/msr-tools/") (synopsis "Read and write Model-Specific Registers (@dfn{MSR})") (description "The MSR Tools project provides console utilities to directly access the Model-Specific Registers (@dfn{MSR}s) and CPU ID of Intel-compatible processors: @itemize @item @command{cpuid}: show identification and feature information of any CPU @item @command{rdmsr}: read MSRs from any CPU or all CPUs @item @command{wrmsr}: write to MSRs on any CPU or all CPUs @end itemize These tools can be used to query and modify certain low-level CPU parameters, such as the Turbo Boost ratio and Thermal Design Power (@dfn{TDP}) limits. MSR addresses differ (greatly) between processors, and any such modification can be dangerous and may void your CPU or system board's warranty.") (license license:gpl2))) ; cpuid.c is gpl2, {rd,wr}msr.c are gpl2+ (define-public wavemon (package (name "wavemon") (version "0.9.1") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/uoaerg/wavemon.git") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "109ycwnjjqc2vpnd8b86njfifczlxglnyv4rh2qmbn2i5nw2wryg")))) (build-system gnu-build-system) (arguments `(#:make-flags (list "CC=gcc" ;; Makefile.in (ab)uses $(datadir) as $(docdir). Set it to Guix's ;; standard --docdir since it's only used as such. (string-append "datadir=" (assoc-ref %outputs "out") "/share/doc/" ,name "-" ,version)) #:tests? #f)) ; no tests (native-inputs `(("pkg-config" ,pkg-config))) (inputs `(("libcap" ,libcap) ("libnl" ,libnl) ("ncurses" ,ncurses))) (home-page "https://github.com/uoaerg/wavemon") (synopsis "Wireless network device monitor") (description "Wavemon is a wireless device monitor with an interactive ncurses terminal interface. It can display and plot signal and noise levels in real time. It also reports packet statistics, device configuration, network parameters, and access points and other wireless clients of your wireless network hardware. Wavemon should work (with varying levels of detail and features) with any device supported by the Linux kernel.") ;; Source file headers still say GPL2+, but the authorial intent ;; (from COPYING and the F9 'about' screen) is clearly GPL3+. (license license:gpl3+)))