aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHaibo Huang <hhb@google.com>2021-02-04 23:47:50 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2021-02-04 23:47:50 +0000
commit11791cdff14922c6adb8b1124924a40281fb6e62 (patch)
tree2c508a8eb9e848cd1a33875aef900f1a977bcfb2
parent30958c7a8ecb68d0d5327eb592e8589bf58d6a25 (diff)
parent331d20b337f1e2d7980ebe0304468d3fc85cbc0f (diff)
downloadcpython3-11791cdff14922c6adb8b1124924a40281fb6e62.tar.gz
[kokoro python] Debugging logging am: 331d20b337
Original change: https://android-review.googlesource.com/c/platform/external/python/cpython3/+/1576746 MUST ONLY BE SUBMITTED BY AUTOMERGER Change-Id: I55d3235ee8a8cbacf55ebdb0257fad47965f0033
-rw-r--r--Lib/_osx_support.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/Lib/_osx_support.py b/Lib/_osx_support.py
index 37975fe8a3..140718dfb3 100644
--- a/Lib/_osx_support.py
+++ b/Lib/_osx_support.py
@@ -156,9 +156,9 @@ def _default_sysroot(cc):
if _cache_default_sysroot is not None:
return _cache_default_sysroot
-
+
contents = _read_output('%s -c -E -v - </dev/null' % (cc,), True)
- in_incdirs = False
+ in_incdirs = False
for line in contents.splitlines():
if line.startswith("#include <...>"):
in_incdirs = True
@@ -376,6 +376,9 @@ def compiler_fixup(compiler_so, cc_args):
stripArch = '-arch' in cc_args
stripSysroot = any(arg for arg in cc_args if arg.startswith('-isysroot'))
+ print("=====stripArch: " + repr(stripArch))
+ print("=====stripSysroot: " + repr(stripSysroot))
+ print("=====compiler_so1: " + repr(compiler_so))
if stripArch or 'ARCHFLAGS' in os.environ:
while True:
try:
@@ -391,11 +394,12 @@ def compiler_fixup(compiler_so, cc_args):
if compiler_so[idx] == '-arch' and compiler_so[idx+1] == "arm64":
del compiler_so[idx:idx+2]
+ print("=====compiler_so2: " + repr(compiler_so))
if 'ARCHFLAGS' in os.environ and not stripArch:
# User specified different -arch flags in the environ,
# see also distutils.sysconfig
compiler_so = compiler_so + os.environ['ARCHFLAGS'].split()
-
+ print("=====compiler_so3: " + repr(compiler_so))
if stripSysroot:
while True:
indices = [i for i,x in enumerate(compiler_so) if x.startswith('-isysroot')]
@@ -408,7 +412,7 @@ def compiler_fixup(compiler_so, cc_args):
else:
# It's '-isysroot/some/path' in one arg
del compiler_so[index:index+1]
-
+ print("=====compiler_so4: " + repr(compiler_so))
# Check if the SDK that is used during compilation actually exists,
# the universal build requires the usage of a universal SDK and not all
# users have that installed by default.