File tree Expand file tree Collapse file tree 3 files changed +14
-11
lines changed Expand file tree Collapse file tree 3 files changed +14
-11
lines changed Original file line number Diff line number Diff line change 25
25
26
26
PROJECT (MYSQLCPPCONN )
27
27
28
- IF (WIN32 )
29
- # We need this for mysqlcppconn_EXPORTS needed for the static build
30
- cmake_minimum_required (VERSION 2.6.2 )
31
- ELSE (WIN32 )
32
- cmake_minimum_required (VERSION 2.6 )
33
- ENDIF (WIN32 )
28
+ cmake_minimum_required (VERSION 2.6.2 )
34
29
35
30
if (COMMAND cmake_policy AND POLICY CMP0015 )
36
31
cmake_policy (SET CMP0015 NEW )
37
32
endif (COMMAND cmake_policy AND POLICY CMP0015 )
38
33
39
-
40
34
INCLUDE (VersionInfo.cmake )
41
35
36
+ OPTION (TAR_LAYOUT "Use directory layout for an unpacked TAR install" )
37
+
38
+ IF (TAR_LAYOUT OR NOT CMAKE_VERSION OR CMAKE_VERSION VERSION_LESS "2.8.5" )
39
+ SET (INSTALL_LIBDIR lib )
40
+ ELSE ()
41
+ INCLUDE (GNUInstallDirs )
42
+ SET (INSTALL_LIBDIR ${CMAKE_INSTALL_LIBDIR} )
43
+ ENDIF ()
44
+
42
45
SET (EDIT_WARNING_MESSAGE "Please do not edit this file - it is generated by cmake. Edit its source file instead." )
43
46
44
47
# Configuring header file with driver version info
Original file line number Diff line number Diff line change @@ -309,8 +309,8 @@ IF(WIN32)
309
309
)
310
310
ELSE (WIN32 )
311
311
INSTALL (TARGETS mysqlcppconn mysqlcppconn-static
312
- LIBRARY DESTINATION lib
313
- ARCHIVE DESTINATION lib
312
+ LIBRARY DESTINATION ${INSTALL_LIBDIR}
313
+ ARCHIVE DESTINATION ${INSTALL_LIBDIR}
314
314
)
315
315
ENDIF (WIN32 )
316
316
Original file line number Diff line number Diff line change @@ -72,8 +72,8 @@ IF(WIN32)
72
72
)
73
73
ELSE (WIN32 )
74
74
INSTALL (TARGETS mysqlcppconn_thread mysqlcppconn_thread-static
75
- LIBRARY DESTINATION lib
76
- ARCHIVE DESTINATION lib
75
+ LIBRARY DESTINATION ${INSTALL_LIBDIR}
76
+ ARCHIVE DESTINATION ${INSTALL_LIBDIR}
77
77
)
78
78
ENDIF (WIN32 )
79
79
You can’t perform that action at this time.
0 commit comments