query
On this page

isCompatible

lib.systems.parse.isCompatible

Docs pulled from | This Revision | 26 minutes ago


Contribute
Enhance the ecosystem with your expertise! Contribute to fill the gaps in documentation. Your input can make a difference.

Noogle detected

Implementation

The following is the current implementation of this function.

a: b:
    b == a
    || any id [
      # x86
      (b == i386 && isCompatible a i486)
      (b == i486 && isCompatible a i586)
      (b == i586 && isCompatible a i686)

      # XXX: Not true in some cases. Like in WSL mode.
      (b == i686 && isCompatible a x86_64)

      # ARMv4
      (b == arm && isCompatible a armv5tel)

      # ARMv5
      (b == armv5tel && isCompatible a armv6l)

      # ARMv6
      (b == armv6m && isCompatible a armv6l)
      (b == armv6l && isCompatible a armv7l)

      # ARMv7
      (b == armv7l && isCompatible a armv7a)
      (b == armv7l && isCompatible a armv7r)
      (b == armv7m && isCompatible a armv7a)
      (b == armv7m && isCompatible a armv7r)

      # ARMv8
      (b == armv8a && isCompatible a aarch64)

      # PowerPC
      (b == powerpc && isCompatible a powerpc64)
      (b == powerpcle && isCompatible a powerpc64le)

      # MIPS
      (b == mips && isCompatible a mips64)
      (b == mipsel && isCompatible a mips64el)

      # SPARC
      (b == sparc && isCompatible a sparc64)
    ]