aboutsummaryrefslogtreecommitdiffstats
path: root/.travis.yml
blob: 70c4499d9a6694b9a1dce492faa8e87a6f5d1ce9 (plain) (blame)
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
dist: trusty
sudo: required
language: cpp
env:
  global:
   - secure: "VAdPa4SeDaJWWzQwz6m1/8xbr4bDcfd+1qlvOi6+dVhSeilWAyoEBaEaQ4pdp6oD+RvPyuNj6I+9h02WnM5Yuo/rlhgav0FgnoJus14dYNZijyM9T2yjQiVKFm6x1VMJv6woDtl3BdKOjCFVLUhucAt2ifxS4so3HkbXpX5QPFT8OtPv4W9nvv5cyCIHQyOfEn3oH/JM/o0NeVybPeHksm97nXTenL8EL5N8UaX9sxqzouOnRLXQhrU9p34/AMYbBBbXY5yfc2BNTJIL+Ek/A7g14RZJkmytC3ac123gPDWTC3qXdsyUtBudCigDdDCioDb2BtJdTnvBqLURowM2G/oceMchlSp8sK+qQGZJX6P8DbvfBnkUCBMqAGVu0RqeMuG2pVYVE4dLreAMDxUAHZ1ZO8xEisCWUVEEfK6mJoiNQmrPbiaM5oQKhn5+JOQt5/nGDXEATxuLjy8FKmDdJ+Dgk/dqs4thp7NmMKBFUWOmE+hHHtzCxXdPawXqhd9Gm4QttXoRpsIeadgX2u43iSvlJgwHbUfeQCPitPNwoe4IidbrXtXdTK16G3YxXSivcNJKR3NSp2C0jjsalbIyDmf+iJA3zZ+87+ypIC+/gJLSjR5XASH3conr+C4jl9aPmQIvck7I/6ul+fQXBwfUktc0G3+2+L3fDYPrUKDyns4="
matrix:
  include:
    os: linux
    compiler: clang
    addons:
      coverity_scan:
        project:
          name: "bloodstalker/mutator"
          description: "Build submitted via Travis CI"
        notification_email: thabogre@gmail.com
        build_command_prepend: "cov-configure --comptype clangcxx --compiler clang-5.0"
        build_command:   "make PY_CONF=python3.5-config CXX=clang-5.0 LLVM_CONF=llvm-config-5.0 BUILD_MODE=COV_NO_CLANG"
        branch_pattern: master

before_install:
      - echo -n | openssl s_client -connect scan.coverity.com:443 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' | sudo tee -a /etc/ssl/certs/ca-
      - pip install --user cpp-coveralls

before_script: 
  - ulimit -c unlimited -s
  - sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
  - sudo add-apt-repository ppa:fkrull/deadsnakes -y
  - sudo apt-get update -y
  - wget -O - http://llvm.org/apt/llvm-snapshot.gpg.key|sudo apt-key add -
  - wget -O - http://apt.llvm.org/llvm-snapshot.gpg.key|sudo apt-key add - # Fingerprint: 6084 F3CF 814B 57C1 CF12 EFD5 15CF 4D18 AF4F 7421
  - echo "deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-5.0 main" | sudo tee -a /etc/apt/sources.list
  - sudo apt-get update -qq
  - travis_retry sudo apt-get install clang-5.0 libclang-5.0-dev libclang-common-5.0-dev libllvm5.0 llvm-5.0-dev llvm-5.0 llvm-5.0-runtime libclang1-5.0-dbg libllvm5.0-dbg lldb-5.0 -y
  - sudo apt-get install gcc-4.9 g++-4.9
  - sudo apt-get install libffi-dev -y
  - ./extra-tools/capstoneubuntu14.sh
  - sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.9
  - sudo apt-get install libboost-dev
  - git submodule init
  - git submodule update
    #- sudo apt-get install python3-all-dev -y
    #- sudo apt-get install libpython3-all-dev -y
    #- sudo apt-get source python -y
  - sudo apt-get install python3.5-dev -y --allow-unauthenticated
  - python3-config --includes
  - python3-config --ldflags

script: 
  - make PY_CONF=python3.5-config CXX=clang-5.0 LLVM_CONF=llvm-config-5.0 BUILD_MODE=COV_NO_CLANG -j2
  - cd ./extra-tools && ./precommitTests.sh

after_failure:
  - find . -maxdepth 1 -name "core*"

after_success:
  - llvm-config-4.0 --has-rtti
  - llvm-config-5.0 --has-rtti
  - gcc -v
  - ./mutator-lvl0 -SysHeader=false -MainOnly=true ./test/testFuncs1.c ./test/testFuncs2.c ./test/testFuncs3.c -- -std=c90 -I/usr/lib/gcc/x86_64-linux-gnu/4.9/include -I/usr/include -I/usr/include/linux -Wall > /dev/null
  - make clean
  - make mutator-lvl0 CXX=clang-5.0 LLVM_CONF=llvm-config-5.0 BUILD_MODE=COV_GNU -j2
    #- echo "deb http://old-releases.ubuntu.com/ubuntu/ hardy universe" | sudo tee -a /etc/apt/sources.list
    #- sudo apt-get update -y
  #- sudo apt-get install gcc-4.2 g++-4.2
  #- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.2 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.2
  - make install
  - ./mutator-lvl0 -SysHeader=false -MainOnly=true ./test/testFuncs1.c ./test/testFuncs2.c ./test/testFuncs3.c -- -std=c90 -I/usr/lib/gcc/x86_64-linux-gnu/4.9/include -I/usr/include -I/usr/include/linux -Wall > /dev/null
  - gcov -v
  - gcc -v
    #- coveralls --exclude ./json --exclude ./tinyxml2 --exclude-pattern 'clang' --exclude-pattern 'llvm'
    #- gcc -E - <<< '#include<stddef.h>'
    #- gcc -E - <<< '#include<assert.h>'
  - ls
  - ulimit -a
  - find . -maxdepth 1 -name "core*"
  - ls -s
    cd test
    gcc testFuncs3.c -c
    cd /usr/lib/syslinux
    ls
    cd /usr/include/linux
    ls