Interim fix for Travis macOS Build

This commit is contained in:
Takeshi Nakatani 2020-06-30 13:22:38 +00:00 committed by Andrew Gaul
parent 3f6b5ae6a5
commit 62c8be85d6
2 changed files with 37 additions and 8 deletions

View File

@ -19,8 +19,10 @@
#
language: cpp
dist: xenial
os: linux
matrix:
jobs:
include:
- os: linux
dist: trusty
@ -29,7 +31,7 @@ matrix:
- sudo apt-get update -qq
- sudo apt-get install -qq attr cppcheck libfuse-dev openjdk-7-jdk
- sudo update-alternatives --set java /usr/lib/jvm/java-7-openjdk-amd64/jre/bin/java
- sudo pip install --upgrade awscli
- sudo -H pip install --upgrade awscli
script:
- ./autogen.sh
- ./configure CPPFLAGS='-I/usr/local/opt/openssl/include' CXXFLAGS='-std=c++03 -DS3FS_PTHREAD_ERRORCHECK=1'
@ -57,20 +59,40 @@ matrix:
rm -rf "$TAPS/caskroom/homebrew-cask";
fi;
if [ ! -f $HOME/.osx_cache/cached ]; then
brew tap homebrew/homebrew-cask;
echo "==> [Not found cache] brew tap homebrew/homebrew-cask";
echo "[NOTE]";
echo "If brew is executed without HOMEBREW_NO_AUTO_UPDATE=1,";
echo "python3 cannot be installed, so this is added as a temporary workaround.";
echo "If it is xcode 9.4 or higher, clear this patch.";
HOMEBREW_NO_AUTO_UPDATE=1 brew tap homebrew/homebrew-cask;
else
echo "==> [Found cache] HOMEBREW_NO_AUTO_UPDATE=1 brew tap homebrew/homebrew-cask";
HOMEBREW_NO_AUTO_UPDATE=1 brew tap homebrew/homebrew-cask;
fi
- HOMEBREW_NO_AUTO_UPDATE=1 brew cask install osxfuse
- S3FS_BREW_PACKAGES='awscli cppcheck truncate';
- S3FS_BREW_PACKAGES='cppcheck python3';
for s3fs_brew_pkg in ${S3FS_BREW_PACKAGES}; do
brew list | grep -q ${s3fs_brew_pkg};
if [ $? -eq 0 ]; then
brew outdated | grep -q ${s3fs_brew_pkg} && HOMEBREW_NO_AUTO_UPDATE=1 brew upgrade ${s3fs_brew_pkg};
brew outdated | grep -q ${s3fs_brew_pkg};
if [ $? -eq 0 ]; then
echo "==> Try to upgrade ${s3fs_brew_pkg}";
HOMEBREW_NO_AUTO_UPDATE=1 brew upgrade ${s3fs_brew_pkg};
fi
else
echo "==> Try to install ${s3fs_brew_pkg}";
HOMEBREW_NO_AUTO_UPDATE=1 brew install ${s3fs_brew_pkg};
fi;
done
- pip3 --version;
if [ $? -eq 0 ]; then
echo "==> Try to install awscli by pip3";
sudo -H pip3 install awscli;
else
echo "==> Try to install awscli by pip";
curl https://bootstrap.pypa.io/get-pip.py | sudo python;
sudo -H pip install awscli --ignore-installed matplotlib;
fi
- if [ -f /Library/Filesystems/osxfusefs.fs/Support/load_osxfusefs ]; then
sudo chmod +s /Library/Filesystems/osxfusefs.fs/Support/load_osxfusefs;
elif [ -f /Library/Filesystems/osxfuse.fs/Contents/Resources/load_osxfuse ]; then
@ -78,7 +100,14 @@ matrix:
else
exit 1;
fi
- sudo ln -s /usr/local/opt/coreutils/bin/gstdbuf /usr/local/bin/stdbuf
- if [ ! -f /usr/local/bin/truncate ]; then
echo "==> Make symbolic link truncate to gtruncate";
sudo ln -s /usr/local/opt/coreutils/bin/gtruncate /usr/local/bin/truncate;
fi
- if [ ! -f /usr/local/bin/stdbuf ]; then
echo "==> Make symbolic link stdbuf to gstdbuf";
sudo ln -s /usr/local/opt/coreutils/bin/gstdbuf /usr/local/bin/stdbuf;
fi
script:
- ./autogen.sh
- PKG_CONFIG_PATH=/usr/local/opt/curl/lib/pkgconfig:/usr/local/opt/openssl/lib/pkgconfig ./configure CXXFLAGS='-std=c++03 -DS3FS_PTHREAD_ERRORCHECK=1'
@ -103,7 +132,7 @@ matrix:
- sudo apt-get update -qq
- sudo apt-get install -qq attr cppcheck libfuse-dev openjdk-7-jdk
- sudo update-alternatives --set java /usr/lib/jvm/java-7-openjdk-ppc64el/jre/bin/java
- sudo pip install --upgrade awscli
- sudo -H pip install --upgrade awscli
script:
- ./autogen.sh
- ./configure CPPFLAGS='-I/usr/local/opt/openssl/include' CXXFLAGS='-std=c++03 -DS3FS_PTHREAD_ERRORCHECK=1'

View File

@ -924,7 +924,7 @@ function test_mix_upload_entities() {
}
function test_ut_ossfs {
echo "Testing ossfs python ut..."
describe "Testing ossfs python ut..."
export TEST_BUCKET_MOUNT_POINT=$TEST_BUCKET_MOUNT_POINT_1
../../ut_test.py
}