1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-26 22:57:00 +02:00

Merge pull request #237 from vmarkovtsev/develop

macOS Travis / #2553
This commit is contained in:
Vadim Markovtsev 2016-10-12 12:05:27 +02:00 committed by GitHub
commit 516d938f7a
4 changed files with 64 additions and 31 deletions

26
.travis.linux Normal file
View File

@ -0,0 +1,26 @@
#!/bin/sh
#new Clang
sudo add-apt-repository --yes ppa:h-rayflood/llvm
#new SDL2
sudo add-apt-repository --yes ppa:zoogie/sdl2-snapshots
#new Qt
sudo add-apt-repository --yes ppa:beineri/opt-qt57-trusty
#new CMake
sudo add-apt-repository --yes ppa:george-edison55/cmake-3.x
sudo apt-get update -qq
sudo apt-get install -qq $SUPPORT
sudo apt-get install -qq $PACKAGE
sudo apt-get install -qq cmake libboost1.54-all-dev zlib1g-dev
sudo apt-get install -qq libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-ttf-dev
sudo apt-get install -qq libavformat-dev libswscale-dev
sudo apt-get install -qq qt57declarative
#setup compiler
source /opt/qt57/bin/qt57-env.sh
export CC=${REAL_CC} CXX=${REAL_CXX}

17
.travis.osx Normal file
View File

@ -0,0 +1,17 @@
#!/bin/sh
# https://gist.github.com/vmarkovtsev/3f2dd98e56cb63098027
brew unlink boost
brew install boost smpeg2 innoextract libpng freetype sdl2 sdl2_ttf sdl2_image qt5 ffmpeg
brew install sdl2_mixer --with-smpeg2
sudo sed -i.bak 's/106200/106900/g' /usr/local/Cellar/cmake/*/share/cmake/Modules/FindBoost.cmake
export CMAKE_PREFIX_PATH="/usr/local/opt/qt5:$CMAKE_PREFIX_PATH"
sparkle_version=$(curl -L https://github.com/sparkle-project/Sparkle/releases/latest | grep '<span class="css-truncate-target">' | sed -E 's|^.*([1-9]\.[0-9]+\.[0-9]+).*$|\1|g')
wget https://github.com/sparkle-project/Sparkle/releases/download/$sparkle_version/Sparkle-$sparkle_version.tar.bz2
mkdir sparkle && cd sparkle
tar -xf ../Sparkle-*.tar.bz2
sudo mv Sparkle.framework /Library/Frameworks/
cd .. && rm -rf sparkle

View File

@ -1,37 +1,22 @@
sudo: required
dist: trusty
language: cpp
os:
- linux
- osx
dist: trusty
sudo: required
before_install:
#new Clang
- sudo add-apt-repository --yes ppa:h-rayflood/llvm
#new SDL2
- sudo add-apt-repository --yes ppa:zoogie/sdl2-snapshots
#new Qt
- sudo add-apt-repository --yes ppa:beineri/opt-qt57-trusty
#new CMake
- sudo add-apt-repository --yes ppa:george-edison55/cmake-3.x
- sudo apt-get update -qq
- sudo apt-get install -qq $SUPPORT
- sudo apt-get install -qq $PACKAGE
- sudo apt-get install -qq cmake libboost1.54-all-dev zlib1g-dev
- sudo apt-get install -qq libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-ttf-dev
- sudo apt-get install -qq libavformat-dev libswscale-dev
- sudo apt-get install -qq qt57declarative
#setup compiler
- source /opt/qt57/bin/qt57-env.sh
- export CC=${REAL_CC} CXX=${REAL_CXX}
- if [[ $TRAVIS_OS_NAME == 'linux' ]]; then . .travis.linux; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then . .travis.osx; fi
before_script:
- mkdir build
- cd build
- cmake ..
- cmake -G "Unix Makefiles" ..
script:
- make
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then cd ..; xcodebuild -project osx/osx-vcmibuilder/vcmibuilder.xcodeproj/ -configuration Release CONFIGURATION_BUILD_DIR=..; cd build; fi
- make -j2
env:
- ignore=this
@ -40,14 +25,19 @@ matrix:
exclude:
- env: ignore=this
include:
- compiler: clang
env: REAL_CC=clang-3.4 REAL_CXX=clang++-3.4 PACKAGE=clang-3.4 SUPPORT=libstdc++-4.8-dev
- compiler: clang
- os: linux
compiler: clang
env: REAL_CC=clang-3.4 REAL_CXX=clang++-3.4 PACKAGE=clang-3.4 SUPPORT=libstdc++-4.8-dev
- os: linux
compiler: clang
env: REAL_CC=clang-3.5 REAL_CXX=clang++-3.5 PACKAGE=clang-3.5 SUPPORT=libstdc++-4.8-dev
- compiler: clang
- os: linux
compiler: clang
env: REAL_CC=clang-3.6 REAL_CXX=clang++-3.6 PACKAGE=clang-3.6 SUPPORT=libstdc++-4.8-dev
- compiler: gcc
- os: linux
compiler: gcc
env: REAL_CC=gcc-4.8 REAL_CXX=g++-4.8 PACKAGE=g++-4.8 SUPPORT=
- os: osx
notifications:
email:

View File

@ -235,7 +235,7 @@ endif()
# Installation section #
#######################################
# For apple this files will be already inside vcmiclient bundle
# For apple these files will be already inside vcmiclient bundle
if (NOT APPLE)
# copy whole directory but .svn control files
install(DIRECTORY config DESTINATION ${DATA_DIR} PATTERN ".svn" EXCLUDE)