mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-06-05 21:03:40 +00:00
lib.systems.parse: check if cpus are equal first
Rather than doing this last, we do it first. Saves a little time if we're comparing to an identical platform
This commit is contained in:
@@ -444,7 +444,8 @@ rec {
|
||||
isCompatible =
|
||||
with cpuTypes;
|
||||
a: b:
|
||||
any id [
|
||||
b == a
|
||||
|| any id [
|
||||
# x86
|
||||
(b == i386 && isCompatible a i486)
|
||||
(b == i486 && isCompatible a i586)
|
||||
@@ -482,9 +483,6 @@ rec {
|
||||
|
||||
# SPARC
|
||||
(b == sparc && isCompatible a sparc64)
|
||||
|
||||
# identity
|
||||
(b == a)
|
||||
];
|
||||
|
||||
################################################################################
|
||||
|
||||
Reference in New Issue
Block a user