diff --git a/CMakeLists.txt b/CMakeLists.txt index de97cb8..428664f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -72,6 +72,7 @@ set (CPACK_SOURCE_IGNORE_FILES "/build/") include (CPack) +# Compile-time configuration. configure_file (${CMAKE_SOURCE_DIR}/config.h.cmake ${CMAKE_BINARY_DIR}/config.h) @@ -118,6 +119,9 @@ target_link_libraries(encfs ) install (TARGETS encfs DESTINATION lib) +# Set RPATH to library install path. +set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib") + add_executable (encfs-bin encfs/main.cpp) target_link_libraries (encfs-bin encfs) set_target_properties (encfs-bin PROPERTIES OUTPUT_NAME "encfs")