Include directory for other packages
I'm trying to learn how to use a package that depends on another package I have created. Both are under ros_workspace/ and one of them(first_pack) depends on the other (lib_test, which is a shared library).
I'm able to compile lib_test, and its header file is located under lib_test/include . I added <depend package="lib_test"/> in first_pack's manifest, and included the file "lib_test/mylib.h" in its executable. But when I try to compile it, it shows:
fatal error: lib_test/mylib.h: No such file or directory compilation terminated.
I tried adding:
<export>
<cpp cflags="-I${prefix}/include"/>
</export>
to lib_test manifest, but it still doesn't work. What is the right way to do it?