Currently, CMake's find_library is used to find dependent libraries, but this does not find the paths to the dependent include files (for instance arb.h). Nominally, one would want to use find_package, but the arb package does not come with a FindXXX.cmake file, so that won't work. The reason I mention this is that on macOS, I installed all of the dependent libraries into /opt, and the libraries were found there, but compilations failed because the necessary header files were not found. This can be worked around by specifying -DCMAKE_C_FLAGS="-I/opt/include" (in my case), when invoking cmake.
There is the possibility of using CMake's find_path to get the location of certain header files that are necessary. I suspect there is only a handful that would need this treatment.
There is also the option of using pkg_config (via the cmake built-in module FindPkgConfig.cmake), but only GMP and MPFR (either used directly or indirectly) have .pc files. Perhaps an issue should be filed with the maintainers of Cascade's dependent libraries to get this functionality.
Currently, CMake's
find_library
is used to find dependent libraries, but this does not find the paths to the dependent include files (for instancearb.h
). Nominally, one would want to usefind_package
, but thearb
package does not come with aFindXXX.cmake
file, so that won't work. The reason I mention this is that on macOS, I installed all of the dependent libraries into/opt
, and the libraries were found there, but compilations failed because the necessary header files were not found. This can be worked around by specifying-DCMAKE_C_FLAGS="-I/opt/include"
(in my case), when invokingcmake
.There is the possibility of using CMake's
find_path
to get the location of certain header files that are necessary. I suspect there is only a handful that would need this treatment.There is also the option of using
pkg_config
(via the cmake built-in moduleFindPkgConfig.cmake
), but onlyGMP
andMPFR
(either used directly or indirectly) have.pc
files. Perhaps an issue should be filed with the maintainers of Cascade's dependent libraries to get this functionality.