a third party library using cmake? In my case I'm trying to link asio with my project. I found some solutions online. One is adding the library into my project as a standalone library (I like that solution but still using the snippets I found online I can't yet include asio headers). How do you do that in your projects? An example project, with a cmakelists would be very helpful
cmake usually comes with find modules which can find third party libraries for you. After that you add a library with target_link_library() and add headers with target_include_directories()
do you mean find_package?
yep, i could show you how to add asio to a project i guess. Wait a sec
yes that would be very helpful!
can you point to me to a decent hello world example or something? i can't be bothered to write usage code D
i would prefer a pastebin
https://pastebin.com/qKTFyzNj
lol i thought you'd send me something complex which shows some basic usage, i could have included headers myself
I see, I forgot that it might still be badly linked even when the header is being included properly
Обсуждают сегодня