[lldb][test] Use xcrun -f strip for API tests on Darwin (#111842)

A follow-up for https://github.com/llvm/llvm-project/pull/111816.

This is to fix buildbot failure
https://lab.llvm.org/staging/#/builders/195/builds/4242.

TestSymbolFileJSON.py doesn't pass with llvm-strip on macOS. Apparently,
llvm-strip/llvm-objcopy can't clean symbols from Mach-O nlists.
This commit is contained in:
Vladislav Dzhidzhoev 2024-10-10 17:14:13 +02:00 committed by GitHub
parent f59b0c7603
commit 058ede06c4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 1 deletions

View File

@ -10,6 +10,7 @@ import lldbsuite.test.lldbplatformutil as lldbplatformutil
import lldbsuite.test.lldbutil as lldbutil
from lldbsuite.test import configuration
from lldbsuite.test_event import build_exception
from lldbsuite.support import seven
class Builder:
@ -190,6 +191,9 @@ class Builder:
if not util_paths["DWP"]:
del util_paths["DWP"]
if lldbplatformutil.platformIsDarwin():
util_paths["STRIP"] = seven.get_command_output("xcrun -f strip")
for var, path in util_paths.items():
utils.append("%s=%s" % (var, path))

View File

@ -3,6 +3,6 @@ C_SOURCES := main.c
all: stripped.out
stripped.out : a.out
strip a.out -o stripped.out
$(STRIP) a.out -o stripped.out
include Makefile.rules