git.iko.soy/typeable/nixpkgs
on master help sign in
gpio-tools: init in kernel 5.4

Linux provides some tools to interact with the gpiochip interface (which replaces the deprecated sysfs GPIO interface). Expose these as a package. The tool has not changed much recently, so there is no need to package a version for each kernel.

commit89d3a605e31b5e4efbe1b28b08206da4e75fd689 authorKai Wohlfahrt <kai.wohlfahrt@gmail.com> dateWed 29 Apr 2020, 23:10 (7 years ago) parentd59cc0f
2 files changed+25
pkgs/os-specific/linux/kernel/gpio-utils.nix+24 pkgs/top-level/all-packages.nix+1
pkgs/os-specific/linux/kernel/gpio-utils.nixnew file+24
@@ -0,0 +1,24 @@
1+{ lib, stdenv, linux }:
2+
3+with lib;
4+
5+assert versionAtLeast linux.version "4.6";
6+
7+stdenv.mkDerivation {
8+ name = "gpio-utils-${linux.version}";
9+
10+ inherit (linux) src makeFlags;
11+
12+ preConfigure = ''
13+ cd tools/gpio
14+ '';
15+
16+ separateDebugInfo = true;
17+ installFlags = [ "install" "DESTDIR=$(out)" "bindir=/bin" ];
18+
19+ meta = {
20+ description = "Linux tools to inspect the gpiochip interface";
21+ maintainers = with stdenv.lib.maintainers; [ kwohlfahrt ];
22+ platforms = stdenv.lib.platforms.linux;
23+ };
24+}
pkgs/top-level/all-packages.nix+1
@@ -26468,4 +26468,5 @@ in
2646826468
2646926469 vpsfree-client = callPackage ../tools/virtualization/vpsfree-client {};
2647026470
26471+ gpio-utils = callPackage ../os-specific/linux/kernel/gpio-utils.nix { };
2647126472}