Skip to content

Commit 41046e2

Browse files
committed
Added check of whether tox.h or toxav.h were edited directly
tox.h and toxav.h must be generated by apidsl instead of edited directly.
1 parent c510e24 commit 41046e2

File tree

1 file changed

+27
-6
lines changed

1 file changed

+27
-6
lines changed

.travis.yml

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,41 @@ compiler:
66
- clang
77

88
before_script:
9+
- sudo add-apt-repository ppa:avsm/ocaml42+opam12 -y
910
- sudo apt-get update -qq
11+
- sudo apt-get install ocaml opam astyle -qq
1012
- sudo apt-get install libconfig-dev libvpx-dev libopus-dev check -qq
13+
# build apidsl
14+
- git clone https://github.com/iphydf/apidsl
15+
- cd apidsl
16+
- export OPAMYES=1
17+
- opam init
18+
- opam install ocamlfind ppx_deriving menhir
19+
- eval `opam config env`
20+
- make -j3
21+
- cd ..
1122
# install sodium, as it's not in Ubuntu Trusty
12-
- git clone git://github.com/jedisct1/libsodium.git > /dev/null
23+
- git clone git://github.com/jedisct1/libsodium.git
1324
- cd libsodium
14-
- git checkout tags/1.0.8 > /dev/null
15-
- ./autogen.sh > /dev/null
16-
- ./configure > /dev/null
17-
- make -j3 >/dev/null
18-
- sudo make install >/dev/null
25+
- git checkout tags/1.0.8
26+
- ./autogen.sh
27+
- ./configure
28+
- make -j3
29+
- sudo make install
1930
- cd ..
2031
- sudo ldconfig
2132

2233
script:
34+
# check if toxcore.h and toxav.h match apidsl tox.in.h and toxav.in.h
35+
# tox.h
36+
- ./apidsl/_build/apigen.native ./other/apidsl/tox.in.h > tox.h
37+
- astyle --options=./other/astyle/astylerc tox.h
38+
- diff -u tox.h ./toxcore/tox.h
39+
# toxav.h
40+
- ./apidsl/_build/apigen.native ./other/apidsl/toxav.in.h > toxav.h
41+
- astyle --options=./other/astyle/astylerc toxav.h
42+
- diff -u toxav.h ./toxav/toxav.h
43+
# build toxcore and run tests
2344
- ./autogen.sh
2445
- CFLAGS="-Ofast -Wall -Wextra" ./configure --enable-daemon --enable-ntox
2546
- make

0 commit comments

Comments
 (0)