forked from fetlang/fetlang
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
53 lines (44 loc) · 1.7 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
52
sudo: required
# Enable C++ support
language: cpp
os:
- linux
- osx
# Compiler selection
compiler:
- clang++
before_install:
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get update; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install clang; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then ruby --version; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then rvm install ruby-2.3.3; rvm --default use 2.3.3; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then ruby --version; fi
install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then ruby --version; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install python3; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install ninja; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then curl -L "https://github.com/ninja-build/ninja/releases/download/v1.7.2/ninja-linux.zip" -o ninja-linux.zip; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo unzip ninja-linux.zip -d /usr/local/bin; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo chmod 755 /usr/local/bin/ninja; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then pyenv shell 3.6; fi
- pip3 install meson
# Build steps
script:
- meson --buildtype=release src build
- cd build
- ninja test
- rm test.text
- ./fetlang ../examples/bf2c.fet > fetlang_output
- echo -n "" > blank_output
- diff fetlang_output blank_output
- sudo ninja install
- cd ../fetishes/obedience
- fetlang unit.fet -o unit_test
- ./unit_test
- rm test.text
- fetlang -O unit.fet -o unit_test_optimized
- ./unit_test_optimized
- rm test.text
- bash ../../scripts/checkdiff.sh unit_test unit_test_optimized
- cd -