You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I use add_executable() it automatically "knows" where to find every h-file.
However, add_library() with the same source files (except for main.cpp) requires adding target_include_directories() with the locations of all the h-files.
Shouldn't CPM find the h-files "for everyone" ?
The text was updated successfully, but these errors were encountered:
I'm having a similar problem with an executable using CPM 0.40.0 with our own libraries hosted on GitLab. Additionally, the libraries are not being built for some reason, so linking fails.
For example:
CPMAddPackage("gh:fmtlib/fmt#10.2.1")
...works fine, but this:
CPMAddPackage(
NAME common
VERSION 1.0.9
GIT_REPOSITORY [email protected]
)
requires this to resolve the includes:
target_include_directories(myapp PUBLIC
src
$<BUILD_INTERFACE:${common_SOURCE_DIR}/include>
)
If I use
add_executable()
it automatically "knows" where to find every h-file.However,
add_library()
with the same source files (except for main.cpp) requires addingtarget_include_directories()
with the locations of all the h-files.Shouldn't CPM find the h-files "for everyone" ?
The text was updated successfully, but these errors were encountered: