diff options
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/umockdev/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/umockdev/default.nix | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/nixpkgs/pkgs/development/libraries/umockdev/default.nix b/nixpkgs/pkgs/development/libraries/umockdev/default.nix index 1cae2c62b33c..9c3026b0c9fb 100644 --- a/nixpkgs/pkgs/development/libraries/umockdev/default.nix +++ b/nixpkgs/pkgs/development/libraries/umockdev/default.nix @@ -2,6 +2,7 @@ , lib , docbook-xsl-nons , fetchurl +, fetchpatch , glib , gobject-introspection , gtk-doc @@ -12,7 +13,8 @@ , ninja , pkg-config , python3 -, systemd +, substituteAll +, systemdMinimal , usbutils , vala , which @@ -33,6 +35,20 @@ stdenv.mkDerivation (finalAttrs: { # Hardcode absolute paths to libraries so that consumers # do not need to set LD_LIBRARY_PATH themselves. ./hardcode-paths.patch + + # Replace references to udevadm with an absolute paths, so programs using + # umockdev will just work without having to provide it in their test environment + # $PATH. + (substituteAll { + src = ./substitute-udevadm.patch; + udevadm = "${systemdMinimal}/bin/udevadm"; + }) + + (fetchpatch { + name = "musl.patch"; + url = "https://github.com/martinpitt/umockdev/commit/d4efe24be59bd859b87473ea3d7efe8100bedc74.patch"; + hash = "sha256-whf3p2e7FWN1xk5+HF9KsbMW74DPOQ0R0+FxBfCZTX0="; + }) ]; nativeBuildInputs = [ @@ -49,7 +65,7 @@ stdenv.mkDerivation (finalAttrs: { buildInputs = [ glib - systemd + systemdMinimal libpcap ]; @@ -59,10 +75,12 @@ stdenv.mkDerivation (finalAttrs: { nativeCheckInputs = [ python3 - which usbutils + which ]; + strictDeps = true; + mesonFlags = [ "-Dgtk_doc=true" ]; |