1 if(LLDB_VERSION_STRING)
2 set(LLDB_FULL_VERSION_STRING ${LLDB_VERSION_STRING})
5 # Configure the VCSVersion.inc file.
6 set(vcs_version_inc "${CMAKE_CURRENT_BINARY_DIR}/VCSVersion.inc")
7 set(generate_vcs_version_script "${LLVM_CMAKE_DIR}/GenerateVersionFromVCS.cmake")
9 find_first_existing_vc_file("${LLDB_SOURCE_DIR}" lldb_vc)
11 if(lldb_vc AND LLVM_APPEND_VC_REV)
12 set(lldb_source_dir ${LLDB_SOURCE_DIR})
15 add_custom_command(OUTPUT "${vcs_version_inc}"
16 DEPENDS "${lldb_vc}" "${generate_vcs_version_script}"
17 COMMAND ${CMAKE_COMMAND} "-DNAMES=LLDB"
18 "-DLLDB_SOURCE_DIR=${lldb_source_dir}"
19 "-DHEADER_FILE=${vcs_version_inc}"
20 "-DLLVM_FORCE_VC_REVISION=${LLVM_FORCE_VC_REVISION}"
21 "-DLLVM_FORCE_VC_REPOSITORY=${LLVM_FORCE_VC_REPOSITORY}"
22 -P "${generate_vcs_version_script}")
24 set_source_files_properties("${vcs_version_inc}"
25 PROPERTIES GENERATED TRUE
26 HEADER_FILE_ONLY TRUE)
28 # Configure the Version.inc file.
29 set(version_inc "${LLDB_BINARY_DIR}/include/lldb/Version/Version.inc")
32 ${LLDB_SOURCE_DIR}/include/lldb/Version/Version.inc.in
35 set_source_files_properties("${version_inc}"
36 PROPERTIES GENERATED TRUE
37 HEADER_FILE_ONLY TRUE)
39 include_directories(${CMAKE_CURRENT_BINARY_DIR})
41 add_lldb_library(lldbVersion NO_PLUGIN_DEPENDENCIES