Use hererocks.

This commit is contained in:
Alexey Melnichuk 2016-11-16 16:17:10 +03:00
parent 2d50bdb6fa
commit 83de1e1d2f

View File

@ -6,32 +6,38 @@ os:
shallow_clone: true shallow_clone: true
environment: environment:
LUAROCKS_VER: 2.2.1 LR_EXTERNAL: c:\external
CURL_VER: 7.51.0 CURL_VER: 7.51.0
matrix: matrix:
- LUA_VER: 5.1.5 - LUA: "lua 5.1"
- LUA_VER: 5.2.4 - LUA: "lua 5.2"
- LUA_VER: 5.3.0 - LUA: "lua 5.3"
# - LJ_VER: 2.0.3
# - LJ_VER: 2.1
platform: platform:
- x64 - x64
- x86 - x86
# - mingw
cache: cache:
- c:\lua -> appveyor.yml - c:\hererocks -> appveyor.yml
- c:\external -> appveyor.yml
- C:\Program Files (x86)\LuaRocks -> appveyor.yml
- C:\Program Files\LuaRocks -> appveyor.yml
init:
- call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" %platform%
install: install:
# Setup Lua development/build environment - set PATH=C:\Python27\Scripts;%PATH%
- call .appveyor\install.bat - if /I "%platform%"=="x86" set HR_TARGET=vs_32
- if /I "%platform%"=="x64" set HR_TARGET=vs_64
- if /I "%platform%"=="mingw" set HR_TARGET=mingw
- if /I "%platform%"=="mingw" set PATH=C:\MinGW\bin;%PATH%
- if not exist "%LR_EXTERNAL%" (
mkdir "%LR_EXTERNAL%" &&
mkdir "%LR_EXTERNAL%\lib" &&
mkdir "%LR_EXTERNAL%\include"
)
- if not exist c:\hererocks (
pip install hererocks &&
hererocks c:\hererocks --%LUA% --target %HR_TARGET% -rlatest &&
call c:\hererocks\bin\activate
)
before_build: before_build:
# external deps # external deps
@ -45,11 +51,11 @@ build_script:
before_test: before_test:
# test deps # test deps
- luarocks install lunitx - if "%LUA%"=="lua 5.1" luarocks show bit32 >nul 2>&1 || luarocks install bit32
- luarocks install dkjson - luarocks show lunitx >nul 2>&1 || luarocks install lunitx
- luarocks install luafilesystem - luarocks show dkjson >nul 2>&1 || luarocks install dkjson
- if "%LUA_SHORTV%"=="5.1" luarocks install bit32 - luarocks show luafilesystem >nul 2>&1 || luarocks install luafilesystem
- luarocks install lua-path - luarocks show lua-path >nul 2>&1 || luarocks install lua-path
test_script: test_script:
- echo "Testing..." - echo "Testing..."