-
What is the issue you have?can't connect the library to my project via Cmake as described here: https://github.com/nlohmann/json#embedded. my project: https://github.com/safocl/Watcher/tree/tmp Please describe the steps to reproduce the issue.Can you provide a small but working code example?What is the expected behavior?And what is the actual behavior instead?Which compiler and operating system are you using?
Which version of the library did you use?
If you experience a compilation error: can you compile and run the unit tests?
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 8 replies
-
(I moved the issue to the discussion board, because it's a question rather than a bug). Browsing your code, it seems you are only adding the project, but not linking it to your binary, see https://github.com/safocl/Watcher/blob/3a500c8288cc9a8e36c13db9ea5ae3e856bb52a1/src/CMakeLists.txt#L19 |
Beta Was this translation helpful? Give feedback.
-
same mistake |
Beta Was this translation helpful? Give feedback.
-
ох, это была моя ошибка -- я вместо target_link_libraries указал target_link_directories |
Beta Was this translation helpful? Give feedback.
ох, это была моя ошибка -- я вместо target_link_libraries указал target_link_directories
https://github.com/safocl/Watcher/blob/3a500c8288cc9a8e36c13db9ea5ae3e856bb52a1/src/loger/CMakeLists.txt#L8