How to include library header files in subdirectory

  • Thread starter Thread starter linganmm
  • Start date Start date
L

linganmm

Guest
Hi, I have a Visual Studio 2015 C++ project organized like this:

myapp

|

-- subdir/something.cpp

-- libdir/blabla.h

And I have add path\to\myapp\libdir to the "Include directories", "library directories" as well as "Additional include directories" in project property.

However, when I include blabla.h in something.cpp:

#include <blabla.h>

I still get the "cannot open source file blabla.h" error.

Files right under the root directory do not have such problem.

I know "#include "../libdir/blabla.h"" may bypass this issue, but it's not very beautiful.

Can't VC project be organized into hierarchical directories, like Linux does?

Thank you!

Continue reading...
 
Back
Top