Skip to content

[BUG] CPack variables are leaking into my project when using FetchContent #651

@koenvandesande

Description

@koenvandesande

Describe the bug
When I try to use CPack on my project (after adding Redis++ using FetchContent), it now tries to build a Debian package.

Could add the CPack area inside a guard so it is only built when Redis++ is a top-level project? This prevents it from being added when using FetchContent.

if(PROJECT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
  include(CPack)
endif()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions