Closed robertodr closed 6 years ago
The fix would be:
include(GNUInstallDirs)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR})
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_BINDIR})
Yes, you are right. Your suggestion is better than the current solution.
Should
default_build_paths.cmake
useGNUInstallDirs
? It currently stores binaries under${CMAKE_BINARY_DIR}/bin
and libraries under${CMAKE_BINARY_DIR}/lib
but on 64-bit system the latter should rather be${CMAKE_BINARY_DIR}/lib64
.