diff options
author | Eric Anholt <eric@anholt.net> | 2017-06-01 12:29:12 -0700 |
---|---|---|
committer | Adam Jackson <ajax@redhat.com> | 2017-06-13 10:36:25 -0400 |
commit | 01dfb65ee2e34148718d3f95dfd4629024edba84 (patch) | |
tree | 88381c2e1544cf1e6bce5c40bf39c5b8cfcfda6a /.travis.yml | |
parent | fda2b064a0ebd223e8a39fd19f5c5ad1da0776e8 (diff) |
travis: Add a build script for Travis CI.
This currently does a meson build using a docker image I've prepared.
The Dockerfile source is at:
https://github.com/anholt/xserver-travis
Docker proved to be necessary to cut the build time per Travis push.
If some day we end up using meson in more of the X stack, we may be
able to move more dependencies out of the docker image and into the CI
build (putting the I in CI). Until then, we'll have to do docker
image rebuilds when dependencies are added/updated.
To enable Travis CI on your github repository, see the first two steps
of the docs at:
https://docs.travis-ci.com/user/getting-started/
Once you do that, pushing branches to your github repo will trigger
builds, which will send you email if they fail. Current build status
can be veiewed your account on travis-ci.org:
https://travis-ci.org/anholt/xserver
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 000000000..d7379ab78 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,14 @@ +language: c +dist: trusty +services: docker + +before_install: + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then docker pull anholt/xserver-travis ; fi + +before_script: + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then echo FROM anholt/xserver-travis:v3 > Dockerfile ; fi + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then echo ADD . /root >> Dockerfile ; fi + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then docker build -t withgit . ; fi + +script: + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then docker run withgit /bin/sh -c "cd /root && ./test/scripts/build-travis-deps.sh" ; fi |