2015-11-23 06:07:25 -07:00
|
|
|
language: cpp
|
2020-06-11 03:47:36 -06:00
|
|
|
jobs:
|
|
|
|
include:
|
|
|
|
- os: linux
|
|
|
|
dist: bionic
|
2020-12-09 22:28:53 -07:00
|
|
|
# - os: osx
|
2015-11-23 06:07:25 -07:00
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages:
|
2021-06-29 01:20:39 -06:00
|
|
|
- python3
|
|
|
|
- python3-pip
|
2015-11-23 06:07:25 -07:00
|
|
|
- cmake
|
2015-12-20 11:30:57 -07:00
|
|
|
- libsdl2-dev
|
2020-04-17 01:59:36 -06:00
|
|
|
- libsdl2-mixer-dev
|
|
|
|
- libsdl2-image-dev
|
2015-11-23 06:07:25 -07:00
|
|
|
- liblua5.1-0-dev
|
|
|
|
- libtolua++5.1-dev
|
|
|
|
- libtolua-dev
|
2020-06-28 01:49:02 -06:00
|
|
|
- libtheora-dev
|
|
|
|
- libvorbis-dev
|
|
|
|
- libogg-dev
|
|
|
|
- libmng-dev
|
|
|
|
- libpng-dev
|
2015-11-23 06:07:25 -07:00
|
|
|
- zlib1g-dev
|
|
|
|
before_script:
|
2020-06-06 03:00:27 -06:00
|
|
|
- "if [ $TRAVIS_OS_NAME == osx ]; then brew install lua51 sdl2 sdl2_mixer sdl2_image; \
|
2015-11-24 07:40:49 -07:00
|
|
|
git clone https://github.com/LuaDist/toluapp.git; \
|
2015-11-24 07:46:39 -07:00
|
|
|
cd toluapp; mkdir build;
|
2016-01-05 07:26:20 -07:00
|
|
|
cd build; cmake ..; make; \
|
2016-01-07 08:25:42 -07:00
|
|
|
export CMAKEARGS=\"-DTOLUA++_INCLUDE_DIR=$(pwd)/../include/ -DTOLUA++_LIBRARY=$(pwd)/libtoluapp.dylib -DTOLUA++_APP=$(pwd)/toluapp -DWITH_X11=OFF\";
|
2015-11-24 07:46:39 -07:00
|
|
|
cd ..;
|
2015-11-24 07:41:53 -07:00
|
|
|
cd ..;
|
2015-11-24 07:40:49 -07:00
|
|
|
fi"
|
2015-11-23 06:07:25 -07:00
|
|
|
- mkdir build
|
|
|
|
- cd build
|
2016-01-05 07:26:20 -07:00
|
|
|
- cmake $CMAKEARGS ..
|
2015-11-24 07:29:31 -07:00
|
|
|
script: make
|
2016-01-06 04:03:08 -07:00
|
|
|
after_success:
|
2021-06-29 01:20:39 -06:00
|
|
|
- "if [ $TRAVIS_REPO_SLUG == Wargus/stratagus -a \
|
|
|
|
$TRAVIS_BRANCH == master -a \
|
|
|
|
$TRAVIS_OS_NAME == linux -a \
|
|
|
|
$TRAVIS_PULL_REQUEST == 'false' ]; then \
|
2021-06-29 01:52:24 -06:00
|
|
|
cd $TRAVIS_BUILD_DIR;
|
2021-06-29 01:20:39 -06:00
|
|
|
git clone https://${GH_TOKEN}@github.com/Wargus/wargus.github.io;
|
|
|
|
python3 -m pip install --user Pygments;
|
|
|
|
python3 doc/lua/generate_index.py;
|
|
|
|
cp index.html wargus.github.io/lua_bindings.html;
|
|
|
|
cd wargus.github.io;
|
|
|
|
git config --global user.email \"travis-ci@travis.org\";
|
|
|
|
git config --global user.name \"Travis CI\";
|
|
|
|
git add lua_bindings.html;
|
|
|
|
git commit -m \"update bindings\";
|
|
|
|
git push origin master;
|
|
|
|
cd ..;
|
|
|
|
fi"
|
2016-01-06 04:03:08 -07:00
|
|
|
- "if [ $TRAVIS_REPO_SLUG == Wargus/stratagus -a \
|
|
|
|
$TRAVIS_BRANCH == master -a \
|
2016-02-04 07:08:59 -07:00
|
|
|
$TRAVIS_OS_NAME == osx -a \
|
2016-01-06 04:03:08 -07:00
|
|
|
$TRAVIS_PULL_REQUEST == 'false' ]; then \
|
|
|
|
git clone https://${GH_TOKEN}@github.com/Wargus/stratagus.wiki.git;
|
|
|
|
mkdir -p stratagus.wiki/$TRAVIS_OS_NAME;
|
|
|
|
cp $TRAVIS_BUILD_DIR/build/stratagus stratagus.wiki/$TRAVIS_OS_NAME/;
|
2016-01-07 08:08:43 -07:00
|
|
|
rm -rf macdylibbundler; git clone https://github.com/auriamg/macdylibbundler;
|
|
|
|
cd macdylibbundler; make; cd ..;
|
|
|
|
macdylibbundler/dylibbundler -cd -of -b -x stratagus.wiki/$TRAVIS_OS_NAME/stratagus -d stratagus.wiki/libs/;
|
2016-01-06 04:03:08 -07:00
|
|
|
cd stratagus.wiki/;
|
|
|
|
git config --global user.email \"travis-ci@travis.org\";
|
|
|
|
git config --global user.name \"Travis CI\";
|
|
|
|
git add $TRAVIS_OS_NAME/stratagus;
|
2016-01-07 08:34:25 -07:00
|
|
|
git add libs;
|
2016-01-06 04:03:08 -07:00
|
|
|
git commit --amend -C HEAD;
|
2016-01-06 04:07:41 -07:00
|
|
|
git push -fq origin master;
|
2016-01-06 04:03:08 -07:00
|
|
|
cd ..;
|
|
|
|
fi"
|