change to container based travis

This commit is contained in:
Denis Blank 2015-08-09 16:53:02 +02:00 committed by Naios
parent 1454ba1593
commit 862c2bb765
2 changed files with 31 additions and 28 deletions

View File

@ -1,35 +1,43 @@
sudo: false
language: cpp
cache: apt
git:
depth: 1
compiler:
- gcc
- clang
before_install:
- sudo add-apt-repository -y ppa:kalakris/cmake
- sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
- sudo add-apt-repository -y ppa:boost-latest/ppa
# clang 3.4
- if [ "$CXX" == "clang++" ]; then sudo add-apt-repository -y ppa:h-rayflood/llvm; fi
- sudo apt-get -qq update
- sudo apt-get -qq install build-essential libtool make cmake
- sudo apt-get install -qq gcc-4.8 g++-4.8
- sudo apt-get -qq install libboost1.55-dev libboost-thread1.55-dev libboost-filesystem1.55-dev libboost-system1.55-dev libboost-program-options1.55-dev libboost-iostreams1.55-dev
addons:
apt:
sources:
- kalakris-cmake
- boost-latest
- ubuntu-toolchain-r-test
packages:
- build-essential
- libtool
- gcc-4.8
- g++-4.8
- clang-3.4
- make
- cmake
- libboost1.55-dev
install:
# g++4.8.1
- if [ "$CXX" = "g++" ]; then export CXX="g++-4.8"; fi
# gcc 4.8
- if [ "$CXX" == "g++" ]; then export CXX="g++-4.8"; fi
# clang 3.4
- if [ "$CXX" == "clang++" ]; then sudo apt-get install --allow-unauthenticated -qq clang-3.4; fi
- if [ "$CXX" == "clang++" ]; then export CXX="clang++-3.4"; fi
# - if [ "$CXX" == "clang++" ]; then export CXX="clang++-3.4"; fi
- $CXX --version
- mkdir bin
- cd bin
- cmake ../ -DCMAKE_BUILD_TYPE=Release
script:
- $CXX --version
- make -j 4
- ./ContinuableTest
- ./ContinuableTests

View File

@ -1,4 +1,4 @@
project(Continue.cpp C CXX)
project(Continuable CXX)
cmake_minimum_required(VERSION 2.8)
include(CheckCXXCompilerFlag)
@ -10,7 +10,6 @@ if(MSVC)
message(FATAL_ERROR "You are using an unsupported version of Visual Studio "
"which doesn't support all required C++11 features. "
"(Visual Studio 2013 (Version >= 1800) is required!)")
endif()
if(PLATFORM EQUAL 64)
@ -40,9 +39,6 @@ else()
# Enable full warnings
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra")
# Find Threads
find_package (Threads)
endif()
find_package(Boost 1.55 REQUIRED)
@ -51,16 +47,15 @@ if(Boost_FOUND)
include_directories(${Boost_INCLUDE_DIRS})
endif()
file(GLOB_RECURSE LIB_SOURCES include/*.cpp include/*.hpp include/*.h)
file(GLOB_RECURSE LIB_SOURCES include/*.cpp include/*.hpp)
add_library(Continuable STATIC ${LIB_SOURCES})
include_directories(include testing)
include_directories(src testing)
file(GLOB TEST_SOURCES *.cpp *.hpp *.h)
add_executable(ContinuableTest ${TEST_SOURCES})
add_executable(ContinuableTests ${TEST_SOURCES})
target_link_libraries(ContinuableTest
target_link_libraries(ContinuableTests
Continuable
${CMAKE_THREAD_LIBS_INIT}
)