1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

MCOL-3982 Avoid using autotools for libmarias3 and remove libxml2 from libmarias3 dependencies.

This commit is contained in:
Roman Nozdrin
2020-05-06 11:47:08 +00:00
parent 368c4fac05
commit 6987ac40e1
4 changed files with 18 additions and 21 deletions

View File

@ -311,11 +311,6 @@ SET (ENGINE_COMMON_INCLUDES ${ENGINE_DEFAULT_INCLUDES} ${Boost_INCLUDE_DIR} ${L
ADD_SUBDIRECTORY(utils)
add_library(marias3 SHARED IMPORTED)
set_target_properties(marias3 PROPERTIES IMPORTED_LOCATION ${CMAKE_BINARY_DIR}/lib/libmarias3.so.3.1.2)
add_dependencies(marias3 ms3)
ADD_SUBDIRECTORY(oam/oamcpp)
ADD_SUBDIRECTORY(dbcon/execplan)
ADD_SUBDIRECTORY(dbcon/joblist)

View File

@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 2.8.12)
project(storagemanager)
include_directories(include ${CMAKE_BINARY_DIR}/include ${ENGINE_UTILS_COMMON_INCLUDE})
include_directories(include ${CMAKE_BINARY_DIR}/include ${ENGINE_UTILS_COMMON_INCLUDE} ${S3API_DIR})
set(storagemanager_SRCS
src/AppendTask.cpp

View File

@ -16,22 +16,24 @@ if(GIT_FOUND AND EXISTS ${ENGINE_SRC_DIR}/.git)
endif()
endif()
include(ExternalProject)
ExternalProject_Add(ms3
SOURCE_DIR ${S3API_DIR}
CONFIGURE_COMMAND autoreconf -fi ${S3API_DIR} && ${S3API_DIR}/configure --enable-shared --disable-static --prefix=${CMAKE_BINARY_DIR} ${S3_CONFIGURE_OPT}
BUILD_COMMAND make
BUILD_IN_SOURCE 0
EXCLUDE_FROM_ALL TRUE
BUILD_BYPRODUCTS ${CMAKE_BINARY_DIR}/lib/libmarias3.so.3.1.2
)
SET(S3_SOURCES ${S3API_DIR}/src/debug.c
${S3API_DIR}/src/error.c
${S3API_DIR}/src/marias3.c
${S3API_DIR}/src/request.c
${S3API_DIR}/src/response.c
${S3API_DIR}/src/sha256.c
${S3API_DIR}/src/sha256-internal.c
${S3API_DIR}/src/xml.c)
set(S3API_DEPS marias3 curl xml2 CACHE INTERNAL "S3API_DEPS")
ADD_LIBRARY(marias3 SHARED ${S3_SOURCES})
install(PROGRAMS
${CMAKE_BINARY_DIR}/lib/libmarias3.so.3.1.2
${CMAKE_BINARY_DIR}/lib/libmarias3.so.3
${CMAKE_BINARY_DIR}/lib/libmarias3.so
FIND_PACKAGE(CURL REQUIRED)
TARGET_LINK_LIBRARIES(marias3 curl)
INCLUDE_DIRECTORIES(${S3API_DIR})
set(S3API_DEPS marias3 curl CACHE INTERNAL "S3API_DEPS")
install(TARGETS marias3
DESTINATION ${ENGINE_LIBDIR}
COMPONENT columnstore-platform
)