mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
fix(osx): create /usr/local/sbin directory for brew package installation
ffmpeg dependency unbound attempts to symlink to /usr/local/sbin, failing if the directory does not exist. /usr/local/sbin does not exist by default on 10.13 High Sierra, so prompt to create it if it doesn't exit, and create it for travis CI automatically.
This commit is contained in:
parent
8e597ed736
commit
e97b270584
|
@ -92,6 +92,26 @@ install() {
|
|||
read -n1 -rsp $'Press any key to continue or Ctrl+C to exit...\n'
|
||||
fi
|
||||
|
||||
# osx 10.13 High Sierra doesn't come with a /usr/local/sbin, yet it is needed by some brew packages
|
||||
NEEDED_DEP_DIR="/usr/local/sbin"
|
||||
if [[ $TRAVIS = true ]]
|
||||
then
|
||||
sudo mkdir -p $NEEDED_DEP_DIR
|
||||
sudo chown -R $(whoami) $NEEDED_DEP_DIR
|
||||
elif [[ ! -d $NEEDED_DEP_DIR ]]
|
||||
then
|
||||
fcho "The direcory $NEEDED_DEP_DIR must exist for some development packages."
|
||||
read -r -p "Would you like to create it now, and set the owner to $(whoami)? [y/N] " response
|
||||
if [[ $response =~ ^([yY][eE][sS]|[yY])$ ]]
|
||||
then
|
||||
sudo mkdir $NEEDED_DEP_DIR
|
||||
sudo chown -R $(whoami) $NEEDED_DEP_DIR
|
||||
else
|
||||
fcho "Cannot proceed without $NEEDED_DEP_DIR. Exiting."
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
|
||||
#fcho "Installing x-code Command line tools ..."
|
||||
#xcode-select --install
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user