Skip to content

[lldb] Use add_custom_command for SBLanguages.h #91254

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
May 6, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 5 additions & 7 deletions lldb/source/API/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@ endif()
# Target to generate SBLanguages.h from Dwarf.def.
set(sb_languages_file
${CMAKE_CURRENT_BINARY_DIR}/../../include/lldb/API/SBLanguages.h)
add_custom_target(
lldb-sbapi-dwarf-enums
"${Python3_EXECUTABLE}"
add_custom_command(
COMMENT "Generating SBLanguages.h from Dwarf.def"
COMMAND "${Python3_EXECUTABLE}"
${LLDB_SOURCE_DIR}/scripts/generate-sbapi-dwarf-enum.py
${LLVM_MAIN_INCLUDE_DIR}/llvm/BinaryFormat/Dwarf.def
-o ${sb_languages_file}
BYPRODUCTS ${sb_languages_file}
OUTPUT ${sb_languages_file}
DEPENDS ${LLVM_MAIN_INCLUDE_DIR}/llvm/BinaryFormat/Dwarf.def
WORKING_DIRECTORY ${LLVM_LIBRARY_OUTPUT_INTDIR}
)
Expand Down Expand Up @@ -113,9 +113,7 @@ add_lldb_library(liblldb SHARED ${option_framework}
SystemInitializerFull.cpp
${lldb_python_wrapper}
${lldb_lua_wrapper}

DEPENDS
lldb-sbapi-dwarf-enums
${sb_languages_file}

LINK_LIBS
lldbBreakpoint
Expand Down