-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
114 lines (107 loc) · 3.55 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
#
# Off-the-Record Messaging plugin for pidgin
# Copyright (C) 2004-2018 Ian Goldberg, Rob Smits,
# Chris Alexander, Willy Lew,
# Nikita Borisov
# The pidgin-otrng contributors
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of version 2 of the GNU General Public License as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#
language: c
cache:
- ccache: true
- directories:
- .deps
notifications:
irc:
channels:
- "irc.oftc.net#cad"
on_success: change
on_failure: change
skip_join: true
template:
- "%{repository_slug}(%{author}): %{message} %{build_url}"
sudo: false
addons:
apt:
sources:
- llvm-toolchain-trusty-4.0
packages:
- gettext
- intltool
- valgrind
- libgtk2.0-dev
- pidgin-dev
- libpurple-dev
- clang-tidy-4.0
matrix:
include:
- os: linux
dist: trusty
compiler: gcc
env: T=normal
- os: linux
dist: trusty
compiler: clang
env: T=normal
- os: linux
dist: trusty
compiler: gcc
env: T=splint
- os: linux
dist: trusty
compiler: gcc
env: T=code-check
- os: linux
dist: trusty
compiler: gcc
env: T=valgrind
allow_failures:
- os: linux
dist: trusty
compiler: gcc
env: T=splint
- os: linux
dist: trusty
compiler: gcc
env: T=code-check
- os: linux
dist: trusty
compiler: gcc
env: T=valgrind
before_install:
- PREFIX=/tmp/prefix # we dont want to use sudo (and be forced to use the non-container based infrastructure)
- mkdir -p ${PREFIX}
- export LD_LIBRARY_PATH=${PREFIX}/lib:${LD_LIBRARY_PATH}
- export PKG_CONFIG_PATH="${PREFIX}/lib/pkgconfig:${PKG_CONFIG_PATH}"
- ./travis_before_script.sh
- rm -rf .deps/libotr-ng
- git clone --depth=1 https://github.com/otrv4/libotr-ng.git .deps/libotr-ng
- pushd .deps/libotr-ng && ./autogen.sh && ./configure --with-libotr-inc-prefix=${PREFIX}/include --with-libotr-prefix=${PREFIX}/lib --with-libgcrypt-prefix=$PREFIX --prefix=$PREFIX && make -j && make install && popd
- if [[ "$T" == "splint" ]]; then sudo apt-get install splint --quiet --assume-yes; fi
script:
- cd ${PREFIX}/pidgin-2.13.0/pidgin/plugins
- mv ${TRAVIS_BUILD_DIR} ${PREFIX}/pidgin-2.13.0/pidgin/plugins/
- OLD_TRAVIS_BUILD_DIR=${TRAVIS_BUILD_DIR}
- TRAVIS_BUILD_DIR=${PREFIX}/pidgin-2.13.0/pidgin/plugins/`basename ${TRAVIS_BUILD_DIR}`
- cd ${TRAVIS_BUILD_DIR}
- echo -e "ACLOCAL_FLAGS= -I ${PREFIX}/share/aclocal\n$(cat Makefile.am)" > Makefile.am
- ./autogen.sh
- ./configure --with-libotr-inc-prefix=${PREFIX}/include --with-libotr-prefix=${PREFIX}/lib
- make -j && make test
- mv ${TRAVIS_BUILD_DIR} ${OLD_TRAVIS_BUILD_DIR}
- if [[ "$T" == "splint" ]]; then make splint; fi
- if [[ "$T" == "code-check" ]]; then make code-check; fi
- if [[ "$T" == "valgrind" ]]; then make memory-check; fi