mirror of
https://github.com/shivammathur/setup-php.git
synced 2024-11-22 11:51:07 +07:00
Add unixodbc if missing in sqlsrv setup
This commit is contained in:
parent
16de39288a
commit
fe9e23a16a
@ -7,9 +7,18 @@ get_sqlsrv_version() {
|
||||
fi
|
||||
}
|
||||
|
||||
add_unixodbc() {
|
||||
if [ "$(uname -s)" = 'Linux' ]; then
|
||||
install_packages unixodbc-dev
|
||||
else
|
||||
brew install unixodbc
|
||||
fi
|
||||
}
|
||||
|
||||
# Function to install sqlsrv and pdo_sqlsrv.
|
||||
add_sqlsrv() {
|
||||
ext=$1
|
||||
ext_version=$(get_sqlsrv_version)
|
||||
add_unixodbc >/dev/null 2>&1
|
||||
add_pecl_extension "$ext" "$ext_version" extension
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user