Skip to content

Commit

Permalink
Fix OSX tests: find(1) doesn't work like on Linux.
Browse files Browse the repository at this point in the history
  • Loading branch information
iphydf committed Feb 21, 2018
1 parent ee53d96 commit e2270c2
Show file tree
Hide file tree
Showing 2 changed files with 72 additions and 70 deletions.
126 changes: 63 additions & 63 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,70 +8,70 @@ language: c

matrix:
include:
- stage: "Stage 1"
env: JOB=toxcore ENV=linux
compiler: clang
addons:
apt: &apt-dependencies
packages:
- libconfig-dev # For tox-bootstrapd.
- libcv-dev # For av_test.
- libhighgui-dev # For av_test.
- libopencv-contrib-dev # For av_test.
- libopus-dev # For toxav.
- libsndfile1-dev # For av_test.
- libgtest-dev # For unit tests.
- libvpx-dev # For toxav.
- portaudio19-dev # For av_test.
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=autotools ENV=linux
compiler: gcc
addons:
apt: *apt-dependencies
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=toxcore ENV=windows ARCH=i686
group: deprecated-2017Q4
services:
- docker
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=toxcore ENV=windows ARCH=x86_64
group: deprecated-2017Q4
services:
- docker
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=installmd ENV=windows SUPPORT_ARCH_i686=true SUPPORT_ARCH_x86_64=false SUPPORT_TEST=true ENABLE_ARCH_i686=true ENABLE_ARCH_x86_64=false ENABLE_TEST=true ALLOW_TEST_FAILURE=true
services:
- docker
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=installmd ENV=windows SUPPORT_ARCH_i686=false SUPPORT_ARCH_x86_64=true SUPPORT_TEST=true ENABLE_ARCH_i686=false ENABLE_ARCH_x86_64=true ENABLE_TEST=true ALLOW_TEST_FAILURE=true
services:
- docker
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=toxcore ENV=freebsd
dist: trusty
sudo: required
install: other/travis/phase $JOB $ENV install stage1
script: other/travis/phase $JOB $ENV script stage1
- stage: "Stage 1"
if: type IN (push, api, cron)
env: JOB=tox-bootstrapd-docker ENV=linux
services:
- docker
sudo: required
# - stage: "Stage 1"
# env: JOB=toxcore ENV=linux
# compiler: clang
# addons:
# apt: &apt-dependencies
# packages:
# - libconfig-dev # For tox-bootstrapd.
# - libcv-dev # For av_test.
# - libhighgui-dev # For av_test.
# - libopencv-contrib-dev # For av_test.
# - libopus-dev # For toxav.
# - libsndfile1-dev # For av_test.
# - libgtest-dev # For unit tests.
# - libvpx-dev # For toxav.
# - portaudio19-dev # For av_test.
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=autotools ENV=linux
# compiler: gcc
# addons:
# apt: *apt-dependencies
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=toxcore ENV=windows ARCH=i686
# group: deprecated-2017Q4
# services:
# - docker
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=toxcore ENV=windows ARCH=x86_64
# group: deprecated-2017Q4
# services:
# - docker
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=installmd ENV=windows SUPPORT_ARCH_i686=true SUPPORT_ARCH_x86_64=false SUPPORT_TEST=true ENABLE_ARCH_i686=true ENABLE_ARCH_x86_64=false ENABLE_TEST=true ALLOW_TEST_FAILURE=true
# services:
# - docker
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=installmd ENV=windows SUPPORT_ARCH_i686=false SUPPORT_ARCH_x86_64=true SUPPORT_TEST=true ENABLE_ARCH_i686=false ENABLE_ARCH_x86_64=true ENABLE_TEST=true ALLOW_TEST_FAILURE=true
# services:
# - docker
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=toxcore ENV=freebsd
# dist: trusty
# sudo: required
# install: other/travis/phase $JOB $ENV install stage1
# script: other/travis/phase $JOB $ENV script stage1
# - stage: "Stage 1"
# if: type IN (push, api, cron)
# env: JOB=tox-bootstrapd-docker ENV=linux
# services:
# - docker
# sudo: required
# - stage: "Stage 2"
# if: type IN (push, api, cron)
# env: JOB=toxcore ENV=freebsd
# dist: trusty
# sudo: required
# install: other/travis/phase $JOB $ENV install stage2
- stage: "Stage 2"
if: type IN (push, api, cron)
env: JOB=toxcore ENV=freebsd
dist: trusty
sudo: required
install: other/travis/phase $JOB $ENV install stage2
- stage: "Stage 2"
if: type IN (push, api, cron)
# if: type IN (push, api, cron)
env: JOB=toxcore ENV=osx RUN_TESTS=true
os: osx
fast_finish: true
Expand Down
16 changes: 9 additions & 7 deletions other/astyle/format-source
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh

set -e
set -ex

SOURCE_DIR="$1"
ASTYLE="$2"
Expand Down Expand Up @@ -47,12 +47,14 @@ if grep '<unresolved>' */*.h; then
exit 1
fi

SOURCES=`find . \
"-(" -name "*.[ch]" -or -name "*.cpp" "-)" \
-and -not -name "*.api.h" \
-and -not -wholename "./super_donators/*" \
-and -not -wholename "./third_party/*" \
-and -not -wholename "./toxencryptsave/crypto_pwhash*"`
FIND="find ."
FIND="$FIND '-(' -name '*.[ch]' -or -name '*.cpp' '-)'"
FIND="$FIND -and -not -name '*.api.h'"
FIND="$FIND -and -not -wholename './super_donators/*'"
FIND="$FIND -and -not -wholename './third_party/*'"
FIND="$FIND -and -not -wholename './toxencryptsave/crypto_pwhash*'"

SOURCES=`$FIND`

$ASTYLE -n --options=other/astyle/astylerc $SOURCES

Expand Down

0 comments on commit e2270c2

Please sign in to comment.