Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MySQL 9.0 is released #1085

Merged
merged 14 commits into from
Jul 6, 2024
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion .github/build-mysql-darwin-macos14.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@ esac
PREFIX=$RUNNER_TOOL_CACHE/mysql/$MYSQL_VERSION/$MYSQL_ARCH
export LDFLAGS=-Wl,-rpath,$PREFIX/lib

# use the latest version of clang
brew install llvm@17
CC=$(brew --prefix llvm@17)/bin/clang
export CC
CXX=$(brew --prefix llvm@17)/bin/clang++
export CXX

# detect the number of CPU Core
JOBS=$(sysctl -n hw.logicalcpu_max)

Expand All @@ -34,7 +41,7 @@ ACTION_VERSION=$(jq -r '.version' < "$ROOT/../package.json")

# system SSL/TLS library is too old. so we use custom build.

if [[ "$MYSQL_VERSION" =~ ^8[.] ]]; then # MySQL 8.0 or later
if [[ "$MYSQL_VERSION" =~ ^[89][.] ]]; then # MySQL 8.0 or later
# build OpenSSL v3
export OPENSSL_VERSION=$OPENSSL_VERSION3
echo "::group::download OpenSSL source"
Expand Down
7 changes: 4 additions & 3 deletions .github/build-mysql-darwin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,10 @@ PREFIX=$RUNNER_TOOL_CACHE/mysql/$MYSQL_VERSION/$MYSQL_ARCH
export LDFLAGS=-Wl,-rpath,$PREFIX/lib

# use the latest version of clang installed
CC=$(brew --prefix llvm@15)/bin/clang
brew install llvm@17
CC=$(brew --prefix llvm@17)/bin/clang
export CC
CXX=$(brew --prefix llvm@15)/bin/clang++
CXX=$(brew --prefix llvm@17)/bin/clang++
export CXX

# detect the number of CPU Core
Expand All @@ -40,7 +41,7 @@ ACTION_VERSION=$(jq -r '.version' < "$ROOT/../package.json")

# system SSL/TLS library is too old. so we use custom build.

if [[ "$MYSQL_VERSION" =~ ^8[.] ]]; then # MySQL 8.0 or later
if [[ "$MYSQL_VERSION" =~ ^[89][.] ]]; then # MySQL 8.0 or later
# build OpenSSL v3
export OPENSSL_VERSION=$OPENSSL_VERSION3
echo "::group::download OpenSSL source"
Expand Down
2 changes: 1 addition & 1 deletion .github/build-mysql-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ ACTION_VERSION=$(jq -r '.version' < "$ROOT/../package.json")

# system SSL/TLS library is too old. so we use custom build.

if [[ "$MYSQL_VERSION" =~ ^8[.] ]]; then # MySQL 8.0 or later
if [[ "$MYSQL_VERSION" =~ ^[89][.] ]]; then # MySQL 8.0 or later
# build OpenSSL v3
export OPENSSL_VERSION=$OPENSSL_VERSION3
echo "::group::download OpenSSL source"
Expand Down
2 changes: 1 addition & 1 deletion .github/build-mysql-windows.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ if ( $MYSQL_VERSION -match '^8[.]') # MySQL 8.0 or later

# Bison
Write-Host "::group::Set up Bison"
if ( $MYSQL_VERSION -match '^8[.]' ) # MySQL 8.0 or later
if ( $MYSQL_VERSION -match '^[89][.]' ) # MySQL 8.0 or later
{
choco install winflexbison3
}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
- windows-2022
- windows-2019
mysql:
- "9.0"
- "8.4"
- "8.3"
- "8.2"
Expand Down Expand Up @@ -120,7 +121,7 @@
- run: npm run build
- name: use the action
id: action
uses: ./

Check warning on line 124 in .github/workflows/test.yml

View workflow job for this annotation

GitHub Actions / actionlint

[actionlint] reported by reviewdog 🐶 file "lib/setup-mysql.js" does not exist in "/github/workspace". it is specified at "main" key in "runs" section in "actions-setup-mysql" action [action] Raw Output: .github/workflows/test.yml:124:15: file "lib/setup-mysql.js" does not exist in "/github/workspace". it is specified at "main" key in "runs" section in "actions-setup-mysql" action [action]

Check warning on line 124 in .github/workflows/test.yml

View workflow job for this annotation

GitHub Actions / actionlint

