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

cmake doesn't define args_INCLUDE_DIRS #115

Closed
yurivict opened this issue Mar 14, 2023 · 2 comments
Closed

cmake doesn't define args_INCLUDE_DIRS #115

yurivict opened this issue Mar 14, 2023 · 2 comments

Comments

@yurivict
Copy link

The gccdiag project uses args_INCLUDE_DIRS here.

However, args_INCLUDE_DIRS isn't defined after find_package(args REQUIRED).

Please consider adding the section "Using with cmake" to the README explaining how to use args.

@Taywee
Copy link
Owner

Taywee commented Mar 14, 2023

When this is installed with CMake, the correct usage for this project is the target. You should be able to do this, I think, with target_link_libraries($projectname taywee::args).

@Taywee
Copy link
Owner

Taywee commented Mar 14, 2023

You do make a good point. CMake build instructions should be included. I've added an example CMakeLists.txt to the examples directory and a note in the readme about this. If you've installed cmake in the expected way (cmake -s$argsdir -B$builddir && cmake --build $builddir && cmake --install $builddir, with any optionally replaced CMAKE_INSTALL_PREFIX), then this should work as expected.

@Taywee Taywee closed this as completed Mar 14, 2023
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