Skip to content

Commit

Permalink
chore: Update build-mysql-darwin.sh to support MySQL 8.0 or later
Browse files Browse the repository at this point in the history
  • Loading branch information
shogo82148 committed Jul 6, 2024
1 parent e7144e7 commit 75d4982
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions .github/build-mysql-darwin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,16 @@ esac
PREFIX=$RUNNER_TOOL_CACHE/mysql/$MYSQL_VERSION/$MYSQL_ARCH
export LDFLAGS=-Wl,-rpath,$PREFIX/lib

# install LLVM
brew install llvm@17
LLVM_PATH=$(brew --prefix llvm@17)
export PATH="$LLVM_PATH/bin:$PATH"
export LDFLAGS="$LDFLAGS -L$LLVM_PATH/lib"
export CPPFLAGS="$CPPFLAGS -I$LLVM_PATH/include"
export CC=$LLVM_PATH/bin/clang
export CXX=$LLVM_PATH/bin/clang++
if [[ "$MYSQL_VERSION" =~ ^[89][.] ]]; then # MySQL 8.0 or later
# install LLVM
brew install llvm@17
LLVM_PATH=$(brew --prefix llvm@17)
export PATH="$LLVM_PATH/bin:$PATH"
export LDFLAGS="$LDFLAGS -L$LLVM_PATH/lib"
export CPPFLAGS="$CPPFLAGS -I$LLVM_PATH/include"
export CC=$LLVM_PATH/bin/clang
export CXX=$LLVM_PATH/bin/clang++
fi

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

0 comments on commit 75d4982

Please sign in to comment.