Skip to content

Commit

Permalink
CMake configure_file should place config.cmake in the root
Browse files Browse the repository at this point in the history
This change allows the configuration of websocketpp-config.cmake to be compliant with what cmake expects when an "export" statement is used.  This adjustment allows the "find_package(websocketpp)" command to behave as expected if a user installs websocketpp via the "INSTALL" project on Windows.
  • Loading branch information
codemercenary committed Aug 20, 2014
1 parent 5ef4855 commit ba2f422
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions CMakeLists.txt
Expand Up @@ -218,12 +218,12 @@ print_used_build_config()

export (PACKAGE websocketpp)

configure_file (websocketpp-config.cmake.in "${PROJECT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/websocketpp-config.cmake" @ONLY)
configure_file (websocketpp-configVersion.cmake.in "${PROJECT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/websocketpp-configVersion.cmake" @ONLY)
configure_file (websocketpp-config.cmake.in websocketpp-config.cmake @ONLY)
configure_file (websocketpp-configVersion.cmake.in websocketpp-configVersion.cmake @ONLY)

# Install the websocketpp-config.cmake and websocketpp-configVersion.cmake
install (FILES
"${PROJECT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/websocketpp-config.cmake"
"${PROJECT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/websocketpp-configVersion.cmake"
"websocketpp-config.cmake"
"websocketpp-configVersion.cmake"
DESTINATION "${INSTALL_CMAKE_DIR}" COMPONENT dev)

0 comments on commit ba2f422

Please sign in to comment.