Ejemplo n.º 1
0
def _mac_platforms(arch):

    # type: (str) -> List[str]

    match = _osx_arch_pat.match(arch)

    if match:

        name, major, minor, actual_arch = match.groups()

        mac_version = (int(major), int(minor))

        arches = [

            # Since we have always only checked that the platform starts

            # with "macosx", for backwards-compatibility we extract the

            # actual prefix provided by the user in case they provided

            # something like "macosxcustom_". It may be good to remove

            # this as undocumented or deprecate it in the future.
            '{}_{}'.format(name, arch[len('macosx_'):])
            for arch in mac_platforms(mac_version, actual_arch)
        ]

    else:

        # arch pattern didn't match (?!)

        arches = [arch]

    return arches
Ejemplo n.º 2
0

def _mac_platforms(arch):
    # type: (str) -> List[str]
    match = _osx_arch_pat.match(arch)
    if match:
        name, major, minor, actual_arch = match.groups()
        mac_version = (int(major), int(minor))
        arches = [
            # Since we have always only checked that the platform starts
            # with "macosx", for backwards-compatibility we extract the
            # actual prefix provided by the user in case they provided
            # something like "macosxcustom_". It may be good to remove
            # this as undocumented or deprecate it in the future.
            '{}_{}'.format(name, arch[len('macosx_'):])
            for arch in mac_platforms(mac_version, actual_arch)
        ]
    else:
        # arch pattern didn't match (?!)
        arches = [arch]
    return arches


def _custom_manylinux_platforms(arch):
    # type: (str) -> List[str]
    arches = [arch]
    arch_prefix, arch_sep, arch_suffix = arch.partition('_')
    if arch_prefix == 'manylinux2014':
        # manylinux1/manylinux2010 wheels run on most manylinux2014 systems
        # with the exception of wheels depending on ncurses. PEP 599 states
        # manylinux1/manylinux2010 wheels should be considered