On 09/03/2013 01:57 PM, Marcin Wojdyr wrote: > On 3 September 2013 15:46, Brad King <brad.k...@kitware.com> wrote: >> One way to do this is to tell CMake that the library uses C++ >> using the IMPORTED_LINK_INTERFACE_LANGUAGES property on an > > That's what I was looking for, but for me instead of adding C++ > runtime, C++ compiler (icpc) is used for linking. > So I have the same problem: > undefined reference to `main'
Now set LINKER_LANGUAGE to "Fortran" to tell it that your main is there. I think the LINKER_PREFERENCE infrastructure may be outdated. -Brad -- 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://www.cmake.org/mailman/listinfo/cmake