compile: override: - "echo 'TODO(zoff99): fix compile'" test: override: - "echo 'TODO(zoff99): fix compile'" #machine: # environment: # MAKEFLAGS: "j4" ## --- Android build --- # _toolchain_: "/home/ubuntu/c-toxcore/toolchains/" # _s_: "/home/ubuntu/c-toxcore/src/" # AND_PATH: "$_toolchain_/arm-linux-androideabi/bin:$PATH" # AND_PKG_CONFIG_PATH: "$_toolchain_/arm-linux-androideabi/sysroot/usr/lib/pkgconfig" # AND_CC: "$_toolchain_/arm-linux-androideabi/bin/arm-linux-androideabi-clang" # AND_CXX: "$_toolchain_/arm-linux-androideabi/bin/arm-linux-androideabi-clang++" ## --- Android build --- #dependencies: # pre: # - sudo apt-get update # - sudo bash -c "echo 'deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse' >> /etc/apt/sources.list" # add backports repo # - sudo apt-get update # - sudo apt-get install astyle/trusty-backports # - sudo apt-get install clang # - sudo apt-get install build-essential libtool autotools-dev automake checkinstall git yasm # - sudo apt-get install libopus-dev libvpx-dev pkg-config # ## ------------ network_test requires that "localhost" resolves to ::1 ------------ # - sudo bash -c "echo '::1 localhost ipv6-localhost ipv6-loopback' >> /etc/hosts" # ipv6 localhost entry ## ------------ network_test requires that "localhost" resolves to ::1 ------------ # # - sudo bash -c "echo /usr/local/lib/x86_64-linux-gnu > /etc/ld.so.conf.d/fix685519.conf" # fix https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=685519 # # - java -version ; exit 0 # - gcc --version ; exit 0 # - clang --version ; exit 0 # - astyle --version ; exit 0 # #compile: # override: # ### ----- check code style ------ # - cd .. ; cp -av c-toxcore ./astyle_check/ # - cd ../astyle_check/ ; ls -al other/astyle/astylerc # - cd ../astyle_check/ ; # SOURCES=`find . -name "*.[ch]" -and -not -name "*.api.h" -and -not -wholename "*crypto_pwhash*" -and -not -wholename "./super_donators/*"|sort`; # astyle -n --options=other/astyle/astylerc $SOURCES ; exit 0 # - cd ../astyle_check/ ; git --no-pager diff # - cd ../astyle_check/ ; git diff | cat > $CIRCLE_ARTIFACTS/astyle_check.patch 2>&1 # ### ----- check code style ------ # # ### ------- get libsodium ------- # - mkdir ~/libsodium # - cd ~/libsodium/ ; git clone https://github.com/jedisct1/libsodium.git # - cd ~/libsodium/ ; cd libsodium/ ; git checkout tags/1.0.11 # - cd ~/libsodium/ ; cd libsodium/ ; ./autogen.sh # - cd ~/libsodium/ ; cd libsodium/ ; ./configure && make check # - cd ~/libsodium/ ; cd libsodium/ ; sudo bash -c "printf 'y\naa\n\n' | checkinstall --install --pkgname libsodium --pkgversion 1.0.0 --nodoc --deldesc=no --pkglicense='GPL2'" # - cd ~/libsodium/ ; cd libsodium/ ; sudo ldconfig # ### ------- get libsodium ------- # ###### ------------ BUILD ------------ # - cmake -DASAN=ON -DDEBUG=ON -DSTRICT_ABI=ON -DTRACE=ON -DWARNINGS=OFF . # #- cmake . # - make # - sudo make install # - sudo ldconfig -v 2>/dev/null | grep toxcore # - sudo ldconfig -v 2>/dev/null | grep sodium ###### ------------ BUILD ------------ # ## --- Android build --- # - echo 'export PATH="$AND_PATH";export PKG_CONFIG_PATH="$AND_PKG_CONFIG_PATH";export CC="$AND_CC";export CXX="$AND_CXX";export CPPFLAGS="";export LDFLAGS=""' > ~/pp # - chmod u+x ~/pp # - mkdir -p "$_s_" # # - rm -Rf /home/ubuntu/install_dest/ ; mkdir -p /home/ubuntu/install_dest/ # - mkdir -p $CIRCLE_ARTIFACTS/android/ # # # - . ~/pp;mkdir -p "$PKG_CONFIG_PATH" # - . ~/pp;curl -s http://dl.google.com/android/repository/android-ndk-r13b-linux-x86_64.zip -o android-ndk-r13b-linux-x86_64.zip # - . ~/pp;unzip android-ndk-r13b-linux-x86_64.zip # - . ~/pp;mv -v /home/ubuntu/c-toxcore/android-ndk-r13b /home/ubuntu/android-ndk # - . ~/pp;/home/ubuntu/android-ndk/build/tools/make_standalone_toolchain.py --arch arm --install-dir "$_toolchain_"/arm-linux-androideabi --api 12 --force # # - . ~/pp;cd $_s_;git clone --depth=1 --branch=v1.3.0 https://github.com/yasm/yasm.git # - . ~/pp;cd $_s_/yasm/;autoreconf -fi # - . ~/pp;rm -Rf ~/build/ # - . ~/pp;mkdir -p ~/build/ # - . ~/pp;cd ~/build/;$_s_/yasm/configure --prefix="$_toolchain_"/arm-linux-androideabi/sysroot/usr --disable-shared --disable-soname-versions --host=arm-linux-androideabi --with-sysroot="$_toolchain_"/arm-linux-androideabi/sysroot # - . ~/pp;cd ~/build/;make -j4 # - . ~/pp;cd ~/build/;make install # # # - . ~/pp;cd $_s_;git clone --depth=1 --branch=v1.6.0 https://github.com/webmproject/libvpx.git # - . ~/pp;rm -Rf ~/build/ # - . ~/pp;mkdir -p ~/build/ # - . ~/pp;cd ~/build/;$_s_/libvpx/configure --prefix="$_toolchain_"/arm-linux-androideabi/sysroot/usr --disable-examples --disable-unit-tests --sdk-path=/home/ubuntu/android-ndk --target=armv7-android-gcc # - . ~/pp;cd ~/build/;make -j4 # - . ~/pp;cd ~/build/;make install # - . ~/pp;cd ~/build/;make clean # - rm -Rf /home/ubuntu/install_dest/ ; mkdir -p /home/ubuntu/install_dest/ # - . ~/pp;cd ~/build/;make DESTDIR=/home/ubuntu/install_dest/ install # - cd /home/ubuntu/install_dest/ ; cd home/ubuntu/c-toxcore/toolchains/arm-linux-androideabi/sysroot/ ; zip -r $CIRCLE_ARTIFACTS/android/libvpx.zip * # # # - . ~/pp;cd $_s_;git clone --depth=1 --branch=v1.1.3 https://github.com/xiph/opus.git # - . ~/pp;cd $_s_/opus/;autoreconf -fi # - . ~/pp;rm -Rf ~/build/ # - . ~/pp;mkdir -p ~/build/ # - . ~/pp;cd ~/build/;$_s_/opus/configure --prefix="$_toolchain_"/arm-linux-androideabi/sysroot/usr --disable-shared --disable-soname-versions --host=arm-linux-androideabi --with-sysroot="$_toolchain_"/arm-linux-androideabi/sysroot # - . ~/pp;cd ~/build/;make -j4 # - . ~/pp;cd ~/build/;make install # - . ~/pp;cd ~/build/;make clean # - rm -Rf /home/ubuntu/install_dest/ ; mkdir -p /home/ubuntu/install_dest/ # - . ~/pp;cd ~/build/;make DESTDIR=/home/ubuntu/install_dest/ install # - cd /home/ubuntu/install_dest/ ; cd home/ubuntu/c-toxcore/toolchains/arm-linux-androideabi/sysroot/ ; zip -r $CIRCLE_ARTIFACTS/android/opus.zip * # # # - . ~/pp;cd $_s_;git clone --depth=1 --branch=1.0.11 https://github.com/jedisct1/libsodium.git # - . ~/pp;cd $_s_/libsodium/;autoreconf -fi # - . ~/pp;rm -Rf ~/build/ # - . ~/pp;mkdir -p ~/build/ # - . ~/pp;cd ~/build/;$_s_/libsodium/configure --prefix="$_toolchain_"/arm-linux-androideabi/sysroot/usr --disable-shared --disable-soname-versions --host=arm-linux-androideabi --with-sysroot="$_toolchain_"/arm-linux-androideabi/sysroot --enable-minimal --disable-pie # - . ~/pp;cd ~/build/;make -j4 # - . ~/pp;cd ~/build/;make install # - . ~/pp;cd ~/build/;make clean # - rm -Rf /home/ubuntu/install_dest/ ; mkdir -p /home/ubuntu/install_dest/ # - . ~/pp;cd ~/build/;make DESTDIR=/home/ubuntu/install_dest/ install # - cd /home/ubuntu/install_dest/ ; cd home/ubuntu/c-toxcore/toolchains/arm-linux-androideabi/sysroot/ ; zip -r $CIRCLE_ARTIFACTS/android/libsodium.zip * # # # - . ~/pp;cd ~/c-toxcore/;autoreconf -fi # - . ~/pp;rm -Rf ~/build/ # - . ~/pp;mkdir -p ~/build/ # - . ~/pp;cd ~/build/;~/c-toxcore/configure --prefix="$_toolchain_"/arm-linux-androideabi/sysroot/usr --disable-soname-versions --host=arm-linux-androideabi --with-sysroot="$_toolchain_"/arm-linux-androideabi/sysroot --disable-testing --disable-rt # - . ~/pp;cd ~/build/;make -j4 # - . ~/pp;cd ~/build/;make install # - . ~/pp;cd ~/build/;make clean # - rm -Rf /home/ubuntu/install_dest/ ; mkdir -p /home/ubuntu/install_dest/ # - . ~/pp;cd ~/build/;make DESTDIR=/home/ubuntu/install_dest/ install # - cd /home/ubuntu/install_dest/ ; cd home/ubuntu/c-toxcore/toolchains/arm-linux-androideabi/sysroot/ ; zip -r $CIRCLE_ARTIFACTS/android/c-toxcore.zip * ## --- Android build --- # #test: # override: # - make test ARGS="--rerun-failed" CTEST_OUTPUT_ON_FAILURE=1 || make test ARGS="--rerun-failed" CTEST_OUTPUT_ON_FAILURE=1 || make test ARGS="--rerun-failed" CTEST_OUTPUT_ON_FAILURE=1 || make test ARGS="--rerun-failed" CTEST_OUTPUT_ON_FAILURE=1 || make test ARGS="--rerun-failed" CTEST_OUTPUT_ON_FAILURE=1