* Add Travis CI for Linux (through docker) and OS X

This commit is contained in:
Stelios Tsampas 2018-03-22 15:00:40 +02:00
parent e11f002bf9
commit 7716dc64fa
2 changed files with 47 additions and 28 deletions

View File

@ -1,28 +1,33 @@
os: linux
dist: trusty
language: c
compiler:
- clang
- gcc
addons:
apt:
sources:
- ubuntu-sdk-team
packages:
- intltool
- libavformat-dev
- libavcodec-dev
- libavutil-dev
- libgtk-3-dev
- libsdl2-dev
- libxtst-dev
- libxml2-utils
script:
- mkdir build && cd build
- cmake .. -DCMAKE_BUILD_TYPE='Release' -DCMAKE_INSTALL_PREFIX='/usr' -DCMAKE_INSTALL_LIBDIR='/usr/lib'
- make -j1
matrix:
include:
- os: linux
language: c
sudo: required
compiler: gcc
services: docker
before_install:
- docker pull ubuntu:17.10
script:
- export CC=gcc
- export CXX=g++
- docker build .
- os: linux
language: c
sudo: required
compiler: clang
services: docker
before_install:
- docker pull ubuntu:17.10
script:
- export CC=clang
- export CXX=clang++
- docker build .
- os: osx
osx_image: xcode7.3
before_install:
- curl -O -L https://www.libsdl.org/release/SDL2-2.0.8.dmg
- hdiutil attach SDL2-2.0.8.dmg
- sudo cp -a /Volumes/SDL2/SDL2.framework /Library/Frameworks/
language: objective-c
xcode_project: macosx/Pcsxr.xcodeproj
xcode_scheme: PCSXR

14
Dockerfile Normal file
View File

@ -0,0 +1,14 @@
FROM ubuntu:17.10
RUN apt-get update -qq
RUN apt-get install -qq -y libtool intltool gcc clang automake autoconf cmake
RUN apt-get install -qq -y libavformat-dev libavcodec-dev libavutil-dev libgtk-3-dev libsdl2-dev libxtst-dev libxml2-utils libxml2-dev libarchive-dev libcdio-dev
RUN mkdir -p /src/build/
WORKDIR /src/build/
RUN env
COPY . /src/
RUN cmake .. -DCMAKE_BUILD_TYPE='Release' -DCMAKE_INSTALL_PREFIX='/usr' -DCMAKE_INSTALL_LIBDIR='/usr/lib' -DSND_BACKEND='sdl' -DENABLE_CCDDA='ON' -DUSE_LIBARCHIVE='ON' -DUSE_LIBCDIO='ON'
RUN make