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

[cpp doc improvement] cmake fetching #2699

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

[cpp doc improvement] cmake fetching #2699

hsdk123 opened this issue Nov 28, 2024 · 0 comments

Comments

@hsdk123
Copy link

hsdk123 commented Nov 28, 2024

The current docs recommend

include(FetchContent)
FetchContent_Declare(
 spine-runtimes
 GIT_REPOSITORY https://github.com/esotericsoftware/spine-runtimes.git
 GIT_TAG 4.2
 GIT_SHALLOW TRUE
)
FetchContent_MakeAvailable(spine-runtimes)
FetchContent_GetProperties(spine-runtimes)
if(NOT spine-runtimes_POPULATED)
   FetchContent_Populate(spine-runtimes)
endif()
add_subdirectory(${spine-runtimes_SOURCE_DIR}/spine-c ${CMAKE_BINARY_DIR}/spine-runtimes)

But

  • spine-c is mentioned, when it should be spine-cpp
  • the implementation is against cmake standards

I'd like to propose:

FetchContent_Declare(
 spine-runtimes
 GIT_REPOSITORY https://github.com/esotericsoftware/spine-runtimes.git
 GIT_TAG 4.2
 GIT_SHALLOW TRUE
 SOURCE_SUBDIR spine-cpp
)
FetchContent_MakeAvailable(spine-runtimes)

Which achieves the same goal but without the above cons.
I'd send in a PR, but I don't notice a repo for one.

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

No branches or pull requests

1 participant