code: def dyld_override_search(name, env=None):
      # If DYLD_FRAMEWORK_PATH is set and this dylib_name is a
      # framework name, use the first file that exists in the framework
      # path if any.  If there is none go on to search the DYLD_LIBRARY_PATH
      # if any.
  
      framework = framework_info(name)
  
      if framework is not None:
          for path in dyld_framework_path(env):
              yield os.path.join(path, framework["name"])
  
      # If DYLD_LIBRARY_PATH is set then use the first file that exists
      # in the path.  If none use the original name.
      for path in dyld_library_path(env):
          yield os.path.join(path, os.path.basename(name))
  
file_path: catboost/contrib/tools/python3/src/Lib/ctypes/macholib/dyld.py
imports: import os
  from ctypes.macholib.framework import framework_info
  from ctypes.macholib.dylib import dylib_info
  from itertools import *
label_desc: Use image node_id 8 for calling a global function with example usage: dyld_override_search(name, env) without return types