Sfoglia il codice sorgente

Merge pull request #87 from Nicop06/fix-install-lib64

Fix 64 bit install
Dalton Nell 7 anni fa
parent
commit
25c133eba8
1 ha cambiato i file con 9 aggiunte e 1 eliminazioni
  1. 9
    1
      CMakeLists.txt

+ 9
- 1
CMakeLists.txt Vedi File

@@ -118,7 +118,15 @@ else()
118 118
   endif()
119 119
 endif()
120 120
 
121
+get_property(LIB64 GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS)
122
+
123
+if ("${LIB64}" STREQUAL "TRUE")
124
+  set(LIBSUFFIX 64)
125
+else()
126
+  set(LIBSUFFIX "")
127
+endif()
128
+
121 129
 install( TARGETS ${EXECUTABLE_NAME} DESTINATION "${CMAKE_INSTALL_PREFIX}/bin" )
122
-install( TARGETS ${LIBRARY_NAME} DESTINATION "${CMAKE_INSTALL_PREFIX}/lib" )
130
+install( TARGETS ${LIBRARY_NAME} DESTINATION "${CMAKE_INSTALL_PREFIX}/lib${LIBSUFFIX}" )
123 131
 install( FILES ${CMAKE_SOURCE_DIR}/src/slop.hpp DESTINATION "${CMAKE_INSTALL_PREFIX}/include" COMPONENT development )
124 132
 install( FILES "${CMAKE_SOURCE_DIR}/${MANTARGET}" DESTINATION  "${CMAKE_INSTALL_MANDIR}/man1" COMPONENT doc )