2015-02-11 05:17:52 +08:00
|
|
|
macro(add_pdb_impl_folder group)
|
|
|
|
list(APPEND PDB_IMPL_SOURCES ${ARGN})
|
|
|
|
source_group(${group} FILES ${ARGN})
|
|
|
|
endmacro()
|
|
|
|
|
|
|
|
if(HAVE_DIA_SDK)
|
|
|
|
include_directories(${MSVC_DIA_SDK_DIR}/include)
|
|
|
|
set(LIBPDB_LINK_FOLDERS "${MSVC_DIA_SDK_DIR}\\lib")
|
|
|
|
if (CMAKE_SIZEOF_VOID_P EQUAL 8)
|
|
|
|
set(LIBPDB_LINK_FOLDERS "${LIBPDB_LINK_FOLDERS}\\amd64")
|
|
|
|
endif()
|
2015-06-20 05:50:27 +08:00
|
|
|
file(TO_CMAKE_PATH "${LIBPDB_LINK_FOLDERS}\\diaguids.lib" LIBPDB_ADDITIONAL_LIBRARIES)
|
2015-02-11 05:17:52 +08:00
|
|
|
|
|
|
|
add_pdb_impl_folder(DIA
|
|
|
|
DIA/DIADataStream.cpp
|
|
|
|
DIA/DIAEnumDebugStreams.cpp
|
|
|
|
DIA/DIAEnumLineNumbers.cpp
|
|
|
|
DIA/DIAEnumSourceFiles.cpp
|
|
|
|
DIA/DIAEnumSymbols.cpp
|
|
|
|
DIA/DIALineNumber.cpp
|
|
|
|
DIA/DIARawSymbol.cpp
|
|
|
|
DIA/DIASession.cpp
|
|
|
|
DIA/DIASourceFile.cpp
|
|
|
|
)
|
|
|
|
|
2015-02-11 11:28:02 +08:00
|
|
|
set(LIBPDB_ADDITIONAL_HEADER_DIRS "${LLVM_MAIN_INCLUDE_DIR}/llvm/DebugInfo/PDB/DIA")
|
2015-02-11 05:17:52 +08:00
|
|
|
endif()
|
|
|
|
|
2016-04-22 04:58:35 +08:00
|
|
|
add_pdb_impl_folder(Raw
|
|
|
|
Raw/PDBFile.cpp
|
|
|
|
Raw/PDBStream.cpp
|
|
|
|
Raw/RawSession.cpp)
|
|
|
|
|
2015-02-11 11:28:02 +08:00
|
|
|
list(APPEND LIBPDB_ADDITIONAL_HEADER_DIRS "${LLVM_MAIN_INCLUDE_DIR}/llvm/DebugInfo/PDB")
|
2015-02-11 05:17:52 +08:00
|
|
|
|
2015-02-07 04:30:52 +08:00
|
|
|
add_llvm_library(LLVMDebugInfoPDB
|
2015-02-11 06:43:25 +08:00
|
|
|
IPDBSourceFile.cpp
|
2015-02-07 04:30:52 +08:00
|
|
|
PDB.cpp
|
2015-04-28 01:19:51 +08:00
|
|
|
PDBContext.cpp
|
2015-02-11 06:43:25 +08:00
|
|
|
PDBExtras.cpp
|
2015-02-07 04:30:52 +08:00
|
|
|
PDBInterfaceAnchors.cpp
|
|
|
|
PDBSymbol.cpp
|
2015-02-08 08:29:29 +08:00
|
|
|
PDBSymbolAnnotation.cpp
|
|
|
|
PDBSymbolBlock.cpp
|
|
|
|
PDBSymbolCompiland.cpp
|
|
|
|
PDBSymbolCompilandDetails.cpp
|
2015-02-07 04:30:52 +08:00
|
|
|
PDBSymbolCompilandEnv.cpp
|
|
|
|
PDBSymbolCustom.cpp
|
2015-02-08 08:29:29 +08:00
|
|
|
PDBSymbolData.cpp
|
|
|
|
PDBSymbolExe.cpp
|
|
|
|
PDBSymbolFunc.cpp
|
|
|
|
PDBSymbolFuncDebugEnd.cpp
|
|
|
|
PDBSymbolFuncDebugStart.cpp
|
|
|
|
PDBSymbolLabel.cpp
|
|
|
|
PDBSymbolPublicSymbol.cpp
|
|
|
|
PDBSymbolThunk.cpp
|
|
|
|
PDBSymbolTypeArray.cpp
|
|
|
|
PDBSymbolTypeBaseClass.cpp
|
|
|
|
PDBSymbolTypeBuiltin.cpp
|
|
|
|
PDBSymbolTypeCustom.cpp
|
|
|
|
PDBSymbolTypeDimension.cpp
|
|
|
|
PDBSymbolTypeEnum.cpp
|
|
|
|
PDBSymbolTypeFriend.cpp
|
|
|
|
PDBSymbolTypeFunctionArg.cpp
|
|
|
|
PDBSymbolTypeFunctionSig.cpp
|
|
|
|
PDBSymbolTypeManaged.cpp
|
|
|
|
PDBSymbolTypePointer.cpp
|
|
|
|
PDBSymbolTypeTypedef.cpp
|
|
|
|
PDBSymbolTypeUDT.cpp
|
|
|
|
PDBSymbolTypeVTable.cpp
|
|
|
|
PDBSymbolTypeVTableShape.cpp
|
|
|
|
PDBSymbolUnknown.cpp
|
|
|
|
PDBSymbolUsingNamespace.cpp
|
2015-02-23 06:03:38 +08:00
|
|
|
PDBSymDumper.cpp
|
2015-02-11 05:17:52 +08:00
|
|
|
${PDB_IMPL_SOURCES}
|
|
|
|
|
|
|
|
ADDITIONAL_HEADER_DIRS
|
|
|
|
${LIBPDB_ADDITIONAL_HEADER_DIRS}
|
2015-02-07 04:30:52 +08:00
|
|
|
)
|
2015-02-11 05:17:52 +08:00
|
|
|
|
2015-03-24 04:03:57 +08:00
|
|
|
target_link_libraries(LLVMDebugInfoPDB INTERFACE "${LIBPDB_ADDITIONAL_LIBRARIES}")
|