Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add [target].fetch-content support for easy vendoring #161

Open
mrexodia opened this issue Nov 28, 2024 · 0 comments
Open

Add [target].fetch-content support for easy vendoring #161

mrexodia opened this issue Nov 28, 2024 · 0 comments
Labels
feature New feature

Comments

@mrexodia
Copy link
Contributor

mrexodia commented Nov 28, 2024

This can be helpful if the upstream repository's CMakeLists.txt does not work well. Probably some mechanism to transparently specify a target for it would be necessary for this feature to be helpful:

[target.mylib]
type = "shared"
fetch-content = { git = "https://github.com/foo/mylib", tag = "v1.0" }
sources = ["src/mylib.cpp"] # implicitly ${mylib_SOURCE_DIR}/src/mylib.cpp

This would have to disable file checks and transparently convert globbing expressions into file(GLOB) commands. It is also important that the SOURCE_SUBDIR command is set to a non-existent directory to avoid runing the CMakeLists.txt.

@mrexodia mrexodia added the feature New feature label Nov 28, 2024
@mrexodia mrexodia changed the title Add [fetch-content].download-only Add [target].fetch-content support Nov 28, 2024
@mrexodia mrexodia changed the title Add [target].fetch-content support Add [target].fetch-content support for easy vendoring Nov 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature
Development

No branches or pull requests

1 participant