-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new latest stable 10.4 // Update patches
- Loading branch information
Showing
9 changed files
with
365 additions
and
121 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
--- a/configure.cmake | ||
+++ b/configure.cmake | ||
@@ -135,10 +135,11 @@ | ||
IF(NOT LIBRT) | ||
MY_SEARCH_LIBS(clock_gettime rt LIBRT) | ||
ENDIF() | ||
+ MY_SEARCH_LIBS(__atomic_load_8 atomic LIBATOMIC) | ||
FIND_PACKAGE(Threads) | ||
|
||
SET(CMAKE_REQUIRED_LIBRARIES | ||
- ${LIBM} ${LIBNSL} ${LIBBIND} ${LIBCRYPT} ${LIBSOCKET} ${LIBDL} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT} ${LIBEXECINFO}) | ||
+ ${LIBM} ${LIBNSL} ${LIBBIND} ${LIBCRYPT} ${LIBSOCKET} ${LIBDL} ${LIBATOMIC} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT} ${LIBEXECINFO}) | ||
# Need explicit pthread for gcc -fsanitize=address | ||
IF(CMAKE_USE_PTHREADS_INIT AND CMAKE_C_FLAGS MATCHES "-fsanitize=") | ||
SET(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} pthread) | ||
@@ -919,14 +920,26 @@ | ||
return 0; | ||
}" | ||
HAVE_GCC_ATOMIC_BUILTINS) | ||
-CHECK_CXX_SOURCE_COMPILES(" | ||
+ | ||
+SET(MAIN__ATOMIC_LOAD_N " | ||
int main() | ||
{ | ||
long long int var= 1; | ||
long long int *ptr= &var; | ||
return (int)__atomic_load_n(ptr, __ATOMIC_SEQ_CST); | ||
-}" | ||
-HAVE_GCC_C11_ATOMICS) | ||
+}") | ||
+CHECK_CXX_SOURCE_COMPILES("${MAIN__ATOMIC_LOAD_N}" HAVE_GCC_C11_ATOMICS) | ||
+IF(HAVE_GCC_C11_ATOMICS AND HAVE_LIBATOMIC) | ||
+ SET(SAVE_CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES}) | ||
+ LIST(REMOVE_ITEM CMAKE_REQUIRED_LIBRARIES "${LIBATOMIC}") | ||
+ CHECK_CXX_SOURCE_COMPILES("${MAIN__ATOMIC_LOAD_N}" HAVE_GCC_C11_INLINE_ATOMICS) | ||
+ IF(HAVE_GCC_C11_INLINE_ATOMICS) | ||
+ UNSET(HAVE_LIBATOMIC) | ||
+ UNSET(LIBATOMIC) | ||
+ ELSE() | ||
+ SET(CMAKE_REQUIRED_LIBRARIES ${SAVE_CMAKE_REQUIRED_LIBRARIES}) | ||
+ ENDIF() | ||
+ENDIF() | ||
|
||
IF(WITH_VALGRIND) | ||
SET(HAVE_valgrind 1) | ||
--- a/mysys/CMakeLists.txt | ||
+++ b/mysys/CMakeLists.txt | ||
@@ -75,7 +75,7 @@ | ||
|
||
ADD_CONVENIENCE_LIBRARY(mysys ${MYSYS_SOURCES}) | ||
TARGET_LINK_LIBRARIES(mysys dbug strings ${ZLIB_LIBRARY} | ||
- ${LIBNSL} ${LIBM} ${LIBRT} ${LIBDL} ${LIBSOCKET} ${LIBEXECINFO} ${CRC32_LIBRARY}) | ||
+ ${LIBNSL} ${LIBM} ${LIBRT} ${LIBDL} ${LIBATOMIC} ${LIBSOCKET} ${LIBEXECINFO} ${CRC32_LIBRARY}) | ||
DTRACE_INSTRUMENT(mysys) | ||
|
||
IF(HAVE_BFD_H) | ||
--- a/storage/rocksdb/build_rocksdb.cmake | ||
+++ b/storage/rocksdb/build_rocksdb.cmake | ||
@@ -142,7 +142,7 @@ | ||
if(WIN32) | ||
set(SYSTEM_LIBS ${SYSTEM_LIBS} Shlwapi.lib Rpcrt4.lib) | ||
else() | ||
- set(SYSTEM_LIBS ${CMAKE_THREAD_LIBS_INIT} ${LIBRT}) | ||
+ set(SYSTEM_LIBS ${LIBATOMIC} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT}) | ||
endif() | ||
|
||
set(ROCKSDB_LIBS rocksdblib}) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- a/cmake/pcre.cmake | ||
+++ b/cmake/pcre.cmake | ||
@@ -8,11 +8,7 @@ | ||
CHECK_LIBRARY_EXISTS(pcre pcre_stack_guard "" HAVE_PCRE_STACK_GUARD) | ||
IF(NOT CMAKE_CROSSCOMPILING) | ||
SET(CMAKE_REQUIRED_LIBRARIES "pcre") | ||
- CHECK_C_SOURCE_RUNS(" | ||
- #include <pcre.h> | ||
- int main() { | ||
- return -pcre_exec(NULL, NULL, NULL, -999, -999, 0, NULL, 0) < 256; | ||
- }" PCRE_STACK_SIZE_OK) | ||
+ SET(PCRE_STACK_SIZE_OK TRUE) | ||
SET(CMAKE_REQUIRED_LIBRARIES) | ||
ENDIF() | ||
ENDIF() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
--- a/configure.cmake | ||
+++ b/configure.cmake | ||
@@ -135,10 +135,11 @@ | ||
IF(NOT LIBRT) | ||
MY_SEARCH_LIBS(clock_gettime rt LIBRT) | ||
ENDIF() | ||
+ MY_SEARCH_LIBS(__atomic_load_8 atomic LIBATOMIC) | ||
FIND_PACKAGE(Threads) | ||
|
||
SET(CMAKE_REQUIRED_LIBRARIES | ||
- ${LIBM} ${LIBNSL} ${LIBBIND} ${LIBCRYPT} ${LIBSOCKET} ${LIBDL} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT} ${LIBEXECINFO}) | ||
+ ${LIBM} ${LIBNSL} ${LIBBIND} ${LIBCRYPT} ${LIBSOCKET} ${LIBDL} ${LIBATOMIC} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT} ${LIBEXECINFO}) | ||
# Need explicit pthread for gcc -fsanitize=address | ||
IF(CMAKE_USE_PTHREADS_INIT AND CMAKE_C_FLAGS MATCHES "-fsanitize=") | ||
SET(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} pthread) | ||
@@ -919,14 +920,26 @@ | ||
return 0; | ||
}" | ||
HAVE_GCC_ATOMIC_BUILTINS) | ||
-CHECK_CXX_SOURCE_COMPILES(" | ||
+ | ||
+SET(MAIN__ATOMIC_LOAD_N " | ||
int main() | ||
{ | ||
long long int var= 1; | ||
long long int *ptr= &var; | ||
return (int)__atomic_load_n(ptr, __ATOMIC_SEQ_CST); | ||
-}" | ||
-HAVE_GCC_C11_ATOMICS) | ||
+}") | ||
+CHECK_CXX_SOURCE_COMPILES("${MAIN__ATOMIC_LOAD_N}" HAVE_GCC_C11_ATOMICS) | ||
+IF(HAVE_GCC_C11_ATOMICS AND HAVE_LIBATOMIC) | ||
+ SET(SAVE_CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES}) | ||
+ LIST(REMOVE_ITEM CMAKE_REQUIRED_LIBRARIES "${LIBATOMIC}") | ||
+ CHECK_CXX_SOURCE_COMPILES("${MAIN__ATOMIC_LOAD_N}" HAVE_GCC_C11_INLINE_ATOMICS) | ||
+ IF(HAVE_GCC_C11_INLINE_ATOMICS) | ||
+ UNSET(HAVE_LIBATOMIC) | ||
+ UNSET(LIBATOMIC) | ||
+ ELSE() | ||
+ SET(CMAKE_REQUIRED_LIBRARIES ${SAVE_CMAKE_REQUIRED_LIBRARIES}) | ||
+ ENDIF() | ||
+ENDIF() | ||
|
||
IF(WITH_VALGRIND) | ||
SET(HAVE_valgrind 1) | ||
--- a/mysys/CMakeLists.txt | ||
+++ b/mysys/CMakeLists.txt | ||
@@ -75,7 +75,7 @@ | ||
|
||
ADD_CONVENIENCE_LIBRARY(mysys ${MYSYS_SOURCES}) | ||
TARGET_LINK_LIBRARIES(mysys dbug strings ${ZLIB_LIBRARY} | ||
- ${LIBNSL} ${LIBM} ${LIBRT} ${LIBDL} ${LIBSOCKET} ${LIBEXECINFO} ${CRC32_LIBRARY}) | ||
+ ${LIBNSL} ${LIBM} ${LIBRT} ${LIBDL} ${LIBATOMIC} ${LIBSOCKET} ${LIBEXECINFO} ${CRC32_LIBRARY}) | ||
DTRACE_INSTRUMENT(mysys) | ||
|
||
IF(HAVE_BFD_H) | ||
--- a/storage/rocksdb/build_rocksdb.cmake | ||
+++ b/storage/rocksdb/build_rocksdb.cmake | ||
@@ -142,7 +142,7 @@ | ||
if(WIN32) | ||
set(SYSTEM_LIBS ${SYSTEM_LIBS} Shlwapi.lib Rpcrt4.lib) | ||
else() | ||
- set(SYSTEM_LIBS ${CMAKE_THREAD_LIBS_INIT} ${LIBRT}) | ||
+ set(SYSTEM_LIBS ${LIBATOMIC} ${CMAKE_THREAD_LIBS_INIT} ${LIBRT}) | ||
endif() | ||
|
||
set(ROCKSDB_LIBS rocksdblib}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- a/cmake/pcre.cmake | ||
+++ b/cmake/pcre.cmake | ||
@@ -8,11 +8,7 @@ | ||
CHECK_LIBRARY_EXISTS(pcre pcre_stack_guard "" HAVE_PCRE_STACK_GUARD) | ||
IF(NOT CMAKE_CROSSCOMPILING) | ||
SET(CMAKE_REQUIRED_LIBRARIES "pcre") | ||
- CHECK_C_SOURCE_RUNS(" | ||
- #include <pcre.h> | ||
- int main() { | ||
- return -pcre_exec(NULL, NULL, NULL, -999, -999, 0, NULL, 0) < 256; | ||
- }" PCRE_STACK_SIZE_OK) | ||
+ SET(PCRE_STACK_SIZE_OK TRUE) | ||
SET(CMAKE_REQUIRED_LIBRARIES) | ||
ENDIF() | ||
ENDIF() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
[mysqld_safe] | ||
|
||
[mysqldump] | ||
quick | ||
quote-names | ||
max_allowed_packet = {{ getenv "MYSQL_DUMP_MAX_ALLOWED_PACKET" "1G" }} | ||
|
||
[mysqlhotcopy] | ||
interactive-timeout | ||
|
||
[client] | ||
port = {{ getenv "MYSQL_PORT" "3306" }} | ||
socket = /var/run/mysqld/mysqld.sock | ||
default-character-set = {{ getenv "MYSQL_CLIENT_DEFAULT_CHARACTER_SET" "utf8" }} | ||
|
||
{{ if getenv "MARIADB_PLUGIN_LOAD" }} | ||
[mariadb] | ||
plugin_load = {{ getenv "MARIADB_PLUGIN_LOAD" }} | ||
{{ end }} | ||
|
||
[mysqld] | ||
user = mysql | ||
bind-address = 0.0.0.0 | ||
basedir = /usr | ||
datadir = /var/lib/mysql | ||
connect_timeout = {{ getenv "MYSQL_CONNECT_TIMEOUT" "10" }} | ||
socket = /var/run/mysqld/mysqld.sock | ||
log-warnings | ||
|
||
collation-server = {{ getenv "MYSQL_COLLATION_SERVER" "utf8_unicode_ci" }} | ||
init_connect = '{{ getenv "MYSQL_INIT_CONNECT" "SET NAMES utf8" }}' | ||
character_set_server = {{ getenv "MYSQL_CHARACTER_SET_SERVER" "utf8" }} | ||
character_set_filesystem = {{ getenv "MYSQL_CHARACTER_SET_FILESYSTEM" "utf8" }} | ||
|
||
symbolic-links = 0 | ||
default_storage_engine = {{ getenv "MYSQL_DEFAULT_STORAGE_ENGINE" "InnoDB" }} | ||
|
||
skip-character-set-client-handshake | ||
skip-name-resolve | ||
|
||
back_log = {{ getenv "MYSQL_BACK_LOG" "100" }} | ||
|
||
join_buffer_size = {{ getenv "MYSQL_JOIN_BUFFER_SIZE" "8M" }} | ||
max_heap_table_size = {{ getenv "MYSQL_MAX_HEAP_TABLE_SIZE" "16M" }} | ||
query_cache_limit = {{ getenv "MYSQL_QUERY_CACHE_LIMIT" "1M" }} | ||
query_cache_min_res_unit = {{ getenv "MYSQL_QUERY_CACHE_MIN_RES_UNIT" "4K" }} | ||
query_cache_size = {{ getenv "MYSQL_QUERY_CACHE_SIZE" "128M" }} | ||
query_cache_type = {{ getenv "MYSQL_QUERY_CACHE_TYPE" "ON" }} | ||
sort_buffer_size = {{ getenv "MYSQL_SORT_BUFFER_SIZE" "2M" }} | ||
table_definition_cache = {{ getenv "MYSQL_TABLE_DEFINITION_CACHE" "400" }} | ||
table_open_cache = {{ getenv "MYSQL_TABLE_OPEN_CACHE" "4096" }} | ||
thread_cache_size = {{ getenv "MYSQL_THREAD_CACHE_SIZE" "75" }} | ||
tmp_table_size = {{ getenv "MYSQL_TMP_TABLE_SIZE" "16M" }} | ||
|
||
max_allowed_packet = {{ getenv "MYSQL_MAX_ALLOWED_PACKET" "256M" }} | ||
max_connect_errors = {{ getenv "MYSQL_MAX_CONNECT_ERRORS" "100000" }} | ||
max_connections = {{ getenv "MYSQL_MAX_CONNECTIONS" "100" }} | ||
|
||
innodb_buffer_pool_instances = {{ getenv "MYSQL_INNODB_BUFFER_POOL_INSTANCES" "1" }} | ||
innodb_buffer_pool_size = {{ getenv "MYSQL_INNODB_BUFFER_POOL_SIZE" "128M" }} | ||
innodb_data_file_path = {{ getenv "MYSQL_INNODB_DATA_FILE_PATH" "ibdata1:10M:autoextend:max:10G" }} | ||
innodb_default_row_format = {{ getenv "MYSQL_INNODB_DEFAULT_ROW_FORMAT" "dynamic" }} | ||
innodb_fast_shutdown = {{ getenv "MYSQL_INNODB_FAST_SHUTDOWN" "1" }} | ||
innodb_file_per_table = {{ getenv "MYSQL_INNODB_FILE_PER_TABLE" "1" }} | ||
innodb_flush_log_at_trx_commit = {{ getenv "MYSQL_INNODB_FLUSH_LOG_AT_TRX_COMMIT" "2" }} | ||
innodb_flush_method = {{ getenv "MYSQL_INNODB_FLUSH_METHOD" "O_DIRECT" }} | ||
innodb_force_load_corrupted = {{ getenv "MYSQL_INNODB_FORCE_LOAD_CORRUPTED" "0" }} | ||
innodb_force_recovery = {{ getenv "MYSQL_INNODB_FORCE_RECOVERY" "0" }} | ||
innodb_io_capacity = {{ getenv "MYSQL_INNODB_IO_CAPACITY" "200" }} | ||
innodb_lock_wait_timeout = {{ getenv "MYSQL_INNODB_LOCK_WAIT_TIMEOUT" "50" }} | ||
innodb_log_buffer_size = {{ getenv "MYSQL_INNODB_LOG_BUFFER_SIZE" "8M" }} | ||
innodb_log_file_size = {{ getenv "MYSQL_INNODB_LOG_FILE_SIZE" "128M" }} | ||
innodb_log_files_in_group = {{ getenv "MYSQL_INNODB_LOG_FILES_IN_GROUP" "2" }} | ||
innodb_old_blocks_time = {{ getenv "MYSQL_INNODB_OLD_BLOCKS_TIME" "1000" }} | ||
innodb_open_files = {{ getenv "MYSQL_INNODB_OPEN_FILES" "1024" }} | ||
innodb_purge_threads = {{ getenv "MYSQL_INNODB_PURGE_THREADS" "4" }} | ||
innodb_read_io_threads = {{ getenv "MYSQL_INNODB_READ_IO_THREADS" "4" }} | ||
innodb_stats_on_metadata = {{ getenv "MYSQL_INNODB_STATS_ON_METADATA" "OFF" }} | ||
innodb_strict_mode = {{ getenv "MYSQL_INNODB_STRICT_MODE" "OFF" }} | ||
innodb_write_io_threads = {{ getenv "MYSQL_INNODB_WRITE_IO_THREADS" "4" }} | ||
|
||
performance_schema = {{ getenv "MYSQL_PERFORMANCE_SCHEMA" "OFF" }} | ||
|
||
long_query_time = {{ getenv "MYSQL_LONG_QUERY_TIME" "2" }} | ||
slow_query_log = {{ getenv "MYSQL_SLOW_QUERY_LOG" "OFF" }} | ||
general_log = {{ getenv "MYSQL_GENERAL_LOG" "0" }} | ||
|
||
log_warnings = {{ getenv "MYSQL_LOG_WARNINGS" "2" }} | ||
|
||
net_write_timeout = {{ getenv "MYSQL_NET_WRITE_TIMEOUT" "90" }} | ||
net_read_timeout = {{ getenv "MYSQL_NET_READ_TIMEOUT" "90" }} | ||
wait_timeout = {{ getenv "MYSQL_WAIT_TIMEOUT" "420" }} | ||
interactive_timeout = {{ getenv "MYSQL_INTERACTIVE_TIMEOUT" "420" }} | ||
|
||
relay_log_recovery = {{ getenv "MYSQL_RELAY_LOG_RECOVERY" "0" }} | ||
|
||
optimizer_prune_level = {{ getenv "MYSQL_OPTIMIZER_PRUNE_LEVEL" "1" }} | ||
optimizer_search_depth = {{ getenv "MYSQL_OPTIMIZER_SEARCH_DEPTH" "62" }} |
Oops, something went wrong.