2015-08-25 06:50:54 +08:00
|
|
|
language: cpp
|
|
|
|
|
|
|
|
compiler:
|
|
|
|
- gcc
|
|
|
|
|
|
|
|
sudo: true
|
|
|
|
|
|
|
|
before_install:
|
|
|
|
# Qt >= 5.2
|
2015-10-14 20:17:13 +08:00
|
|
|
- sudo add-apt-repository -y ppa:beineri/opt-qt542
|
2015-08-25 06:50:54 +08:00
|
|
|
# GCC >=4.8
|
|
|
|
- if [ "$CXX" == "g++" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; fi
|
|
|
|
- if [ "$CXX" == "clang++" ]; then sudo add-apt-repository -y ppa:h-rayflood/llvm; fi
|
|
|
|
- sudo apt-get update -qq
|
|
|
|
|
|
|
|
install:
|
|
|
|
# install needed Qt stuff
|
|
|
|
- sudo apt-get install -y build-essential qt54base qt54script qt54svg qt54tools qt54xmlpatterns libopenal-dev libxss-dev qrencode libqrencode-dev libglib2.0-dev libgdk-pixbuf2.0-dev libgtk2.0-dev libtool autotools-dev automake checkinstall check libvpx-dev
|
|
|
|
# install needed GCC version and set VM to use
|
|
|
|
- if [ "$CC" == "gcc" ]; then sudo apt-get install -qq gcc-4.9; fi
|
|
|
|
- if [ "$CC" == "gcc" ]; then export CC="gcc-4.9"; fi
|
|
|
|
- if [ "$CXX" == "g++" ]; then sudo apt-get install -qq g++-4.9; fi
|
|
|
|
- if [ "$CXX" == "g++" ]; then export CXX="g++-4.9"; fi
|
|
|
|
# clang
|
|
|
|
- if [ "$CXX" == "clang++" ]; then sudo apt-get install --allow-unauthenticated -qq clang-3.4; fi
|
|
|
|
- if [ "$CXX" == "clang++" ]; then export CXX="clang++-3.4"; fi
|
|
|
|
|
|
|
|
|
|
|
|
before_script:
|
|
|
|
# libopus
|
|
|
|
- wget http://downloads.xiph.org/releases/opus/opus-1.0.3.tar.gz > /dev/null
|
|
|
|
- tar xzf opus-1.0.3.tar.gz > /dev/null
|
|
|
|
- cd opus-1.0.3
|
|
|
|
- ./configure > /dev/null
|
|
|
|
- make -j$(nproc) > /dev/null
|
|
|
|
- sudo make install > /dev/null
|
|
|
|
- cd ..
|
|
|
|
# ffmpeg
|
|
|
|
- if [ ! -e "libs" ]; then mkdir libs; fi
|
|
|
|
- if [ ! -e "ffmpeg" ]; then mkdir ffmpeg; fi
|
|
|
|
#
|
|
|
|
- cd libs/
|
|
|
|
- export PREFIX_DIR="$PWD"
|
|
|
|
#
|
|
|
|
- cd ../ffmpeg
|
|
|
|
- wget http://ffmpeg.org/releases/ffmpeg-2.7.2.tar.bz2
|
|
|
|
- tar xf ffmpeg*
|
|
|
|
- cd ffmpeg*
|
|
|
|
- ./configure --prefix="$PREFIX_DIR" --enable-shared --disable-static --disable-programs --disable-protocols --disable-doc --disable-sdl --disable-avfilter --disable-avresample --disable-filters --disable-iconv --disable-network --disable-muxers --disable-postproc --disable-swresample --disable-swscale-alpha --disable-dct --disable-dwt --disable-lsp --disable-lzo --disable-mdct --disable-rdft --disable-fft --disable-faan --disable-vaapi --disable-vdpau --disable-zlib --disable-xlib --disable-bzlib --disable-lzma --disable-encoders --disable-yasm --enable-memalign-hack
|
|
|
|
- make -j$(nproc)
|
|
|
|
- make install
|
|
|
|
- cd ../../
|
|
|
|
# filter_audio
|
|
|
|
- git clone https://github.com/irungentoo/filter_audio
|
|
|
|
- cd filter_audio
|
|
|
|
- make -j$(nproc)
|
|
|
|
- sudo make install
|
|
|
|
- cd ..
|
|
|
|
# libsodium
|
|
|
|
- git clone git://github.com/jedisct1/libsodium.git
|
|
|
|
- cd libsodium
|
|
|
|
- git checkout tags/1.0.3
|
|
|
|
- ./autogen.sh
|
|
|
|
- ./configure && make -j$(nproc)
|
|
|
|
- sudo checkinstall --install --pkgname libsodium --pkgversion 1.0.0 --nodoc -y
|
|
|
|
- sudo ldconfig
|
|
|
|
- cd ..
|
|
|
|
# toxcore
|
|
|
|
- git clone https://github.com/irungentoo/toxcore.git
|
|
|
|
- cd toxcore
|
|
|
|
- autoreconf -if
|
|
|
|
- ./configure
|
|
|
|
- make -j$(nproc)
|
|
|
|
- sudo make install
|
|
|
|
- echo '/usr/local/lib/' | sudo tee -a /etc/ld.so.conf.d/locallib.conf
|
|
|
|
- sudo ldconfig
|
|
|
|
- cd ..
|
|
|
|
# Qt
|
|
|
|
- source /opt/qt54/bin/qt54-env.sh
|
|
|
|
|
|
|
|
script:
|
|
|
|
- qmake qtox.pro QMAKE_CC="$CC" QMAKE_CXX="$CXX"
|
|
|
|
- $CC --version
|
|
|
|
- $CXX --version
|
|
|
|
- make -j10
|