CI: add Mac build

This commit is contained in:
Hisham Muhammad
2021-01-23 15:16:41 -03:00
parent 7c6e1b013c
commit 442fabb11a

View File

@@ -1,15 +1,34 @@
language: c language: generic
sudo: false sudo: false
env: jobs:
- LUA="lua 5.1" - os: linux
- LUA="lua 5.2" env:
- LUA="lua 5.3" - LUA="lua 5.1"
- LUA="luajit 2.1" LIBFLAG="-shared --coverage"
- os: linux
env:
- LUA="lua 5.2"
LIBFLAG="-shared --coverage"
- os: linux
env:
- LUA="lua 5.3"
LIBFLAG="-shared --coverage"
- os: linux
env:
- LUA="lua 5.4"
LIBFLAG="-shared --coverage"
- os: linux
env:
- LUA="luajit 2.1"
LIBFLAG="-shared --coverage"
- os: osx
env:
- LUA="lua 5.1"
LIBFLAG="-bundle -undefined dynamic_lookup -all_load --coverage"
before_install: before_install:
- pip install --user cpp-coveralls hererocks - pip install cpp-coveralls hererocks
- hererocks env --$LUA --luarocks latest - hererocks env --$LUA --luarocks latest
- export PATH="$PWD/env/bin:$PATH" - export PATH="$PWD/env/bin:$PATH"
- luarocks install lua-path - luarocks install lua-path
@@ -19,7 +38,7 @@ before_install:
- luarocks install luacov-coveralls --server=https://luarocks.org/dev --deps-mode=none - luarocks install luacov-coveralls --server=https://luarocks.org/dev --deps-mode=none
install: install:
- luarocks make CFLAGS="-O2 -fPIC -ftest-coverage -fprofile-arcs" LIBFLAG="-shared --coverage" - luarocks make CFLAGS="-O2 -fPIC -ftest-coverage -fprofile-arcs" LIBFLAG="$LIBFLAG"
script: script:
- lua -lluacov tests/test.lua - lua -lluacov tests/test.lua