Hi, When CMake exports libraries that depend on system library, absolute path to these system libraries are hardcoded in CMakefile configuration files.
For example, when building and installing ITK, the file lib/cmake/ITK-4.7ITKTargets-release.cmake is installed and contain a reference to /usr/lib64/libm.so . My problem is that I want to build a conda package for ITK on Centos OS 5.11, then install this ITK package on Ubuntu 14.04, and link with ITK libraries. But it fails as libm is search in /usr/lib64/libm.so instead of /lib/x86_64-linux-gnu/libm.so.6 . Here is a minimal example to reproduce the problem without ITK: https://github.com/dfroger/gravitation Is there an way in CMake to export libraries without absolute path to dependant system libraries? Thanks, David -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake