Add Travis CI and Appveyor CI configurations.

pull/3/head
whitequark 2015-03-29 08:15:41 +03:00
parent 71b7ad7f99
commit 46db5378dc
4 changed files with 26 additions and 1 deletions

12
.travis.yml Normal file
View File

@ -0,0 +1,12 @@
language: c
os:
- linux
- osx
install:
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo add-apt-repository -y ppa:smspillaz/cmake-2.8.12; sudo add-apt-repository -y ppa:ondrej/php5; sudo apt-get update -qq; sudo apt-get install -q -y cmake cmake-data libpng12-dev zlib1g-dev libjson0-dev libfontconfig1-dev libgtkmm-2.4-dev libpangomm-1.4-dev libgl1-mesa-dev libglu-dev libglew-dev; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install cmake libpng; fi
script:
- mkdir cbuild
- cd cbuild
- cmake -DCMAKE_BUILD_TYPE=Debug ..
- make

View File

@ -19,6 +19,11 @@ project(solvespace)
set(solvespace_VERSION_MAJOR 2)
set(solvespace_VERSION_MINOR 1)
if(WIN32)
# ttf2c takes 10 minutes (!) on Appveyor CI
set(DISABLE_TTF2C CACHE BOOL "Disable font regeneration with ttf2c, for use on CI")
endif()
if(NOT WIN32)
set(GUI gtk2 CACHE STRING "GUI toolkit to use (one of: gtk2 gtk3)")
endif()

8
appveyor.yml Normal file
View File

@ -0,0 +1,8 @@
version: 1.0.{build}
before_build:
- mkdir cbuild
- cd cbuild
- cmake -DDISABLE_TTF2C=ON -G"Visual Studio 12" ..
build:
project: C:\projects\solvespace\cbuild\solvespace.sln
verbosity: minimal

View File

@ -103,7 +103,7 @@ if(PERL_FOUND AND PERLMODULES_FOUND)
DEPENDENCIES ${icons})
endif()
if(WIN32)
if(WIN32 AND NOT DISABLE_TTF2C)
add_custom_command(
OUTPUT "${CMAKE_CURRENT_SOURCE_DIR}/built/bitmapfont.table.h"
COMMAND ttf2c "${CMAKE_CURRENT_SOURCE_DIR}/built/bitmapfont.table.h")