mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-20 20:23:03 +02:00
[WIP] macOS Travis / #2553
This commit is contained in:
parent
bdbbc22c66
commit
0e9e93e14e
26
.travis.linux
Normal file
26
.travis.linux
Normal 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
17
.travis.osx
Normal 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
|
48
.travis.yml
48
.travis.yml
@ -1,37 +1,22 @@
|
|||||||
sudo: required
|
|
||||||
dist: trusty
|
|
||||||
language: cpp
|
language: cpp
|
||||||
|
os:
|
||||||
|
- linux
|
||||||
|
- osx
|
||||||
|
dist: trusty
|
||||||
|
sudo: required
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
#new Clang
|
- if [[ $TRAVIS_OS_NAME == 'linux' ]]; then . .travis.linux; fi
|
||||||
- sudo add-apt-repository --yes ppa:h-rayflood/llvm
|
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then . .travis.osx; fi
|
||||||
#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}
|
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- mkdir build
|
- mkdir build
|
||||||
- cd build
|
- cd build
|
||||||
- cmake ..
|
- cmake -G "Unix Makefiles" ..
|
||||||
|
|
||||||
script:
|
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:
|
env:
|
||||||
- ignore=this
|
- ignore=this
|
||||||
@ -40,14 +25,19 @@ matrix:
|
|||||||
exclude:
|
exclude:
|
||||||
- env: ignore=this
|
- env: ignore=this
|
||||||
include:
|
include:
|
||||||
- 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
|
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.5 REAL_CXX=clang++-3.5 PACKAGE=clang-3.5 SUPPORT=libstdc++-4.8-dev
|
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
|
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=
|
env: REAL_CC=gcc-4.8 REAL_CXX=g++-4.8 PACKAGE=g++-4.8 SUPPORT=
|
||||||
|
- os: osx
|
||||||
|
|
||||||
notifications:
|
notifications:
|
||||||
email:
|
email:
|
||||||
|
@ -235,7 +235,7 @@ endif()
|
|||||||
# Installation section #
|
# 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)
|
if (NOT APPLE)
|
||||||
# copy whole directory but .svn control files
|
# copy whole directory but .svn control files
|
||||||
install(DIRECTORY config DESTINATION ${DATA_DIR} PATTERN ".svn" EXCLUDE)
|
install(DIRECTORY config DESTINATION ${DATA_DIR} PATTERN ".svn" EXCLUDE)
|
||||||
|
Loading…
Reference in New Issue
Block a user