[actionlint] reported by reviewdog 🐶 file "lib/cleanup-mysql.js" does not exist in "/github/workspace". it is specified at "post" key in "runs" section in "actions-setup-mysql" action [action] Raw Output: .github/workflows/test.yml:124:15: file "lib/cleanup-mysql.js" does not exist in "/github/workspace". it is specified at "post" key in "runs" section in "actions-setup-mysql" action [action]
with:
mysql-version: "8.3"
root-password: very-very-secret
Expand Down
79 changes: 79 additions & 0 deletions patches/mysql/9.0.0/skip-install-pdb.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
diff --git a/cmake/install_macros.cmake b/cmake/install_macros.cmake
index 859715a45c4..3d5c8064531 100644
--- a/cmake/install_macros.cmake
+++ b/cmake/install_macros.cmake
@@ -22,33 +22,8 @@

# For windows: install .pdb file for each target.
MACRO(INSTALL_DEBUG_SYMBOLS target)
- IF(MSVC)
- GET_TARGET_PROPERTY(type ${target} TYPE)
- IF(NOT INSTALL_LOCATION)
- IF(type MATCHES "STATIC_LIBRARY"
- OR type MATCHES "MODULE_LIBRARY"
- OR type MATCHES "SHARED_LIBRARY")
- SET(INSTALL_LOCATION "lib")
- ELSEIF(type MATCHES "EXECUTABLE")
- SET(INSTALL_LOCATION "bin")
- ELSE()
- MESSAGE(FATAL_ERROR
- "cannot determine type of ${target}. Don't now where to install")
- ENDIF()
- ENDIF()
-
- IF(target STREQUAL "mysqld" OR target STREQUAL "mysqlbackup")
- SET(comp Server)
- ELSE()
- SET(comp Debuginfo)
- ENDIF()
-
- # No .pdb file for static libraries.
- IF(NOT type MATCHES "STATIC_LIBRARY")
- INSTALL(FILES $<TARGET_PDB_FILE:${target}>
- DESTINATION ${INSTALL_LOCATION} COMPONENT ${comp})
- ENDIF()
- ENDIF()
+# .pdb files are too large to use in GitHub Actions.
+# so skip installing
ENDMACRO()


@@ -282,24 +257,7 @@
MESSAGE(STATUS "Changing RPATH when installing ${debug_target_location}")
ENDIF()
ENDIF()
-
- # For windows, install .pdb files for .exe and .dll files.
- IF(MSVC AND NOT target_type STREQUAL "STATIC_LIBRARY")
- GET_FILENAME_COMPONENT(ext ${debug_target_location} EXT)
- STRING(REPLACE "${ext}" ".pdb"
- debug_pdb_target_location "${debug_target_location}" )
- IF (RENAME_PARAM)
- STRING(REPLACE "${ext}" ".pdb" pdb_rename "${ARG_RENAME}")
- SET(PDB_RENAME_PARAM RENAME "${pdb_rename}")
- ENDIF()

- INSTALL(FILES ${debug_pdb_target_location}
- DESTINATION ${ARG_DESTINATION}
- ${PDB_RENAME_PARAM}
- CONFIGURATIONS Release RelWithDebInfo
- COMPONENT ${ARG_COMPONENT}
- OPTIONAL)
- ENDIF()
ENDFUNCTION(INSTALL_DEBUG_TARGET)


diff --git a/router/cmake/Plugin.cmake b/router/cmake/Plugin.cmake
index 30ba9fa7eaf..4b49751a124 100644
--- a/router/cmake/Plugin.cmake
+++ b/router/cmake/Plugin.cmake
@@ -150,9 +150,6 @@ FUNCTION(add_harness_plugin NAME)
INSTALL(TARGETS ${NAME}
RUNTIME DESTINATION ${_option_DESTINATION}
COMPONENT Router)
- INSTALL(FILES $<TARGET_PDB_FILE:${NAME}>
- DESTINATION ${_option_DESTINATION}
- COMPONENT Router)
ELSE()
INSTALL(TARGETS ${NAME}
LIBRARY DESTINATION ${_option_DESTINATION}
2 changes: 1 addition & 1 deletion t/ssl.t
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ use File::Spec;
my ($version, $distribution) = detect_version('root', 'very-very-secret');
my @ssl_options = ('--ssl');
if ($distribution eq 'mysql') {
if ($version =~ /^(?:8\.[0-9]\.|5\.7\.)/) {
if ($version =~ /^(?:[1-9][0-9]\.|[89]\.|5\.7\.)/) {
# --ssl-mode is available from MySQL 5.7
@ssl_options = ('--ssl-mode=REQUIRED');
} else {
Expand Down
1 change: 1 addition & 0 deletions versions/mysql.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[
"9.0.0",
"8.4.0",
"8.3.0",
"8.2.0",
Expand Down
Loading