mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-09 19:13:26 +03:00
udevCheckHook: remove broken cross-compilation check
This commit is contained in:
parent
d313d94049
commit
4e690a2899
1 changed files with 6 additions and 5 deletions
|
@ -2,15 +2,16 @@
|
||||||
lib,
|
lib,
|
||||||
makeSetupHook,
|
makeSetupHook,
|
||||||
systemdMinimal,
|
systemdMinimal,
|
||||||
udev,
|
|
||||||
stdenv,
|
stdenv,
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
# udev rules can only be checked if systemd (specifically, 'udevadm') can be executed on build platform
|
# udev rules can only be checked if systemd (specifically, 'udevadm') can be executed on build platform
|
||||||
# if udev is not available on hostPlatform, there is no point in checking rules
|
# If cross-compiling linux -> non-linux, udev rules are still checked, even if they end up being unused.
|
||||||
applyHook =
|
# This is not a problem:
|
||||||
lib.meta.availableOn stdenv.hostPlatform udev
|
# - If there are no udev rules, the hook is a noop
|
||||||
&& lib.meta.availableOn stdenv.buildPlatform systemdMinimal;
|
# - If the udev rules are broken, they should be flagged as such
|
||||||
|
# - if rules are not needed on a target platform where they are broken, they should be deleted from package output
|
||||||
|
applyHook = lib.meta.availableOn stdenv.buildPlatform systemdMinimal;
|
||||||
in
|
in
|
||||||
makeSetupHook {
|
makeSetupHook {
|
||||||
name = "udev-check-hook";
|
name = "udev-check-hook";
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue