mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-06 19:14:14 +08:00
mdbx-cmake: add installation.
Change-Id: Ie2f67e51ddaf9444b3c0a817cd5f8e7e37ec8d0e
This commit is contained in:
parent
94d90d87db
commit
d1e2749337
@ -195,4 +195,22 @@ foreach(TOOL mdbx_chk mdbx_copy mdbx_stat mdbx_dump mdbx_load)
|
|||||||
target_link_libraries(${TOOL} mdbx-static)
|
target_link_libraries(${TOOL} mdbx-static)
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
|
# installation
|
||||||
|
if(MDBX_BUILD_SHARED_LIBRARY)
|
||||||
|
install(TARGETS mdbx EXPORT libmdbx
|
||||||
|
LIBRARY DESTINATION lib COMPONENT runtime
|
||||||
|
PUBLIC_HEADER DESTINATION include
|
||||||
|
INCLUDES DESTINATION include COMPONENT devel)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
install(TARGETS mdbx-static EXPORT libmdbx
|
||||||
|
LIBRARY DESTINATION lib COMPONENT runtime
|
||||||
|
OBJECTS DESTINATION lib/static COMPONENT devel
|
||||||
|
ARCHIVE DESTINATION lib/static COMPONENT devel
|
||||||
|
PUBLIC_HEADER DESTINATION include
|
||||||
|
INCLUDES DESTINATION include COMPONENT devel)
|
||||||
|
|
||||||
|
install(TARGETS mdbx_chk mdbx_stat mdbx_copy mdbx_dump mdbx_load
|
||||||
|
RUNTIME DESTINATION bin COMPONENT runtime)
|
||||||
|
|
||||||
cmake_policy(POP)
|
cmake_policy(POP)
|
||||||
|
@ -226,4 +226,11 @@ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/elements/config.h.in"
|
|||||||
"${CMAKE_CURRENT_SOURCE_DIR}/elements/config.h" ESCAPE_QUOTES)
|
"${CMAKE_CURRENT_SOURCE_DIR}/elements/config.h" ESCAPE_QUOTES)
|
||||||
add_definitions(-DMDBX_CONFIG_H="config.h")
|
add_definitions(-DMDBX_CONFIG_H="config.h")
|
||||||
|
|
||||||
|
install(TARGETS mdbx EXPORT libmdbx
|
||||||
|
LIBRARY DESTINATION lib COMPONENT runtime
|
||||||
|
OBJECTS DESTINATION lib/static COMPONENT devel
|
||||||
|
ARCHIVE DESTINATION lib/static COMPONENT devel
|
||||||
|
PUBLIC_HEADER DESTINATION include
|
||||||
|
INCLUDES DESTINATION include COMPONENT devel)
|
||||||
|
|
||||||
add_subdirectory(tools)
|
add_subdirectory(tools)
|
||||||
|
@ -40,3 +40,6 @@ if(LIB_MATH)
|
|||||||
target_link_libraries(mdbx_chk ${LIB_MATH})
|
target_link_libraries(mdbx_chk ${LIB_MATH})
|
||||||
target_link_libraries(mdbx_stat ${LIB_MATH})
|
target_link_libraries(mdbx_stat ${LIB_MATH})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
install(TARGETS mdbx_chk mdbx_stat mdbx_copy mdbx_dump mdbx_load
|
||||||
|
RUNTIME DESTINATION bin COMPONENT runtime)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user