Skip to content

Paths to diaguids.lib are exported as absolute paths in Windows LLVMExports.cmake #152268

@Ext3h

Description

@Ext3h

In the exported CMake module LLVMExports.cmake (as seen in the provided tarball lib/cmake/llvm/LLVMExports.cmake), an absolute path to a dependency is included by accident:

# Create imported target LLVMDebugInfoPDB
add_library(LLVMDebugInfoPDB STATIC IMPORTED)

set_target_properties(LLVMDebugInfoPDB PROPERTIES
  INTERFACE_LINK_LIBRARIES "C:/Program Files (x86)/Microsoft Visual Studio/2019/Professional/DIA SDK/lib/amd64/diaguids.lib;LLVMBinaryFormat;LLVMObject;LLVMSupport;LLVMDebugInfoCodeView;LLVMDebugInfoMSF"
)

This does not work for consumption with any other Visual Studio version, edition (build tools, community, professional, enterprise) or Visual Studio install path.

C:/Program Files (x86)/Microsoft Visual Studio/2019/Professional/DIA SDK/lib/amd64/diaguids.lib should be substituted back into $(VSInstallDir)DIA SDK/lib/amd64/diaguids.lib on export.

Metadata

Metadata

Assignees

No one assigned

    Labels

    cmakeBuild system in general and CMake in particularplatform:windows

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions