You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-08 14:22:09 +03:00
libstdc++ in CI
This commit is contained in:
@@ -44,6 +44,7 @@ optparse.define short=f long=do-not-freeze-revision desc="Disable revision freez
|
||||
optparse.define short=g long=alien desc="Turn off maintainer mode (ex. -Werror)" variable=MAINTAINER_MODE default=true value=false
|
||||
optparse.define short=G long=draw-deps desc="Draw dependencies graph" variable=DRAW_DEPS default=false value=true
|
||||
optparse.define short=j long=parallel desc="Number of paralles for build" variable=CPUS default=$(getconf _NPROCESSORS_ONLN)
|
||||
optparse.define short=L long=libcpp desc="Build with libc++" variable=WITH_LIBCPP default=false value=true
|
||||
optparse.define short=M long=msan desc="Build with MSan" variable=MSAN default=false value=true
|
||||
optparse.define short=m long=skip-smoke desc="Skip final smoke test" variable=SKIP_SMOKE default=false value=true
|
||||
optparse.define short=N long=ninja desc="Build with ninja" variable=USE_NINJA default=false value=true
|
||||
@@ -403,6 +404,11 @@ construct_cmake_flags() {
|
||||
MDB_CMAKE_FLAGS+=(-DWITH_MSAN=ON -DCOLUMNSTORE_WITH_LIBCPP=YES -DWITH_COLUMNSTORE_REPORT_PATH=${REPORT_PATH})
|
||||
fi
|
||||
|
||||
if [[ $WITH_LIBCPP = true ]]; then
|
||||
warn "Building with libc++"
|
||||
MDB_CMAKE_FLAGS+=(-DCOLUMNSTORE_WITH_LIBCPP=YES)
|
||||
fi
|
||||
|
||||
if [[ $WITHOUT_COREDUMPS = true ]]; then
|
||||
warn "Cores are not dumped"
|
||||
else
|
||||
|
@@ -59,6 +59,9 @@ set(FLAGS_ALL
|
||||
-DHAVE_CONFIG_H
|
||||
-DBOOST_BIND_GLOBAL_PLACEHOLDERS
|
||||
)
|
||||
if(COLUMNSTORE_WITH_LIBCPP)
|
||||
list(APPEND FLAGS_ALL -stdlib=libc++)
|
||||
endif()
|
||||
|
||||
set(FLAGS_RELEASE -O3 -DDBUG_OFF)
|
||||
|
||||
|
@@ -33,14 +33,14 @@ set(THRIFT_INCLUDE_DIRS "${INSTALL_LOCATION}/include")
|
||||
set(THRIFT_LIBRARY_DIRS "${INSTALL_LOCATION}/lib")
|
||||
set(THRIFT_LIBRARY ${THRIFT_LIBRARY_DIRS}/${CMAKE_STATIC_LIBRARY_PREFIX}thrift${CMAKE_STATIC_LIBRARY_SUFFIX})
|
||||
|
||||
set(cxxflags "-fPIC")
|
||||
set(cxxflags -fPIC)
|
||||
|
||||
if(WITH_MSAN)
|
||||
set(cxxflags "${cxxflags} -fsanitize=memory -fsanitize-memory-track-origins -U_FORTIFY_SOURCE")
|
||||
set(cxxflags "'${cxxflags} -fsanitize=memory -fsanitize-memory-track-origins -U_FORTIFY_SOURCE -stdlib=libc++'")
|
||||
endif()
|
||||
|
||||
if(COLUMNSTORE_WITH_LIBCPP)
|
||||
set(cxxflags "${cxxflags} -stdlib=libc++")
|
||||
if(COLUMNSTORE_WITH_LIBCPP AND NOT DEFINED WITH_MSAN)
|
||||
set(cxxflags "'${cxxflags} -stdlib=libc++'")
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(
|
||||
@@ -62,16 +62,10 @@ ExternalProject_Add(
|
||||
-DBUILD_TUTORIALS=NO
|
||||
-DCMAKE_C_COMPILER=${CMAKE_C_COMPILER}
|
||||
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
|
||||
-DCMAKE_CXX_FLAGS:STRING="${cxxflags}"
|
||||
-DCMAKE_CXX_FLAGS:STRING=${cxxflags}
|
||||
-DBOOST_ROOT=${BOOST_ROOT}
|
||||
BUILD_BYPRODUCTS "${THRIFT_LIBRARY_DIRS}/${CMAKE_STATIC_LIBRARY_PREFIX}thrift${CMAKE_STATIC_LIBRARY_SUFFIX}"
|
||||
EXCLUDE_FROM_ALL TRUE
|
||||
)
|
||||
|
||||
ExternalProject_Add_Step(
|
||||
external_thrift print_cmake_flags
|
||||
COMMAND ${CMAKE_COMMAND} -E echo "!!!!!!!! CXX_FLAGS: ${CMAKE_CXX_FLAGS}"
|
||||
DEPENDEES configure
|
||||
)
|
||||
|
||||
add_dependencies(external_thrift external_boost)
|
||||
|
@@ -3,6 +3,7 @@
|
||||
#if (_LIBCPP_VERSION)
|
||||
#include <unordered_set>
|
||||
#include <unordered_map>
|
||||
#pragma message("libcpp do not support tr1, so we are using std::unordered_[set|map] instead")
|
||||
namespace std
|
||||
{
|
||||
namespace tr1
|
||||
@@ -15,6 +16,8 @@ using std::unordered_set;
|
||||
} // namespace tr1
|
||||
} // namespace std
|
||||
#else
|
||||
#pragma message("Using std::tr1::unordered_[set|map]")
|
||||
|
||||
#include <tr1/unordered_set>
|
||||
#include <tr1/unordered_map>
|
||||
#endif
|
@@ -9,10 +9,15 @@ if(WITH_UNITTESTS)
|
||||
cmake_policy(SET CMP0054 NEW)
|
||||
set(EXTERNAL_INSTALL_LOCATION ${CMAKE_BINARY_DIR}/external)
|
||||
set(cxxflags "")
|
||||
|
||||
if(WITH_MSAN)
|
||||
set(cxxflags "'${cxxflags} -fsanitize=memory -fsanitize-memory-track-origins -U_FORTIFY_SOURCE -stdlib=libc++'")
|
||||
endif()
|
||||
|
||||
if(COLUMNSTORE_WITH_LIBCPP AND NOT DEFINED WITH_MSAN)
|
||||
set(cxxflags "'${cxxflags} -stdlib=libc++'")
|
||||
endif()
|
||||
|
||||
ExternalProject_Add(
|
||||
googletest
|
||||
GIT_REPOSITORY https://github.com/google/googletest
|
||||
|
@@ -15,12 +15,8 @@
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
MA 02110-1301, USA. */
|
||||
|
||||
#include <sstream>
|
||||
#include <cstring>
|
||||
#include <typeinfo>
|
||||
#include "corr.h"
|
||||
#include "bytestream.h"
|
||||
#include "objectreader.h"
|
||||
|
||||
using namespace mcsv1sdk;
|
||||
|
||||
|
@@ -36,8 +36,6 @@
|
||||
#include <unordered.h>
|
||||
|
||||
#include "mcsv1_udaf.h"
|
||||
#include "calpontsystemcatalog.h"
|
||||
#include "windowfunctioncolumn.h"
|
||||
|
||||
#define EXPORT
|
||||
|
||||
|
Reference in New Issue
Block a user