• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1language: c
2
3matrix:
4    include:
5
6        # normal native in-tree builds
7        - os: linux
8          env: BUILD="native" INSTALL_PACKAGES="$BUILD"
9          compiler: gcc-5
10          addons:
11              apt:
12                  sources: ['ubuntu-toolchain-r-test']
13                  packages: ['gcc-5']
14
15        - os: linux
16          env: BUILD="native" INSTALL_PACKAGES="$BUILD"
17          compiler: gcc-7
18          addons:
19              apt:
20                  sources: ['ubuntu-toolchain-r-test']
21                  packages: ['gcc-7']
22
23        - os: linux
24          env: BUILD="native" INSTALL_PACKAGES="$BUILD"
25          compiler: clang-4.0
26          addons:
27              apt:
28                  sources: ['ubuntu-toolchain-r-test', 'llvm-toolchain-trusty-4.0']
29                  packages: ['clang-4.0']
30
31        - os: linux
32          env: BUILD="native" INSTALL_PACKAGES="$BUILD"
33          compiler: clang-5.0
34          addons:
35              apt:
36                  sources: ['ubuntu-toolchain-r-test', 'llvm-toolchain-trusty-5.0']
37                  packages: ['clang-5.0']
38
39        # minimal build (some headers and libraries are missing)
40        - os: linux
41          env: BUILD="native"
42          compiler: clang-3.9
43          addons:
44              apt:
45                  sources: ['ubuntu-toolchain-r-test', 'llvm-toolchain-trusty-3.9']
46                  packages: ['clang-3.9']
47
48        # 32-bit in-tree cross-compile builds
49        - os: linux
50          env: BUILD="32" INSTALL_PACKAGES="$BUILD"
51          compiler: gcc-4.9
52          addons:
53              apt:
54                  sources: ['ubuntu-toolchain-r-test']
55                  packages: ['gcc-4.9', 'gcc-4.9-multilib', 'linux-libc-dev:i386']
56
57        - os: linux
58          env: BUILD="32" INSTALL_PACKAGES="$BUILD"
59          compiler: gcc-6
60          addons:
61              apt:
62                  sources: ['ubuntu-toolchain-r-test']
63                  packages: ['gcc-6', 'gcc-6-multilib', 'linux-libc-dev:i386']
64
65        # out-of-tree build
66        - os: linux
67          env: BUILD="out" INSTALL_PACKAGES="native"
68          compiler: gcc-7
69          addons:
70              apt:
71                  sources: ['ubuntu-toolchain-r-test']
72                  packages: ['gcc-7']
73
74        # cross-compile ARM builds
75        - os: linux
76          env: BUILD="cross" INSTALL_PACKAGES="$BUILD"
77          compiler: arm-linux-gnueabihf-gcc
78          addons:
79              apt:
80                  packages: ['gcc-arm-linux-gnueabihf', 'libc6-dev-armhf-cross']
81
82        - os: linux
83          env: BUILD="cross" INSTALL_PACKAGES="$BUILD"
84          compiler: aarch64-linux-gnu-gcc
85          addons:
86              apt:
87                  packages: ['gcc-aarch64-linux-gnu', 'libc6-dev-arm64-cross']
88
89notifications:
90    email:
91        secure: "b/xcA/K5OyQvPPnd0PRahTH5LJu8lgz8goGHvhXpHo+ZPsPgTDXNFo5cX9fSOkMuFKeoW8iGl0wOgK2+ptc8mbYDw277K4RFIHRHeV/KIoE1EzjQnEFiL8J0oHCAvDj12o0AXeriTyY9gICXKbR31Br6Zh5eKViDJe2OAGeHeDU="
92
93before_install:
94    # installing / removing dependencies
95    - if [ "$INSTALL_PACKAGES" = "" ]; then
96          sudo apt remove $(cat .travis.packages_native | grep -v -e 'libc6' -e 'libc6-dev' -e 'linux-libc-dev' -e 'libacl1')
97      ; elif [ "$INSTALL_PACKAGES" != "cross" ]; then
98          sudo apt install -qq $(cat .travis.packages_native)
99      ; fi
100
101    - if [ "$INSTALL_PACKAGES" = "32" ]; then
102          sudo apt install -qq $(cat .travis.packages_i386)
103      ; fi
104
105script: ./build.sh -t $BUILD -c $CC
106