code: def customize_compiler(compiler):
      """Do any platform-specific customization of a CCompiler instance.
  
      Mainly needed on Unix, so we can plug in the information that
      varies across Unices and is stored in Python's Makefile.
      """
      if compiler.compiler_type == "unix":
          if sys.platform == "darwin":
              # Perform first-time customization of compiler-related
              # config vars on OS X now that we know we need a compiler.
              # This is primarily to support Pythons from binary
              # installers.  The kind and paths to build tools on
              # the user system may vary significantly from the system
              # that Python itself was built on.  Also the user OS
              # version and build tools may not support the same set
              # of CPU architectures for universal builds.
              if not _config_vars.get("CUSTOMIZED_OSX_COMPILER"):
                  import _osx_support
  
                  _osx_support.customize_compiler(_config_vars)
                  _config_vars["CUSTOMIZED_OSX_COMPILER"] = "True"
  
          (
              cc,
              cxx,
              cflags,
              ccshared,
              ldshared,
              shlib_suffix,
              ar,
              ar_flags,
          ) = get_config_vars(
              "CC",
              "CXX",
              "CFLAGS",
              "CCSHARED",
              "LDSHARED",
              "SHLIB_SUFFIX",
              "AR",
              "ARFLAGS",
          )
  
          if "CC" in os.environ:
              newcc = os.environ["CC"]
              if (
                  sys.platform == "darwin"
                  and "LDSHARED" not in os.environ
                  and ldshared.startswith(cc)
              ):
                  # On OS X, if CC is overridden, use that as the default
                  #       command for LDSHARED as well
                  ldshared = newcc + ldshared[len(cc) :]
              cc = newcc
          if "CXX" in os.environ:
              cxx = os.environ["CXX"]
          if "LDSHARED" in os.environ:
              ldshared = os.environ["LDSHARED"]
          if "CPP" in os.environ:
              cpp = os.environ["CPP"]
          else:
              cpp = cc + " -E"  # not always
          if "LDFLAGS" in os.environ:
              ldshared = ldshared + " " + os.environ["LDFLAGS"]
          if "CFLAGS" in os.environ:
              cflags = cflags + " " + os.environ["CFLAGS"]
              ldshared = ldshared + " " + os.environ["CFLAGS"]
          if "CPPFLAGS" in os.environ:
              cpp = cpp + " " + os.environ["CPPFLAGS"]
              cflags = cflags + " " + os.environ["CPPFLAGS"]
              ldshared = ldshared + " " + os.environ["CPPFLAGS"]
          if "AR" in os.environ:
              ar = os.environ["AR"]
          if "ARFLAGS" in os.environ:
              archiver = ar + " " + os.environ["ARFLAGS"]
          else:
              archiver = ar + " " + ar_flags
  
          cc_cmd = cc + " " + cflags
          compiler.set_executables(
              preprocessor=cpp,
              compiler=cc_cmd,
              compiler_so=cc_cmd + " " + ccshared,
              compiler_cxx=cxx,
              linker_so=ldshared,
              linker_exe=cc,
              archiver=archiver,
          )
  
          compiler.shared_lib_extension = shlib_suffix
  
file_path: catboost/contrib/tools/python3/src/Lib/distutils/sysconfig.py
imports: import _imp
  import os
  import re
  import sys
  import warnings
  from functools import partial
  from .errors import DistutilsPlatformError
  from sysconfig import _PREFIX, _BASE_PREFIX, _EXEC_PREFIX, _BASE_EXEC_PREFIX, _PROJECT_BASE, _PYTHON_BUILD, _init_posix, parse_config_h, _init_non_posix, _variable_rx, _findvar1_rx, _findvar2_rx, expand_makefile_vars, is_python_build, get_config_h_filename, get_config_var, get_config_vars, get_makefile_filename, get_python_version
label_desc: Use image node_id 3 for calling a global function with example usage: customize_compiler(compiler) without return types