1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
|
From 1352b633388dd9d82b8cb7e3d11932d0b569da4e Mon Sep 17 00:00:00 2001
From: hasufell <hasufell@gentoo.org>
Date: Thu, 27 Mar 2014 21:07:37 +0100
Subject: [PATCH 1/4] make install destinations modifiable
---
CMakeLists.txt | 5 +++--
client/CMakeLists.txt | 2 +-
master/CMakeLists.txt | 4 ++++
odalaunch/CMakeLists.txt | 2 +-
server/CMakeLists.txt | 2 +-
5 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 11e52d1..262e3db 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,4 +1,5 @@
include(CMakeDependentOption)
+include(GNUInstallDirs)
project(Odamex)
cmake_minimum_required(VERSION 2.8)
@@ -113,10 +114,10 @@ if(NOT APPLE)
set(CPACK_INCLUDE_TOPLEVEL_DIRECTORY OFF)
else()
install(FILES odamex.wad LICENSE README
- DESTINATION share/odamex
+ DESTINATION ${CMAKE_INSTALL_DATADIR}/odamex
COMPONENT common)
install(FILES ${CONFIG_SAMPLES}
- DESTINATION share/odamex/config-samples
+ DESTINATION ${CMAKE_INSTALL_DATADIR}/odamex/config-samples
COMPONENT common)
option(ODAMEX_COMPONENT_PACKAGES "Create several rpm/deb packages for repository maintainers." OFF)
diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt
index 510b820..3f73ab5 100644
--- a/client/CMakeLists.txt
+++ b/client/CMakeLists.txt
@@ -228,7 +228,7 @@ if(SDL_FOUND AND SDLMIXER_FOUND)
COMPONENT client)
else()
install(TARGETS odamex
- RUNTIME DESTINATION bin
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
COMPONENT client)
endif()
endif()
diff --git a/master/CMakeLists.txt b/master/CMakeLists.txt
index 7fc386b..5bdc048 100644
--- a/master/CMakeLists.txt
+++ b/master/CMakeLists.txt
@@ -14,3 +14,7 @@ if(WIN32)
elseif(SOLARIS)
target_link_libraries(odamast socket nsl)
endif()
+
+if(UNIX)
+ install( TARGETS odamast DESTINATION ${CMAKE_INSTALL_BINDIR} )
+endif()
diff --git a/odalaunch/CMakeLists.txt b/odalaunch/CMakeLists.txt
index 4ca5920..0b134ef 100644
--- a/odalaunch/CMakeLists.txt
+++ b/odalaunch/CMakeLists.txt
@@ -71,7 +71,7 @@ if(wxWidgets_FOUND)
COMPONENT odalaunch)
else()
install(TARGETS odalaunch
- RUNTIME DESTINATION bin
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
COMPONENT odalaunch)
endif()
diff --git a/server/CMakeLists.txt b/server/CMakeLists.txt
index b046714..d33b974 100644
--- a/server/CMakeLists.txt
+++ b/server/CMakeLists.txt
@@ -73,6 +73,6 @@ elseif(WIN32)
COMPONENT server)
else()
install(TARGETS odasrv
- RUNTIME DESTINATION bin
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
COMPONENT server)
endif()
--
1.9.1
|