aboutsummaryrefslogtreecommitdiff
path: root/ci
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2018-03-11 19:53:05 +0100
committerGitHub <noreply@github.com>2018-03-11 19:53:05 +0100
commit241c380da93835081e2c1a072d0a281245dd0af4 (patch)
tree40dc6f1f17d7765b88e36782a785a1124b6bab01 /ci
parenta2d1e9cc795c651864339a7197a748806f8af5eb (diff)
parentb0b656dd37567dea5e3f58e7821c7442831403cb (diff)
downloadrneovim-241c380da93835081e2c1a072d0a281245dd0af4.tar.gz
rneovim-241c380da93835081e2c1a072d0a281245dd0af4.tar.bz2
rneovim-241c380da93835081e2c1a072d0a281245dd0af4.zip
Merge #8117 'build/CI/MSVC/LuaRocks'
Diffstat (limited to 'ci')
-rwxr-xr-xci/before_install.sh10
-rw-r--r--ci/build.bat14
-rw-r--r--ci/common/build.sh16
-rwxr-xr-xci/install.sh11
-rwxr-xr-xci/run_lint.sh8
5 files changed, 29 insertions, 30 deletions
diff --git a/ci/before_install.sh b/ci/before_install.sh
index f696b85afc..9a3e192536 100755
--- a/ci/before_install.sh
+++ b/ci/before_install.sh
@@ -24,19 +24,13 @@ echo 'python info:'
) | sed 's/^/ /'
if [[ "${TRAVIS_OS_NAME}" == osx ]]; then
- echo "Install Python 2."
- brew install python@2
-fi
-
-echo "Upgrade Python 2 pip."
-pip2.7 -q install --user --upgrade pip
-
-if [[ "${TRAVIS_OS_NAME}" == osx ]]; then
echo "Upgrade Python 3."
brew upgrade python
echo "Upgrade Python 3 pip."
pip3 -q install --user --upgrade pip
else
+ echo "Upgrade Python 2 pip."
+ pip2.7 -q install --user --upgrade pip
echo "Upgrade Python 3 pip."
# Allow failure. pyenv pip3 on travis is broken:
# https://github.com/travis-ci/travis-ci/issues/8363
diff --git a/ci/build.bat b/ci/build.bat
index 3fa185f646..8bf310851e 100644
--- a/ci/build.bat
+++ b/ci/build.bat
@@ -6,19 +6,19 @@ if "%CONFIGURATION%" == "MINGW_32" (
set ARCH=x86_64
set BITS=64
if "%CONFIGURATION%" == "MINGW_64-gcov" (
- set USE_GCOV="-DUSE_GCOV=ON"
+ set "USE_GCOV=-DUSE_GCOV=ON"
)
) else if "%CONFIGURATION%" == "MSVC_32" (
- set CMAKE_GENERATOR="Visual Studio 15 2017"
+ set "CMAKE_GENERATOR=Visual Studio 15 2017"
) else if "%CONFIGURATION%" == "MSVC_64" (
- set CMAKE_GENERATOR="Visual Studio 15 2017 Win64"
+ set "CMAKE_GENERATOR=Visual Studio 15 2017 Win64"
)
if "%CONFIGURATION:~0,5%" == "MINGW" (
:: These are native MinGW builds, but they use the toolchain inside
:: MSYS2, this allows using all the dependencies and tools available
:: in MSYS2, but we cannot build inside the MSYS2 shell.
- set CMAKE_GENERATOR="MinGW Makefiles"
+ set "CMAKE_GENERATOR=MinGW Makefiles"
set CMAKE_GENERATOR_ARGS=VERBOSE=1
:: Add MinGW to the PATH and remove the Git directory because it
:: has a conflicting sh.exe
@@ -49,14 +49,14 @@ where.exe neovim-node-host.cmd || goto :error
mkdir .deps
cd .deps
-cmake -G %CMAKE_GENERATOR% -DCMAKE_BUILD_TYPE=RelWithDebInfo ..\third-party\ || goto :error
+cmake -G "%CMAKE_GENERATOR%" -DCMAKE_BUILD_TYPE=RelWithDebInfo ..\third-party\ || goto :error
cmake --build . -- %CMAKE_GENERATOR_ARGS% || goto :error
cd ..
:: Build Neovim
mkdir build
cd build
-cmake -G %CMAKE_GENERATOR% -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUSTED_OUTPUT_TYPE=nvim %USE_GCOV% -DGPERF_PRG="C:\msys64\usr\bin\gperf.exe" .. || goto :error
+cmake -G "%CMAKE_GENERATOR%" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUSTED_OUTPUT_TYPE=nvim %USE_GCOV% -DGPERF_PRG="C:\msys64\usr\bin\gperf.exe" .. || goto :error
cmake --build . --config RelWithDebInfo -- %CMAKE_GENERATOR_ARGS% || goto :error
bin\nvim --version || goto :error
@@ -78,7 +78,7 @@ if defined USE_GCOV (
)
:: The default cpack in the PATH is not CMake
-set PATH=C:\Program Files (x86)\CMake\bin\cpack.exe;%PATH%
+set "PATH=C:\Program Files (x86)\CMake\bin\cpack.exe;%PATH%"
:: Build artifacts
cpack -G ZIP -C RelWithDebInfo
if defined APPVEYOR_REPO_TAG_NAME cpack -G NSIS -C RelWithDebInfo
diff --git a/ci/common/build.sh b/ci/common/build.sh
index 2748b15b0d..772b696969 100644
--- a/ci/common/build.sh
+++ b/ci/common/build.sh
@@ -1,5 +1,8 @@
top_make() {
- ${MAKE_CMD} "$@"
+ echo '================================================================================'
+ # Travis has 1.5 virtual cores according to:
+ # http://docs.travis-ci.com/user/speeding-up-the-build/#Paralellizing-your-build-on-one-VM
+ ninja "$@"
}
build_make() {
@@ -17,14 +20,13 @@ build_deps() {
rm -rf "${DEPS_BUILD_DIR}"
- # If there is a valid cache and we're not forced to recompile,
- # use cached third-party dependencies.
- if test -f "${CACHE_MARKER}" && test "${BUILD_NVIM_DEPS}" != "true" ; then
+ # Use cached dependencies if $CACHE_MARKER exists.
+ if test -f "${CACHE_MARKER}" && ! test "${CACHE_ENABLE}" = "false" ; then
local statcmd="stat -c '%y'"
if test "${TRAVIS_OS_NAME}" = osx ; then
statcmd="stat -f '%Sm'"
fi
- echo "Using third-party dependencies from Travis's cache (last updated: $(${statcmd} "${CACHE_MARKER}"))."
+ echo "Using third-party dependencies from Travis cache (last update: $(${statcmd} "${CACHE_MARKER}"))."
mkdir -p "$(dirname "${DEPS_BUILD_DIR}")"
mv "${HOME}/.cache/nvim-deps" "${DEPS_BUILD_DIR}"
@@ -36,7 +38,7 @@ build_deps() {
# update CMake configuration and update to newer deps versions.
cd "${DEPS_BUILD_DIR}"
echo "Configuring with '${DEPS_CMAKE_FLAGS}'."
- CC= cmake ${DEPS_CMAKE_FLAGS} "${TRAVIS_BUILD_DIR}/third-party/"
+ CC= cmake -G Ninja ${DEPS_CMAKE_FLAGS} "${TRAVIS_BUILD_DIR}/third-party/"
if ! top_make; then
exit 1
@@ -56,7 +58,7 @@ prepare_build() {
mkdir -p "${BUILD_DIR}"
cd "${BUILD_DIR}"
echo "Configuring with '${CMAKE_FLAGS} $@'."
- cmake ${CMAKE_FLAGS} "$@" "${TRAVIS_BUILD_DIR}"
+ cmake -G Ninja ${CMAKE_FLAGS} "$@" "${TRAVIS_BUILD_DIR}"
}
build_nvim() {
diff --git a/ci/install.sh b/ci/install.sh
index 60d9507bfb..053549d6db 100755
--- a/ci/install.sh
+++ b/ci/install.sh
@@ -8,20 +8,23 @@ if [[ "${CI_TARGET}" == lint ]]; then
fi
if [[ "${TRAVIS_OS_NAME}" == osx ]]; then
+ brew install ninja
brew install gettext
brew reinstall -s libtool
fi
-# Use default CC to avoid compilation problems when installing Python modules.
-echo "Install neovim module for Python 2."
-CC=cc pip2.7 -q install --user --upgrade neovim
-
echo "Install neovim module for Python 3."
# Allow failure. pyenv pip3 on travis is broken:
# https://github.com/travis-ci/travis-ci/issues/8363
CC=cc pip3 -q install --user --upgrade neovim || true
if ! [ "${TRAVIS_OS_NAME}" = osx ] ; then
+ # Update PATH for pip.
+ export PATH="$(python2.7 -c 'import site; print(site.getuserbase())')/bin:$PATH"
+ # Use default CC to avoid compilation problems when installing Python modules.
+ echo "Install neovim module for Python 2."
+ CC=cc pip2.7 -q install --user --upgrade neovim
+
echo "Install neovim RubyGem."
gem install --no-document --version ">= 0.2.0" neovim
fi
diff --git a/ci/run_lint.sh b/ci/run_lint.sh
index e7f6727448..ae9adb7c87 100755
--- a/ci/run_lint.sh
+++ b/ci/run_lint.sh
@@ -10,19 +10,19 @@ source "${CI_DIR}/common/suite.sh"
enter_suite 'clint'
-run_test 'top_make clint-full' clint
+run_test 'make clint-full' clint
exit_suite --continue
enter_suite 'testlint'
-run_test 'top_make testlint' testlint
+run_test 'make testlint' testlint
exit_suite --continue
enter_suite 'lualint'
-run_test 'top_make lualint' lualint
+run_test 'make lualint' lualint
exit_suite --continue
@@ -31,7 +31,7 @@ enter_suite single-includes
CLICOLOR_FORCE=1 run_test_wd \
--allow-hang \
10s \
- 'top_make check-single-includes' \
+ 'make check-single-includes' \
'csi_clean' \
single-includes