Is it automatically the default that a package location of recursive dependency is in the same as its dependent package above or we have to ensure, i.e. tell/instruct Cmake, to refer the recursed dependency package location?
e.g. the foobar
package is to be found
foreach(FOOB foo bar)
find_library(FOO_${FOOB}_LIBRARY ${FOOB}
HINTS
"/usr"
PATH_SUFFIXES
lib/
)
if(FOO_${FOOB}_LIBRARY)
list(APPEND FOO_LIBRARIES ${FOO_${FOOB}_LIBRARY})
endif()
endforeach()
…
…
find_package_handle_standard_args(foobar
REQUIRED_VARS
FOO_LIBRARIES
)
and
foo.so depends: baz.so
bar.so depends: baz.so
baz.so will be automatically found under /usr/lib by Cmake rule, or what syntax to ensure and order Cmake to do it?