From 87433500297949091454517819fd52a652c5f23a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5vard=20Pettersson?= Date: Fri, 3 Feb 2017 16:05:41 -0800 Subject: [PATCH] Update .travis.yml for TokTok c-toxcore --- .travis.yml | 71 +++++++++++++++++++++++------------------------------ 1 file changed, 31 insertions(+), 40 deletions(-) diff --git a/.travis.yml b/.travis.yml index 67ced84..6908f97 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,48 +1,39 @@ -language: c +dist: trusty +sudo: false -before_install: - - sudo add-apt-repository -y ppa:ubuntu-sdk-team/ppa - - sudo add-apt-repository -y ppa:kalakris/cmake - - sudo apt-get update -q +addons: + apt: + sources: + - sourceline: 'deb https://weechat.org/ubuntu trusty main' + packages: + - weechat-dev - # install libtoxav dependencies and a newer version of cmake - - sudo apt-get install -y libopus-dev libvpx-dev cmake +env: + # install dependencies under $HOME because we don't have sudo + - DEPENDENCY_DIR=$HOME/dependencies install: - - _libsodium_version=1.0.0 - - _weechat_version=v1.5 + # install libsodium, required by libtoxcore + - mkdir libsodium && pushd libsodium + && curl -fSsL "https://download.libsodium.org/libsodium/releases/libsodium-1.0.11.tar.gz" + | tar -xz --strip-components 1 + && ./configure --prefix="$DEPENDENCY_DIR" + && make install + && popd - # install libsodium (libtoxcore dependency) - - git clone git://github.com/jedisct1/libsodium.git - - pushd libsodium - - git checkout tags/${_libsodium_version} - - ./autogen.sh - - ./configure - - make -j3 - - sudo make install - - popd - - # install libtoxcore - - git clone git://github.com/irungentoo/toxcore - - pushd toxcore - - autoreconf -i - - ./configure --disable-testing --disable-ntox - - make -j3 - - sudo make install - - popd - - # install weechat - - git clone git://github.com/weechat/weechat - - pushd weechat - - git checkout tags/${_weechat_version} - - mkdir build && cd build - - cmake .. - - make -j3 - - sudo make install - - popd + # install libtoxcore + - mkdir c-toxcore && pushd c-toxcore + && curl -fSsL "https://github.com/TokTok/c-toxcore/archive/v0.1.6.tar.gz" + | tar -xz --strip-components 1 + && autoreconf -if + && ./configure --disable-ntox --disable-tests --disable-daemon + --with-libsodium-libs="$DEPENDENCY_DIR/lib" + --with-libsodium-headers="$DEPENDENCY_DIR/include" + --prefix="$DEPENDENCY_DIR" + && make install + && popd script: - mkdir build && cd build - - cmake .. - - make -j3 - + - cmake -DCMAKE_PREFIX_PATH:PATH="$DEPENDENCY_DIR" .. + - make