Skip to content

[ci] add dependencies for lldb python binding tests #136158

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 19, 2025

Conversation

mizvekov
Copy link
Contributor

Add correct configuration and dependencies for LLDB testing which is actually relevant for clang changes.

@mizvekov mizvekov self-assigned this Apr 17, 2025
@mizvekov mizvekov requested a review from JDevlieghere as a code owner April 17, 2025 16:40
@llvmbot llvmbot added the lldb label Apr 17, 2025
@llvmbot
Copy link
Member

llvmbot commented Apr 17, 2025

@llvm/pr-subscribers-lldb

Author: Matheus Izvekov (mizvekov)

Changes

Add correct configuration and dependencies for LLDB testing which is actually relevant for clang changes.


Full diff: https://github.com/llvm/llvm-project/pull/136158.diff

2 Files Affected:

  • (modified) .ci/monolithic-linux.sh (+8)
  • (modified) lldb/test/requirements.txt (+2)
diff --git a/.ci/monolithic-linux.sh b/.ci/monolithic-linux.sh
index 59a6b22ccb06a..653495e45786a 100755
--- a/.ci/monolithic-linux.sh
+++ b/.ci/monolithic-linux.sh
@@ -54,6 +54,7 @@ targets="${2}"
 lit_args="-v --xunit-xml-output ${BUILD_DIR}/test-results.xml --use-unique-output-file-name --timeout=1200 --time-tests"
 
 echo "--- cmake"
+
 export PIP_BREAK_SYSTEM_PACKAGES=1
 pip install -q -r "${MONOREPO_ROOT}"/mlir/python/requirements.txt
 pip install -q -r "${MONOREPO_ROOT}"/lldb/test/requirements.txt
@@ -63,9 +64,13 @@ pip install -q -r "${MONOREPO_ROOT}"/.ci/requirements.txt
 export LLVM_SYMBOLIZER_PATH=`which llvm-symbolizer`
 [[ ! -f "${LLVM_SYMBOLIZER_PATH}" ]] && echo "llvm-symbolizer not found!"
 
+# Set up all runtimes either way. libcxx is a dependency of LLDB.
+# If it ends up being unused, not much harm.
 cmake -S "${MONOREPO_ROOT}"/llvm -B "${BUILD_DIR}" \
       -D LLVM_ENABLE_PROJECTS="${projects}" \
+      -D LLVM_ENABLE_RUNTIMES="libcxx;libcxxabi;libunwind" \
       -G Ninja \
+      -D CMAKE_PREFIX_PATH="${HOME}/.local" \
       -D CMAKE_BUILD_TYPE=Release \
       -D LLVM_ENABLE_ASSERTIONS=ON \
       -D LLVM_BUILD_EXAMPLES=ON \
@@ -74,7 +79,10 @@ cmake -S "${MONOREPO_ROOT}"/llvm -B "${BUILD_DIR}" \
       -D LLVM_ENABLE_LLD=ON \
       -D CMAKE_CXX_FLAGS=-gmlt \
       -D LLVM_CCACHE_BUILD=ON \
+      -D LIBCXX_CXX_ABI=libcxxabi \
       -D MLIR_ENABLE_BINDINGS_PYTHON=ON \
+      -D LLDB_ENABLE_PYTHON=ON \
+      -D LLDB_ENFORCE_STRICT_TEST_REQUIREMENTS=ON \
       -D CMAKE_INSTALL_PREFIX="${INSTALL_DIR}"
 
 echo "--- ninja"
diff --git a/lldb/test/requirements.txt b/lldb/test/requirements.txt
index 708f2327a6a04..c187180697d0b 100644
--- a/lldb/test/requirements.txt
+++ b/lldb/test/requirements.txt
@@ -5,3 +5,5 @@ psutil>=5.9.4
 # See llvm.org/pr22274.
 pexpect>=4.9.0; sys_platform != 'win32'
 packaging
+# Required for python tests
+swig

@mizvekov mizvekov force-pushed the users/mizvekov/ci-lldb-python-deps branch from 20f393e to cfb1035 Compare April 17, 2025 16:41
@mizvekov mizvekov force-pushed the users/mivekov/ci-symbolizer branch from ae4da18 to 778c401 Compare April 18, 2025 20:44
Base automatically changed from users/mivekov/ci-symbolizer to main April 18, 2025 22:46
Add correct configuration and dependencies for LLDB testing which
is actually relevant for clang changes.
@mizvekov mizvekov force-pushed the users/mizvekov/ci-lldb-python-deps branch from cfb1035 to ba2f21f Compare April 18, 2025 23:06
@mizvekov mizvekov merged commit 1c4ff51 into main Apr 19, 2025
11 checks passed
@mizvekov mizvekov deleted the users/mizvekov/ci-lldb-python-deps branch April 19, 2025 06:50
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants