Skip to content

Commit 36a2a18

Browse files
Brave Galera Crewsvoj
authored andcommitted
Galera4
1 parent 382115b commit 36a2a18

File tree

791 files changed

+27581
-8411
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

791 files changed

+27581
-8411
lines changed

.gitmodules

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,7 @@
44
[submodule "storage/rocksdb/rocksdb"]
55
path = storage/rocksdb/rocksdb
66
url = https://github.com/facebook/rocksdb.git
7+
[submodule "wsrep-lib"]
8+
path = wsrep-lib
9+
url = https://github.com/codership/wsrep-lib.git
10+
branch = master

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ INCLUDE(misc)
143143
INCLUDE(mysql_version)
144144
INCLUDE(cpack_source_ignore_files)
145145
INCLUDE(install_layout)
146+
INCLUDE(submodules)
146147
INCLUDE(wsrep)
147148
INCLUDE(cpack_rpm)
148149
INCLUDE(cpack_deb)
@@ -377,7 +378,6 @@ ENDIF()
377378

378379
SET (MYSQLD_STATIC_PLUGIN_LIBS "" CACHE INTERNAL "")
379380

380-
INCLUDE(submodules)
381381
INCLUDE(mariadb_connector_c) # this does ADD_SUBDIRECTORY(libmariadb)
382382

383383
# Add storage engines and plugins.
@@ -405,7 +405,7 @@ IF(NOT WITHOUT_SERVER)
405405
ENDIF(WITH_EMBEDDED_SERVER)
406406

407407
IF(WITH_WSREP)
408-
ADD_SUBDIRECTORY(wsrep)
408+
ADD_SUBDIRECTORY(wsrep-lib)
409409
ENDIF()
410410

411411
ADD_SUBDIRECTORY(mysql-test)

cmake/cpack_rpm.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ SETA(CPACK_RPM_server_PACKAGE_REQUIRES
171171

172172
IF(WITH_WSREP)
173173
SETA(CPACK_RPM_server_PACKAGE_REQUIRES
174-
"galera" "rsync" "lsof" "grep" "gawk" "iproute"
174+
"galera-4" "rsync" "lsof" "grep" "gawk" "iproute"
175175
"coreutils" "findutils" "tar")
176176
ENDIF()
177177

cmake/make_dist.cmake.in

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,14 @@ IF(GIT_EXECUTABLE)
5050
IF(NOT RESULT EQUAL 0)
5151
SET(GIT_EXECUTABLE)
5252
ENDIF()
53+
EXECUTE_PROCESS(
54+
COMMAND "${GIT_EXECUTABLE}" submodule foreach "${GIT_EXECUTABLE} checkout-index --all --prefix=${PACKAGE_DIR}/wsrep-lib/$path/"
55+
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/wsrep-lib
56+
RESULT_VARIABLE RESULT
57+
)
58+
IF(NOT RESULT EQUAL 0)
59+
SET(GIT_EXECUTABLE)
60+
ENDIF()
5361
ENDIF()
5462

5563
CONFIGURE_FILE(${CMAKE_BINARY_DIR}/include/source_revision.h

cmake/submodules.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,16 @@ IF(GIT_EXECUTABLE AND EXISTS "${CMAKE_SOURCE_DIR}/.git")
1414
SET(update_result 0)
1515
ELSEIF (cmake_update_submodules MATCHES force)
1616
MESSAGE(STATUS "Updating submodules (forced)")
17-
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule update --init --force
17+
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule update --init --force --recursive
1818
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
1919
RESULT_VARIABLE update_result)
2020
ELSEIF (cmake_update_submodules MATCHES yes)
21-
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule update --init
21+
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule update --init --recursive
2222
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
2323
RESULT_VARIABLE update_result)
2424
ELSE()
2525
MESSAGE(STATUS "Updating submodules")
26-
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule update --init
26+
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule update --init --recursive
2727
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
2828
RESULT_VARIABLE update_result)
2929
ENDIF()

cmake/wsrep.cmake

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,15 @@ ELSE()
2424
ENDIF()
2525

2626
OPTION(WITH_WSREP "WSREP replication API (to use, e.g. Galera Replication library)" ${with_wsrep_default})
27+
OPTION(WITH_WSREP_ALL
28+
"Build all components of WSREP (unit tests, sample programs)"
29+
OFF)
2730

2831
# Set the patch version
29-
SET(WSREP_PATCH_VERSION "23")
32+
SET(WSREP_PATCH_VERSION "22")
3033

3134
# Obtain wsrep API version
32-
FILE(STRINGS "${MySQL_SOURCE_DIR}/wsrep/wsrep_api.h" WSREP_API_VERSION
35+
FILE(STRINGS "${CMAKE_SOURCE_DIR}/wsrep-lib/wsrep-API/v26/wsrep_api.h" WSREP_API_VERSION
3336
LIMIT_COUNT 1 REGEX "WSREP_INTERFACE_VERSION")
3437
STRING(REGEX MATCH "([0-9]+)" WSREP_API_VERSION "${WSREP_API_VERSION}")
3538

@@ -40,4 +43,12 @@ SET(WSREP_PROC_INFO ${WITH_WSREP})
4043

4144
IF(WITH_WSREP)
4245
SET(WSREP_PATCH_VERSION "wsrep_${WSREP_VERSION}")
46+
if (NOT WITH_WSREP_ALL)
47+
SET(WSREP_LIB_WITH_UNIT_TESTS OFF CACHE BOOL
48+
"Disable unit tests for wsrep-lib")
49+
SET(WSREP_LIB_WITH_DBSIM OFF CACHE BOOL
50+
"Disable building dbsim for wsrep-lib")
51+
endif()
52+
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/wsrep-lib/include)
53+
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/wsrep-lib/wsrep-API/v26)
4354
ENDIF()

debian/control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ Recommends: libhtml-template-perl
430430
Pre-Depends: adduser (>= 3.40),
431431
debconf,
432432
mariadb-common (>= ${source:Version})
433-
Depends: galera-3 (>=25.3),
433+
Depends: galera-4 (>=26.4),
434434
gawk,
435435
iproute | iproute2,
436436
libdbi-perl,

extra/mariabackup/CMakeLists.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,6 @@ IF(NOT HAVE_SYSTEM_REGEX)
4040
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/pcre)
4141
ENDIF()
4242

43-
IF(WITH_WSREP)
44-
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/wsrep)
45-
ENDIF()
4643

4744
ADD_DEFINITIONS(-UMYSQL_SERVER)
4845
########################################################################

0 commit comments

Comments
 (0)