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

The root CMakeLists doesn't export the library #19

Open
siniarskimar opened this issue Feb 1, 2022 · 1 comment
Open

The root CMakeLists doesn't export the library #19

siniarskimar opened this issue Feb 1, 2022 · 1 comment

Comments

@siniarskimar
Copy link

A good practice when writing a library with CMake is to export any public targets. This enables code reuse and the usage of find_package().

Currently the tortelini target isn't being exported nor installed.

We should check whenever the project is a root project (ie. "${CMAKE_SOURCE_DIR} == ${CMAKE_CURRENT_SOURCE_DIR}"), provide an install target and export it.

@Qix-
Copy link
Owner

Qix- commented Feb 1, 2022

Meh I never use find_package personally as it is usually a huge headache. I tend to just add_subdirectory directly.

Feel free to PR though. :)

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

No branches or pull requests

2 participants