Index: compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake =================================================================== --- compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake +++ compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake @@ -247,6 +247,9 @@ target_link_libraries(${libname} ${LIB_LINK_LIBS}) endif() if(${type} STREQUAL "SHARED") + if(COMMAND llvm_setup_rpath) + llvm_setup_rpath(${libname}) + endif() if(WIN32 AND NOT CYGWIN AND NOT MINGW) set_target_properties(${libname} PROPERTIES IMPORT_PREFIX "") set_target_properties(${libname} PROPERTIES IMPORT_SUFFIX ".lib")