1
1
mirror of https://github.com/qvacua/vimr.git synced 2024-11-28 11:35:35 +03:00
vimr/bin/build_libnvim.sh

29 lines
1.1 KiB
Bash
Raw Normal View History

2017-05-08 23:03:33 +03:00
#!/bin/bash
2019-12-22 23:45:42 +03:00
set -Eeuo pipefail
2017-05-08 23:03:33 +03:00
echo "### Building libnvim"
2019-12-22 23:45:42 +03:00
pushd "$(dirname "${BASH_SOURCE[0]}")/.." > /dev/null
readonly deployment_target_file="./resources/macos_deployment_target.txt"
readonly deployment_target=$(cat ${deployment_target_file})
2017-05-08 23:03:33 +03:00
2018-06-10 23:12:00 +03:00
# Brew's gettext does not get sym-linked to PATH
export PATH=/usr/local/opt/gettext/bin:$PATH
2019-12-22 23:45:42 +03:00
pushd NvimView/neovim
ln -sf ../local.mk .
# Use custom gettext source only when building libnvim => not in local.mk which is also used to build the full nvim
# to get the full runtime.
make \
CFLAGS="-mmacosx-version-min=${deployment_target}" \
CXXFLAGS="-mmacosx-version-min=${deployment_target}" \
MACOSX_DEPLOYMENT_TARGET=${deployment_target} \
CMAKE_EXTRA_FLAGS="-DGETTEXT_SOURCE=CUSTOM -DCMAKE_OSX_DEPLOYMENT_TARGET=${deployment_target} -DCMAKE_CXX_COMPILER=$(xcrun -find c++)" \
DEPS_CMAKE_FLAGS="-DCMAKE_OSX_DEPLOYMENT_TARGET=${deployment_target} -DCMAKE_CXX_COMPILER=$(xcrun -find c++)" \
libnvim
popd > /dev/null
popd > /dev/null
2017-05-08 23:03:33 +03:00
echo "### Built libnvim"