andy-thomason / Vookoo

A set of utilities for taking the pain out of Vulkan in header only modern C++
MIT License
522 stars 52 forks source link

CMake error: target dependency added via `target_include_directories` #16

Closed Robert42 closed 3 years ago

Robert42 commented 5 years ago

In the example's cmake file, there's a line

target_include_directories(${order}-${exname} PRIVATE Vulkan::Vulkan)

To my knowledge, target_include_directories only allows directory paths and not targets as arguments. I needed to move the Vulkan::Vulkan dependency to target_link_libraries in order to be able to compile the samples

lhog commented 5 years ago

Please confirm you can't compile it now (because I can) and provide your system specs: CMake version, OS, Vulkan SDK version, etc.

9prady9 commented 5 years ago

CMake import targets are meant to be used with target_link_libraries unless newer versions added support for using them target_include_directories. Vulkan::Vulkan passed to link libraries call should include the header location just as fine.

lhog commented 4 years ago

See if https://github.com/andy-thomason/Vookoo/pull/18 good enough

andy-thomason commented 4 years ago

Let me know how you get on with the merge...

FunMiles commented 4 years ago

The offending line has been removed in the PR for #21. If it does resolve the issue completely, then this issue should be closed.

FunMiles commented 4 years ago

Now that the PR for #21 has been merged, I think this issue is also addressed. @Robert42, have you tried it ?

FunMiles commented 3 years ago

Without further comment on this issue, should it be closed? @Robert42 can reopen it if there's still an issue for him.

lhog commented 3 years ago

Reopen, in case the issue persists