(env: 'Environment', paths: T.List[Path])
return None
We just check whether the library exists. We can't do a link check
        because the library might have unresolved symbols that require other
        libraries. On macOS we check if the library matches our target
        architecture.
We just check whether the library exists. We can't do a link check
        because the library might have unresolved symbols that require other
        libraries. On macOS we check if the library matches our target
        architecture.
We just check whether the library exists . We can t do a link check because the library might have unresolved symbols that require other libraries . On macOS we check if the library matches our target architecture .
def _get_file_from_list(env: 'Environment', paths: T.List[Path]) -> Path:
        '''
        We just check whether the library exists. We can't do a link check
        because the library might have unresolved symbols that require other
        libraries. On macOS we check if the library matches our target
        architecture.
        '''
        # If not building on macOS for Darwin, do a simple file check
        if not env.machines.host.is_darwin() or not env.machines.build.is_darwin():
            for p in paths:
                if p.is_file():
                    return p
        # Run `lipo` and check if the library supports the arch we want
        for p in paths:
            if not p.is_file():
                continue
            archs = mesonlib.darwin_get_object_archs(str(p))
            if archs and env.machines.host.cpu_family in archs:
                return p
            else:
                mlog.debug(f'Rejected {p}, supports {archs} but need {env.machines.host.cpu_family}')
        return None
def _get_file_from_list ( env : 'Environment' , paths : T . List [ Path ] ) -> Path : # If not building on macOS for Darwin, do a simple file check if not env . machines . host . is_darwin ( ) or not env . machines . build . is_darwin ( ) : for p in paths : if p . is_file ( ) : return p # Run `lipo` and check if the library supports the arch we want for p in paths : if not p . is_file ( ) : continue archs = mesonlib . darwin_get_object_archs ( str ( p ) ) if archs and env . machines . host . cpu_family in archs : return p else : mlog . debug ( f'Rejected {p}, supports {archs} but need {env.machines.host.cpu_family}' ) return None