aboutsummaryrefslogtreecommitdiffhomepage
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorMichael Keck <[email protected]>2024-04-24 07:43:23 +0200
committerGitHub <[email protected]>2024-04-24 01:43:23 -0400
commit4ce1625b8ae22a4e0030f07d80360e25ae558a1e (patch)
tree8fc25cbdb8c649005ae6349e28d8d41a01f36d1e /CMakeLists.txt
parent5857b13df1a6c2040c8abfd7c694321c9b56fb92 (diff)
downloadenet-4ce1625b8ae22a4e0030f07d80360e25ae558a1e.tar.gz
enet-4ce1625b8ae22a4e0030f07d80360e25ae558a1e.zip
CMake: Improve install instructions (#244)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt14
1 files changed, 8 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 61cef93..2398ccc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -98,10 +98,12 @@ if (WIN32)
target_link_libraries(enet winmm ws2_32)
endif()
+include(GNUInstallDirs)
install(TARGETS enet
- RUNTIME DESTINATION bin
- ARCHIVE DESTINATION lib/static
- LIBRARY DESTINATION lib)
-
-install(DIRECTORY include/
- DESTINATION include)
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
+)
+install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/enet
+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
+)