This revision was automatically updated to reflect the committed changes. JDevlieghere marked an inline comment as done. Closed by commit rG2c350730ca8b: [lldb] The os and version are not separate components in the triple (authored by JDevlieghere). Herald added a project: LLDB.
Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112676/new/ https://reviews.llvm.org/D112676 Files: lldb/packages/Python/lldbsuite/test/builders/darwin.py Index: lldb/packages/Python/lldbsuite/test/builders/darwin.py =================================================================== --- lldb/packages/Python/lldbsuite/test/builders/darwin.py +++ lldb/packages/Python/lldbsuite/test/builders/darwin.py @@ -54,13 +54,20 @@ return vendor, os, version, env +def get_triple_str(arch, vendor, os, version, env): + if None in [arch, vendor, os, version, env]: + return None + + component = [arch, vendor, os + version] + if env: + components.append(env) + return '-'.join(component) + + class BuilderDarwin(Builder): def getTriple(self, arch): vendor, os, version, env = get_triple() - components = [arch, vendor, os, version, env] - if None in components: - return None - return '-'.join(components) + return get_triple_str(arch, vendor, os, version, env) def getExtraMakeArgs(self): """ @@ -93,12 +100,10 @@ """Returns the ARCH_CFLAGS for the make system.""" # Get the triple components. vendor, os, version, env = get_triple() - if vendor is None or os is None or version is None or env is None: + triple = get_triple_str(arch, vendor, os, version, env) + if not triple: return [] - # Construct the triple from its components. - triple = '-'.join([arch, vendor, os, version, env]) - # Construct min version argument version_min = "" if env == "simulator":
Index: lldb/packages/Python/lldbsuite/test/builders/darwin.py =================================================================== --- lldb/packages/Python/lldbsuite/test/builders/darwin.py +++ lldb/packages/Python/lldbsuite/test/builders/darwin.py @@ -54,13 +54,20 @@ return vendor, os, version, env +def get_triple_str(arch, vendor, os, version, env): + if None in [arch, vendor, os, version, env]: + return None + + component = [arch, vendor, os + version] + if env: + components.append(env) + return '-'.join(component) + + class BuilderDarwin(Builder): def getTriple(self, arch): vendor, os, version, env = get_triple() - components = [arch, vendor, os, version, env] - if None in components: - return None - return '-'.join(components) + return get_triple_str(arch, vendor, os, version, env) def getExtraMakeArgs(self): """ @@ -93,12 +100,10 @@ """Returns the ARCH_CFLAGS for the make system.""" # Get the triple components. vendor, os, version, env = get_triple() - if vendor is None or os is None or version is None or env is None: + triple = get_triple_str(arch, vendor, os, version, env) + if not triple: return [] - # Construct the triple from its components. - triple = '-'.join([arch, vendor, os, version, env]) - # Construct min version argument version_min = "" if env == "simulator":
_______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits