Skip to content

Commit b31f8cb

Browse files
authored
[LLDB] Require DIA SDK for testing the PDB plugin-selection setting (#158284)
If LLDB is built without the DIA SDK enabled, then the native plugin is used regardless of `plugin.symbol-file.pdb.reader` or `LLDB_USE_NATIVE_PDB_READER`. This made the test fail on Windows when the DIA SDK was disabled (#114906 (comment)). This PR changes the requirement for the test from `target-windows` to `diasdk` (only used in this test).
1 parent cf9576d commit b31f8cb

File tree

4 files changed

+6
-1
lines changed

4 files changed

+6
-1
lines changed

lldb/test/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,7 @@ llvm_canonicalize_cmake_booleans(
250250
LLDB_ENABLE_LZMA
251251
LLVM_ENABLE_ZLIB
252252
LLVM_ENABLE_SHARED_LIBS
253+
LLVM_ENABLE_DIA_SDK
253254
LLDB_HAS_LIBCXX
254255
LLDB_TEST_SHELL_DISABLE_REMOTE
255256
LLDB_TOOL_LLDB_SERVER_BUILD

lldb/test/Shell/SymbolFile/PDB/native-setting.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: target-windows
1+
// REQUIRES: diasdk
22

33
// Test plugin.symbol-file.pdb.reader setting
44
// RUN: %build -o %t.exe -- %s

lldb/test/Shell/lit.cfg.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,9 @@ def calculate_arch_features(arch_string):
170170
)
171171
)
172172

173+
if config.have_dia_sdk:
174+
config.available_features.add("diasdk")
175+
173176
# NetBSD permits setting dbregs either if one is root
174177
# or if user_set_dbregs is enabled
175178
can_set_dbregs = True

lldb/test/Shell/lit.site.cfg.py.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ config.have_lldb_server = @LLDB_TOOL_LLDB_SERVER_BUILD@
3434
config.lldb_system_debugserver = @LLDB_USE_SYSTEM_DEBUGSERVER@
3535
config.llvm_use_sanitizer = "@LLVM_USE_SANITIZER@"
3636
config.lldb_has_lldbrpc = @LLDB_BUILD_LLDBRPC@
37+
config.have_dia_sdk = @LLVM_ENABLE_DIA_SDK@
3738
# The shell tests use their own module caches.
3839
config.lldb_module_cache = os.path.join("@LLDB_TEST_MODULE_CACHE_LLDB@", "lldb-shell")
3940
config.clang_module_cache = os.path.join("@LLDB_TEST_MODULE_CACHE_CLANG@", "lldb-shell")

0 commit comments

Comments
 (0)