about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/libwacom/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/libwacom/default.nix')
-rw-r--r--nixpkgs/pkgs/development/libraries/libwacom/default.nix22
1 files changed, 19 insertions, 3 deletions
diff --git a/nixpkgs/pkgs/development/libraries/libwacom/default.nix b/nixpkgs/pkgs/development/libraries/libwacom/default.nix
index 24092d328695..f1f6762bab8c 100644
--- a/nixpkgs/pkgs/development/libraries/libwacom/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libwacom/default.nix
@@ -8,11 +8,12 @@
 , udev
 , libgudev
 , python3
+, valgrind
 }:
 
 stdenv.mkDerivation rec {
   pname = "libwacom";
-  version = "2.4.0";
+  version = "2.6.0";
 
   outputs = [ "out" "dev" ];
 
@@ -20,9 +21,13 @@ stdenv.mkDerivation rec {
     owner = "linuxwacom";
     repo = "libwacom";
     rev = "libwacom-${version}";
-    sha256 = "sha256-9uhnO+MqB7tAnSXjBcJWCzHGiz9izun4nVjFb17G8Gg=";
+    sha256 = "sha256-9zqW6zPrFcxv/yAAtFgdVavKVMXeDBoMP3E/XriUcT0=";
   };
 
+  postPatch = ''
+    patchShebangs test/check-files-in-git.sh
+  '';
+
   nativeBuildInputs = [
     pkg-config
     meson
@@ -36,13 +41,24 @@ stdenv.mkDerivation rec {
     libgudev
   ];
 
+  doCheck = stdenv.hostPlatform == stdenv.buildPlatform && lib.meta.availableOn stdenv.hostPlatform valgrind;
+
   mesonFlags = [
-    "-Dtests=disabled"
+    "-Dtests=${if doCheck then "enabled" else "disabled"}"
   ];
 
+  nativeCheckInputs = [
+    valgrind
+  ] ++ (with python3.pkgs; [
+    libevdev
+    pytest
+    pyudev
+  ]);
+
   meta = with lib; {
     platforms = platforms.linux;
     homepage = "https://linuxwacom.github.io/";
+    changelog = "https://github.com/linuxwacom/libwacom/blob/${src.rev}/NEWS";
     description = "Libraries, configuration, and diagnostic tools for Wacom tablets running under Linux";
     maintainers = teams.freedesktop.members;
     license = licenses.mit;