Skip to content

Project can't be included as a sub-project of another CMake project #15

Description

@mschuckmann

Attempting to use CMakes fetchcontent() facility or simply including this project as a sub-project (or dependency) of another CMake project fails due to incorrect use of CMAKE_SOURCE_DIR in when setting up the include paths in src/CMakeLists.txt

The use of CMAKE_SOURCE_DIR should be replaced with CMAKE_PROJECT_SOURCE_DIR.
Additionally the use of CMAKE_CURRENT_*_DIR variables should probably be changed to use the CMAKE_PROJECT_*_DIR versions.

There maybe other similar changes required.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions