[Lldb-commits] [lldb] 38edd23 - [lldb] Fix TestAppleSimulatorOSType for older watchOS SDKs
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Fri Mar 26 20:28:49 PDT 2021
Author: Jonas Devlieghere
Date: 2021-03-26T20:28:42-07:00
New Revision: 38edd23b8cbfc46f35bb9071e86bb66c876d371c
URL: https://github.com/llvm/llvm-project/commit/38edd23b8cbfc46f35bb9071e86bb66c876d371c
DIFF: https://github.com/llvm/llvm-project/commit/38edd23b8cbfc46f35bb9071e86bb66c876d371c.diff
LOG: [lldb] Fix TestAppleSimulatorOSType for older watchOS SDKs
Older watchOS SDKs *only* support i386 so we can't use x86_64/arm64
unconditionally.
Added:
Modified:
lldb/test/API/tools/lldb-server/TestAppleSimulatorOSType.py
Removed:
################################################################################
diff --git a/lldb/test/API/tools/lldb-server/TestAppleSimulatorOSType.py b/lldb/test/API/tools/lldb-server/TestAppleSimulatorOSType.py
index c0ec37910534..f44955ac838a 100644
--- a/lldb/test/API/tools/lldb-server/TestAppleSimulatorOSType.py
+++ b/lldb/test/API/tools/lldb-server/TestAppleSimulatorOSType.py
@@ -47,9 +47,17 @@ def check_simulator_ostype(self, sdk, platform_name, arch=platform.machine()):
# Launch the process using simctl
self.assertIsNotNone(deviceUDID)
+
exe_name = 'test_simulator_platform_{}'.format(platform_name)
sdkroot = lldbutil.get_xcode_sdk_root(sdk)
vers = lldbutil.get_xcode_sdk_version(sdk)
+
+ # Older versions of watchOS (<7.0) only support i386
+ if platform_name == 'watchos':
+ from distutils.version import LooseVersion
+ if LooseVersion(vers) < LooseVersion("7.0"):
+ arch = 'i386'
+
triple = '-'.join([arch, 'apple', platform_name + vers, 'simulator'])
version_min = '-m{}-simulator-version-min={}'.format(platform_name, vers)
self.build(
More information about the lldb-commits
mailing list