This repository has been archived by the owner on Oct 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 81
/
.travis.yml
227 lines (203 loc) · 7.19 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
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
language: cpp
sudo: required
dist: trusty
cache:
apt: true
ccache: true
env:
global:
- LIBPCIACCESS_VERSION=libpciaccess-0.13.4
- LIBDRM_VERSION=libdrm-2.4.92
- LIBWAYLAND_VERSION=wayland-1.15.92
- WAYLAND_PROTOCOLS_VERSION=wayland-protocols-1.15
- MESA_VERSION=mesa-18.1.5
- LIBVA_VERSION=libva-1.7.0
- VULKAN_SDK_VERSION=sdk-1.1.77.0
- LIBEVDEV_VERSION=libevdev-1.5.9
- LIBUNWIND_VERSION=libunwind-1.2.1
- PKG_CONFIG_PATH=$HOME/prefix/lib/pkgconfig:$HOME/prefix/share/pkgconfig
- LD_LIBRARY_PATH=$HOME/prefix/lib:$LD_LIBRARY_PATH
- PATH=$HOME/prefix/bin:$PATH
- OVERRIDE_CC="gcc-4.9"
- OVERRIDE_CXX="g++-4.9"
- MAKEFLAGS="-j4"
- HWC_FLAGS=""
matrix:
include:
- env:
- LABEL="Static analysis"
- BUILD=static
addons:
apt:
packages:
- clang-format-3.9
- cppcheck
install: true
script: true
- env:
- LABEL="Default"
- BUILD=make
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.9
- g++-4.9
- libelf-dev
- env:
- LABEL="Disable hotplug"
- BUILD=make
- HWC_FLAGS="--disable-hotplug-support"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.9
- g++-4.9
- libelf-dev
- env:
- LABEL="Dummy compositor"
- BUILD=make
- HWC_FLAGS="--enable-dummy-compositor"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.9
- g++-4.9
- libelf-dev
- env:
- LABEL="Vulkan compositor"
- BUILD=make
- HWC_FLAGS="--enable-vulkan"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.9
- g++-4.9
- libelf-dev
- env:
- LABEL="Weston plugin"
- BUILD=weston
- HWC_FLAGS=""
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.9
- g++-4.9
- libelf-dev
- xutils-dev
- libxcb*
- libx11-xcb-dev
- libxkbcommon-dev
- x11proto-*-dev
- libxdamage*
- libxext-dev
- libxshmfence-dev
- libwacom-dev
- libgtk-3-dev
- check
- libpam0g-dev
- python3
- python3-pip
- libudev-dev
- libevdev-dev
- libmtdev-dev
- mtdev-tools
before_install:
- if test "x$BUILD" = xstatic; then
./travisci/check_patch.py;
fi
install:
- |
test -n "$OVERRIDE_CC" && export CC="$OVERRIDE_CC"
test -n "$OVERRIDE_CXX" && export CXX="$OVERRIDE_CXX"
wget http://xorg.freedesktop.org/releases/individual/lib/$LIBPCIACCESS_VERSION.tar.bz2
tar -jxvf $LIBPCIACCESS_VERSION.tar.bz2
(cd $LIBPCIACCESS_VERSION && ./configure --prefix=$HOME/prefix && make install)
wget http://dri.freedesktop.org/libdrm/$LIBDRM_VERSION.tar.bz2
tar -jxvf $LIBDRM_VERSION.tar.bz2
(cd $LIBDRM_VERSION && ./configure --prefix=$HOME/prefix && make install)
# Generate this header since one is missing on the Travis instance
mkdir -p $HOME/prefix/include/linux
printf "%s\n" \
"#ifndef _LINUX_MEMFD_H" \
"#define _LINUX_MEMFD_H" \
"" \
"#define __NR_memfd_create 319" \
"#define SYS_memfd_create __NR_memfd_create" \
"" \
"#define MFD_CLOEXEC 0x0001U" \
"#define MFD_ALLOW_SEALING 0x0002U" \
"" \
"#endif /* _LINUX_MEMFD_H */" > $HOME/prefix/include/linux/memfd.h
wget http://wayland.freedesktop.org/releases/$LIBWAYLAND_VERSION.tar.xz
tar -axvf $LIBWAYLAND_VERSION.tar.xz
(cd $LIBWAYLAND_VERSION && ./configure --prefix=$HOME/prefix \
--enable-libraries --without-host-scanner --disable-documentation \
--disable-dtd-validation && make install)
wget http://wayland.freedesktop.org/releases/$WAYLAND_PROTOCOLS_VERSION.tar.xz
tar -axvf $WAYLAND_PROTOCOLS_VERSION.tar.xz
(cd $WAYLAND_PROTOCOLS_VERSION && ./configure --prefix=$HOME/prefix && \
make install)
wget https://mesa.freedesktop.org/archive/$MESA_VERSION.tar.gz
tar -zxvf $MESA_VERSION.tar.gz
(cd $MESA_VERSION && ./configure --prefix=$HOME/prefix --disable-glx \
--with-platforms=surfaceless,wayland --without-gallium-drivers \
--with-dri-drivers=i965 --with-vulkan-drivers=intel && make install)
wget http://www.freedesktop.org/software/vaapi/releases/libva/$LIBVA_VERSION.tar.bz2
tar -jxvf $LIBVA_VERSION.tar.bz2
(cd $LIBVA_VERSION && ./configure --prefix=$HOME/prefix && make install)
wget https://github.com/KhronosGroup/Vulkan-Headers/archive/$VULKAN_SDK_VERSION.tar.gz
mv $VULKAN_SDK_VERSION.tar.gz Vulkan-Headers-$VULKAN_SDK_VERSION.tar.gz
tar -zxvf Vulkan-Headers-$VULKAN_SDK_VERSION.tar.gz
(cd Vulkan-Headers-$VULKAN_SDK_VERSION && \
cmake -DCMAKE_INSTALL_PREFIX=$HOME/prefix && make install)
wget https://github.com/KhronosGroup/Vulkan-Loader/archive/$VULKAN_SDK_VERSION.tar.gz
mv $VULKAN_SDK_VERSION.tar.gz Vulkan-Loader-$VULKAN_SDK_VERSION.tar.gz
tar -zxvf Vulkan-Loader-$VULKAN_SDK_VERSION.tar.gz
(cd Vulkan-Loader-$VULKAN_SDK_VERSION && \
cmake -DCMAKE_INSTALL_PREFIX=$HOME/prefix -DBUILD_TESTS=OFF \
-DBUILD_WSI_MIR_SUPPORT=Off -DBUILD_WSI_WAYLAND_SUPPORT=Off \
-DBUILD_WSI_XCB_SUPPORT=Off -DBUILD_WSI_XLIB_SUPPORT=Off && make install)
wget https://www.freedesktop.org/software/libevdev/$LIBEVDEV_VERSION.tar.xz
tar -axvf $LIBEVDEV_VERSION.tar.xz
(cd $LIBEVDEV_VERSION && ./configure --prefix=$HOME/prefix && make install)
wget https://download.savannah.nongnu.org/releases/libunwind/$LIBUNWIND_VERSION.tar.gz
tar -xzvf $LIBUNWIND_VERSION.tar.gz
(cd $LIBUNWIND_VERSION && ./configure --prefix=$HOME/prefix && make install)
script:
- if test "x$BUILD" = xmake; then
./autogen.sh $HWC_FLAGS && make;
fi
- |
if test "x$BUILD" = xweston; then
cp travisci/realpath $HOME/prefix/bin
wget https://github.com/ninja-build/ninja/releases/download/v1.8.2/ninja-linux.zip
unzip ninja-linux.zip
cp ninja $HOME/prefix/bin
pip3 install --user pathlib
pip3 install --user meson==0.43.0
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$HOME/prefix/lib/x86_64-linux-gnu/pkgconfig
git clone git://anongit.freedesktop.org/git/wayland/libinput libinput
(cd libinput && meson --prefix=$HOME/prefix -Dlibwacom=false \
-Ddocumentation=false -Ddebug-gui=false -Dtests=false builddir/ && \
ninja -C builddir/ && ninja -C builddir/ install)
export WLD=$HOME/prefix
git clone -b iahwc-plugin https://github.com/intel/external-weston.git ../weston
cd ../weston
#HACK: Weston's paths are hardcoded to ../iahwc/..
cp -r ../IA-Hardware-Composer ../iahwc
cd -
os/linux/weston/build_script.sh --weston-dir=../weston --iahwc-dir=$(pwd) --build
fi
branches:
only:
- master