forked from meta-toolkit/meta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
51 lines (46 loc) · 2.43 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
notifications:
irc: "chat.freenode.net#meta-toolkit"
language: cpp
compiler:
- clang
- gcc
install:
- sudo apt-get update -qq
- sudo apt-get install libc6-i386
- wget http://www.cmake.org/files/v3.0/cmake-3.0.1-Linux-i386.sh
- sudo sh cmake-3.0.1-Linux-i386.sh --prefix=/usr/local --exclude-subdir
- sudo apt-get install libicu-dev
# credit: https://github.com/beark/ftl/
# install g++ 4.8, if tests are run with g++
- if [ "`echo $CXX`" == "g++" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; fi
- if [ "`echo $CXX`" == "g++" ]; then sudo apt-get update; fi
- if [ "`echo $CXX`" == "g++" ]; then sudo apt-get install -qq g++-4.8; fi
- if [ "`echo $CXX`" == "g++" ]; then sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 50; fi
# install libc++ if tests are run with clang++
- if [ "`echo $CXX`" == "clang++" ]; then cwd=$(pwd); fi
- if [ "`echo $CXX`" == "clang++" ]; then svn co --quiet http://llvm.org/svn/llvm-project/libcxx/trunk libcxx; fi
- if [ "`echo $CXX`" == "clang++" ]; then git clone https://github.com/pathscale/libcxxrt.git libcxxrt; fi
- if [ "`echo $CXX`" == "clang++" ]; then cd libcxxrt; fi
- if [ "`echo $CXX`" == "clang++" ]; then mkdir build; fi
- if [ "`echo $CXX`" == "clang++" ]; then cd build; fi
- if [ "`echo $CXX`" == "clang++" ]; then cmake -DCMAKE_BUILD_TYPE=Release ../; fi
- if [ "`echo $CXX`" == "clang++" ]; then make; fi
- if [ "`echo $CXX`" == "clang++" ]; then sudo cp lib/libcxxrt.so /usr/lib; fi
- if [ "`echo $CXX`" == "clang++" ]; then sudo ln -sf /usr/lib/libcxxrt.so /usr/lib/libcxxrt.so.1; fi
- if [ "`echo $CXX`" == "clang++" ]; then sudo ln -sf /usr/lib/libcxxrt.so /usr/lib/libcxxrt.so.1.0; fi
- if [ "`echo $CXX`" == "clang++" ]; then cd $cwd; fi
- if [ "`echo $CXX`" == "clang++" ]; then cd libcxx; fi
- if [ "`echo $CXX`" == "clang++" ]; then mkdir build; fi
- if [ "`echo $CXX`" == "clang++" ]; then cd build; fi
- if [ "`echo $CXX`" == "clang++" ]; then cmake -DLIBCXX_CXX_ABI=libcxxrt -DLIBCXX_CXX_ABI_INCLUDE_PATHS="../../libcxxrt/src" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr ..; fi
- if [ "`echo $CXX`" == "clang++" ]; then make; fi
- if [ "`echo $CXX`" == "clang++" ]; then sudo make install; fi
- if [ "`echo $CXX`" == "clang++" ]; then cd $cwd; fi
before_script:
- mkdir build
- cd build
- cp ../config.toml ./
script:
- cmake ../ -DCMAKE_BUILD_TYPE=Debug
- make
- ctest --output-on-failure