Skip to content

Library Targets Include Directories Broken #1124

@dipustm

Description

@dipustm

Hi folks, when using the draco library as a subproject, or with CMake's FetchContent machinery, the draco includes are broken. This stems from the definition of the draco_add_library macro. It is not able to find the headers and generated file(draco/draco_features.h header).

I have done the work around like below:-
target_include_directories(draco_static
PUBLIC
$<BUILD_INTERFACE:${draco_SOURCE_DIR}/src>
$<BUILD_INTERFACE:${CMAKE_BINARY_DIR}>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)

But this way we are exposing the entire draco source code to consumer. Does anyone know better solution for this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugcmakeBugs and feature requests related to Draco's CMake buildlow priority

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions