CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
80 lines
2.7 KiB
Python
80 lines
2.7 KiB
Python
import re
|
|
import os
|
|
import subprocess
|
|
|
|
from .builder import Builder
|
|
from lldbsuite.test import configuration
|
|
import lldbsuite.test.lldbutil as lldbutil
|
|
|
|
TRIPLE_RE = re.compile(
|
|
r"""^(?P<arch>[a-zA-Z0-9_]+) # arch (required)
|
|
(?:-(?P<vendor>[a-zA-Z0-9_]+))? # vendor (optional)
|
|
(?:-(?P<os>[a-zA-Z_]+)(?P<os_version>[\d.]+)?)? # os + version (optional)
|
|
(?:-(?P<env>[a-zA-Z0-9_]+))? # env/abi (optional)
|
|
$""",
|
|
re.X,
|
|
)
|
|
|
|
|
|
def split_triple(triple):
|
|
if m := TRIPLE_RE.match(triple):
|
|
return m.groups()
|
|
return [None] * TRIPLE_RE.groups
|
|
|
|
|
|
class BuilderDarwin(Builder):
|
|
def getExtraMakeArgs(self):
|
|
"""
|
|
Helper function to return extra argumentsfor the make system. This
|
|
method is meant to be overridden by platform specific builders.
|
|
"""
|
|
args = dict()
|
|
|
|
if configuration.dsymutil:
|
|
args["DSYMUTIL"] = configuration.dsymutil
|
|
|
|
if configuration.apple_sdk and "internal" in configuration.apple_sdk:
|
|
sdk_root = lldbutil.get_xcode_sdk_root(configuration.apple_sdk)
|
|
if sdk_root:
|
|
private_frameworks = os.path.join(
|
|
sdk_root, "System", "Library", "PrivateFrameworks"
|
|
)
|
|
args["FRAMEWORK_INCLUDES"] = "-F{}".format(private_frameworks)
|
|
|
|
if triple := self.getTriple():
|
|
_, _, operating_system, _, env = split_triple(triple)
|
|
|
|
builder_dir = os.path.dirname(os.path.abspath(__file__))
|
|
test_dir = os.path.dirname(builder_dir)
|
|
if operating_system in [None, "darwin", "macos", "macosx"]:
|
|
entitlements_file = "entitlements-macos.plist"
|
|
else:
|
|
if env == "simulator":
|
|
entitlements_file = "entitlements-simulator.plist"
|
|
else:
|
|
entitlements_file = "entitlements.plist"
|
|
entitlements = os.path.join(test_dir, "make", entitlements_file)
|
|
args["CODESIGN"] = "codesign --entitlements {}".format(entitlements)
|
|
|
|
# Return extra args as a formatted string.
|
|
return ["{}={}".format(key, value) for key, value in args.items()]
|
|
|
|
def getArchCFlags(self):
|
|
triple = self.getTriple()
|
|
if not triple:
|
|
return []
|
|
|
|
_, _, os, version, _ = split_triple(triple)
|
|
|
|
if os == "darwin" or not version:
|
|
return []
|
|
|
|
target_os = "-mtargetos={}{}".format(os, version)
|
|
|
|
return ["ARCH_CFLAGS={}".format(target_os)]
|
|
|
|
def _getDebugInfoArgs(self, debug_info):
|
|
if debug_info == "dsym":
|
|
return ["MAKE_DSYM=YES"]
|
|
return super(BuilderDarwin, self)._getDebugInfoArgs(debug_info)
|