Skip to content

Fix CMake subproject behaviour. #26

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

Merged
merged 1 commit into from
Aug 13, 2014
Merged

Fix CMake subproject behaviour. #26

merged 1 commit into from
Aug 13, 2014

Conversation

alex-ac
Copy link

@alex-ac alex-ac commented Aug 9, 2014

If you add jsoncpp to another project with CMake, as a subproject, than ${CMAKE_SOURCE_DIR}/include will be a root project include directory:

project_a/
  CMakeLists.txt  # Contains: add_subdirectory(jsoncpp)
  include/  # <- ${CMAKE_SOURCE_DIR}/include
  jsoncpp/
    CMakeLists.txt
    include/  # <- ${jsoncpp_SOURCE_DIR}/include

@cdunn2001 cdunn2001 merged this pull request into open-source-parsers:master Aug 13, 2014
cdunn2001 added a commit that referenced this pull request Aug 13, 2014
Fix CMake subproject behaviour.

Sweet. But doesn't this assume that people call the subproject `jsoncpp`? It used to be `json-cpp`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants