vcpkg - Header files not recognized
Answered
Hello,
My setup is CLion 2020.1.3, WSL2 toolchain and vcpkg. I am building a header-only library and some Catch2 tests. I have included
"-DCMAKE_TOOLCHAIN_FILE=/home/zzzz/vcpkg/scripts/buildsystems/vcpkg.cmake"
in my CMake profile and I can successfully build the project. However, I see red squigglies under all includes in my header file. My project structure and the header file is attached. I have tried Reset Cache and Reload, Unload CMake and then re-load and also resync with remote hosts, nothing seems to work.
Thank you.
Please sign in to leave a comment.
I had to use vcpkg lib yesterday, this was my flow >
Hi Suhas Ghorpadkar!
I assume the problems are related to the fact that CLion can't handle interface libraries properly - https://youtrack.jetbrains.com/issue/CPP-11340. Please see the last comment in the issue for more details.
Feel free to comment or upvote the issue. See https://intellij-support.jetbrains.com/hc/en-us/articles/207241135-How-to-follow-YouTrack-issues-and-receive-notifications if you are not familiar with YouTrack.