代码拉取完成,页面将自动刷新
######
#
# Travis-CI configuration file for FreeCAD.
#
# This build configuration will build and test FreeCAD on both Linux
# and Mac OS X. For Mac OS X, this configuration will also package
# and deploy the build to GitHub provided the following prerequisites
# are satisfied:
#
# GH_TOKEN is defined as a secure environment variable and contains a
# a valid GitHub OAUTH token with repo_deployment scope.
# NOTE: Define this env using the Travis-CI Repo Settings UI
#
# FREECAD_RELEASE: A GitHub Release with this identifier exists in the
# repo. The Travis job will deploy the OS X build to this
# GitHub release name as a release asset.
#
# DEPLOY: Repo setting to deploy (defaults to no deploy to reduce
# Travis build times. Set DEPLOY=1 to enable in repo settings.
######
env:
global:
- GENERATOR="Unix Makefiles"
- CMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE:-Release}
# - FREECAD_RELEASE="0.18"
# - DEPLOY_RELEASE=${DEPLOY_RELEASE:-$FREECAD_RELEASE}
# - OSX_PORTS_CACHE=${OSX_PORTS_CACHE:-FreeCAD/FreeCAD-ports-cache}
# - DEPLOY=${DEPLOY:-0}
# jobs:
# chunk.io key (if needed, obtain it with Yorik, PrzemoF, Kunda1)
# secure: MJu0ZU/9Yqut6bUkHoSrXTV/c/WhCLR0KnHKCsnEU081PYoukzH6ngzgKk7/trAH2In080d/ra4B2OmTNl/LAgV6DXKFY9dO1aG8QwcrHgaMPf0pHYUy/OfwQSFYFByQDV2OEMAHcIWc/dtNkzK2QUi44Kn7d0GtSEiN4s816lriWtjg0vmEGAU8MjvcAGss4gKyn05Xm1NUCYPKgpgIHsywLbpE76lv0eOYoosEuKv5Q9Pb4FMQts02+JUlqE8eY4ZZ3nV8iQbgIDdseOSA7Ixn05zWjU/ZRZ74TrYxMnzfUAwQcJe9OcqoESq+pPWQt5HYG66VmeVxQim1gmsiDASH51U/nswKt0Q4bISj3tVk0YZMFV8Ax+SzPvLEmFZJQGfgO1mg7HdNcz9N9G5JHPawrV19DwYIEFbAw8MCSAoIXFOcPQZUWXCbtjm7NO9vCjMrqyVJMDD9L8omvQajHoajuHbOT8KB250gFokeLj3z8yu++Tz+IrZX5inUMrXsARVt/ALXpi8rJPXmoFMpMUjyWmDPqPWlnqUhLtTtEtKpuOWP8ZnWVwkg4QYOUhCy95C1okJSGkG+ylHWncWfY4mS+UBT525laoh+GOhH+sRW+p2xkI21xGFRqg1oHjjgY1yIYF6nnSHPzxMBRYmZwagyXsjkFG5FPMWR2oYk0Yg
git:
depth: 5000
notifications:
email: false
webhooks:
urls:
- https://webhooks.gitter.im/e/479456663cdf5c84e4d8
on_success: always
on_failure: always
on_start: change
# Inject osx build into matrix - needed to specify image/dist
jobs:
# allow_failures:
# - python: 3.7
fast_finish: true # https://blog.travis-ci.com/2013-11-27-fast-finishing-builds
include:
- if: type != pull_request
os: linux
dist: bionic
language: cpp
compiler: clang
cache: ccache
addons:
apt:
sources:
- sourceline: 'ppa:ubuntu-toolchain-r/test'
- sourceline: 'deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-10 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- clang-10
env:
- CC=clang-10
- CXX=clang++-10
- CMAKE_ARGS="-DPYTHON_EXECUTABLE=/usr/bin/python3 -DBUILD_FEM_NETGEN=ON"
- CACHE_NAME=JOB1
- os: linux
dist: bionic
language: cpp
compiler: gcc-10
cache: ccache
addons:
apt:
sources:
- sourceline: 'ppa:ubuntu-toolchain-r/test'
packages:
- gcc-10
- g++-10
env:
- CC=gcc-10
- CXX=g++-10
- CC_FOR_BUILD=gcc-10
- CXX_FOR_BUILD=g++-10
- CMAKE_ARGS="-DCMAKE_CXX_COMPILER=/usr/bin/c++ -DCMAKE_C_COMPILER=/usr/bin/cc -DPYTHON_EXECUTABLE=/usr/bin/python3 -DBUILD_FEM_NETGEN=ON"
- CACHE_NAME=JOB2
# - os: osx
# osx_image: xcode11.6
# language: cpp
# cache:
# - ccache: true
# - directories:
# - $HOME/.ccache
# - $HOME/Library/Caches/Homebrew
# - /usr/local/Homebrew
# env:
# - CMAKE_OPTS="-DBUILD_QT5=ON -DBUILD_ENABLE_CXX_STD='C++17' -DUSE_PYTHON3=1 -DCMAKE_CXX_FLAGS='-Wno-deprecated-declarations' -DBUILD_FEM_NETGEN=1 -DBUILD_FEM=1 -DBUILD_TECHDRAW=0 -DCMAKE_PREFIX_PATH='/usr/local/opt/qt/lib/cmake;/usr/local/opt/nglib/Contents/Resources' -DBUILD_FEM_NETGEN:BOOL=ON -DFREECAD_USE_EXTERNAL_KDL=ON -DCMAKE_BUILD_TYPE=Release"
# - PATH=/usr/local/bin:$PATH
# - CACHE_NAME=OSX1
- os: windows
language: cpp
env:
- CMAKE_OPTS="-DBUILD_FEM_NETGEN=OFF -DFREECAD_RELEASE_PDB=OFF -DFREECAD_RELEASE_SEH=OFF"
- GENERATOR="Visual Studio 15 2017 Win64"
- PYTHON_MAJOR_VERSION=3
- MSBUILD_PATH="c:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin"
- TEST_PATH="C:\Users\travis\build\FreeCAD\FreeCAD\build\bin"
- CLCACHE_PATH="C:\Users\travis\build\FreeCAD\FreeCAD"
- VS15=true
- CCACHE_TEMPDIR=/tmp/.ccache-temp
- CCACHE_COMPRESS=1
- CCACHE_DIR=$HOME/.ccache
- CACHE_NAME=JOB5
# enable this if clcache extended log is needed
#- CLCACHE_LOG=1
cache:
directories:
- $HOME/clcache
# - language: python
# python: 3.7
# dist: xenial # required for Python >= 3.7 (travis-ci/travis-ci#9069)
# before_install: true
# install: python3 -m pip install flake8
# # fail the build if there are Python syntax errors or undefined names
# script: flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics
before_cache:
- if [ "${TRAVIS_OS_NAME}" = "osx" ]; then brew cleanup; fi
- if [ "${TRAVIS_OS_NAME}" = "osx" ]; then find /usr/local/Homebrew \! -regex ".+\.git.+" -delete; fi
before_install:
# - eval "$(curl -fsSL "https://raw.githubusercontent.com/${OSX_PORTS_CACHE}/v${FREECAD_RELEASE}/travis-helpers.sh")"
- |
case "${TRAVIS_OS_NAME}" in
"linux")
# Daily PPA for OCCT, Pivy, Netgen, PySide ... packages
sudo apt-add-repository -y ppa:freecad-maintainers/freecad-daily
sudo apt-get update -qq
# Build deps
sudo apt-get install -y --no-install-recommends \
python-dev \
python-pyside \
python-matplotlib \
python3-dev \
python3-pyside \
python3-matplotlib \
libboost1.65-dev \
libboost-filesystem1.65-dev \
libboost-program-options1.65-dev \
libboost-python1.65-dev \
libboost-regex1.65-dev \
libboost-signals1.65-dev \
libboost-system1.65-dev \
libboost-thread1.65-dev \
libxerces-c-dev \
libocct-data-exchange-dev \
libocct-ocaf-dev \
libocct-visualization-dev \
libvtk7-dev \
libmedc-dev \
pybind11-dev \
swig \
qt4-qmake \
libqt4-opengl-dev \
libqtwebkit-dev \
qtbase5-dev \
libqt5xmlpatterns5-dev \
libqt5svg5-dev \
libqt5opengl5-dev \
qttools5-dev \
qtwebengine5-dev \
libcoin80-dev \
libpyside-dev \
libpyside2-dev \
libshiboken-dev \
libshiboken2-dev \
pyside-tools \
pyside2-tools \
doxygen \
graphviz \
libnglib-dev \
netgen \
netgen-headers \
libmetis-dev \
libspnav-dev
# Runtime deps
sudo apt-get install -y --no-install-recommends freecad-daily-python3 python-pivy python3-pivy python-ply python3-ply
# Use newer Eigen to suppress warnings
# https://github.com/FreeCAD/FreeCAD/pull/3485
wget http://mirrors.kernel.org/ubuntu/pool/universe/e/eigen3/libeigen3-dev_3.3.7-2_all.deb
sudo dpkg -i libeigen3-dev_3.3.7-2_all.deb
export DISPLAY=:99.0
sh -e /etc/init.d/xvfb start
export INSTALLED_APP_PATH="/usr/local/bin/FreeCAD"
export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/netgen/:$LD_LIRBARY_PATH
;;
"osx")
xcodebuild -version -sdk
brew --config
brew install ccache
brew install coreutils
brew update >/dev/null
brew --config
brew update
brew upgrade
brew install [email protected]
brew unlink [email protected]
brew link --overwrite --force [email protected]
rm /usr/local/bin/python
ln -s /usr/local/bin/python3 /usr/local/bin/python
pip3 install six
pip3 install pyyaml
pip3 install ply
export PATH=/usr/local/bin:$PATH
brew reinstall [email protected]
brew link --force [email protected]
which python
python --version
brew install boost
brew install boost-python3
brew tap FreeCAD/freecad
brew install freecad/freecad/coin
brew install freecad/freecad/nglib
brew install freecad/freecad/med-file
brew install freecad/freecad/opencamlib
brew install freecad/freecad/shiboken2
brew install freecad/freecad/pyside2
brew install freecad/freecad/pyside2-tools
brew install freecad/freecad/pivy
brew install freecad/freecad/matplotlib
##Install the 3DConnexion frameworks
if [ ! -d /Library/Frameworks/3DconnexionClient.framework ]; then
curl -o /tmp/3dFW.dmg -L 'https://download.3dconnexion.com/drivers/mac/10-6-6_360DF97D-ED08-4ccf-A55E-0BF905E58476/3DxWareMac_v10-6-6_r3234.dmg'
hdiutil attach -readonly /tmp/3dFW.dmg
sudo installer -package /Volumes/3Dconnexion\ Software/Install\ 3Dconnexion\ software.pkg -target /
diskutil eject /Volumes/3Dconnexion\ Software
fi
export CMAKE_OPTS="${CMAKE_OPTS} -DFREECAD_CREATE_MAC_APP=OFF"
export INSTALLED_APP_PATH="/usr/local/MacOS/FreeCAD"
export CMAKE_ARGS="${CMAKE_OPTS} -DFREECAD_USE_EXTERNAL_KDL=ON"
brew link --overwrite matplotlib
if [ -f "/usr/local/Cellar/opencascade/7.4.0_1/include/opencascade/Standard_Macro.hxx" ]; then
sed '1,$s/\[\[nodiscard\]\]//' /usr/local/Cellar/opencascade/7.4.0_1/include/opencascade/Standard_Macro.hxx > /tmp/Standard_Macro.hxx && cp /tmp/Standard_Macro.hxx /usr/local/Cellar/opencascade/7.4.0_1/include/opencascade/Standard_Macro.hxx ;
fi
;;
"windows")
#choco install -y python
#py -m pip install --quiet --upgrade pip
#py -m pip install git+https://github.com/frerich/[email protected]
curl -L https://github.com/frerich/clcache/releases/download/v4.2.0/clcache-4.2.0.zip --output clcache-4.2.0.zip
7z x clcache-4.2.0.zip > /dev/null
export PATH=$CLCACHE_PATH:$PATH
export PATH=$TEST_PATH:$PATH
#reset clcache hit stats
cmd.exe //C 'C:\Users\travis\build\FreeCAD\FreeCAD\clcache.exe -z'
# clcache stats before compilation
cmd.exe //C 'C:\Users\travis\build\FreeCAD\FreeCAD\clcache.exe -s'
curl -L https://github.com/FreeCAD/FreeCAD/releases/download/0.19.1/FreeCADLibs_12.5.3_x64_VC17.7z --output FreeCADLibs.7z
7z x FreeCADLibs.7z -oFreeCADLibs > /dev/null
rm -f FreeCADLibs.7z
export FREECAD_LIBPACK_DIR="$TRAVIS_BUILD_DIR\FreeCADLibs\FreeCADLibs_12.5.3_x64_VC17"
export CMAKE_ARGS="${CMAKE_OPTS} -DFREECAD_LIBPACK_DIR=$TRAVIS_BUILD_DIR\FreeCADLibs\FreeCADLibs_12.5.3_x64_VC17 -DPYTHON_EXECUTABLE=$TRAVIS_BUILD_DIR\FreeCADLibs\FreeCADLibs_12.5.3_x64_VC17\bin\python.exe \
-DBUILD_QT5=TRUE"
export PATH=$MSBUILD_PATH:$PATH
;;
*)
echo "Invalid or unsupported operating system ${TRAVIS_OS_NAME}"
exit 1
;;
esac
install:
####
# Build FreeCAD with cmake options set above for each platform
##
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then export PATH="/usr/local/bin:/usr/local/opt/ccache/libexec:$PATH"; fi
- echo ${CMAKE_ARGS}
- mkdir build && cd build && cmake -Wno-dev -G"${GENERATOR}" ${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} ../
script:
####
# Install FreeCAD and run unit tests. Test failures will fail the build
##
# MSBuild.exe /m FreeCAD.sln
- |
if [ "${TRAVIS_OS_NAME}" == "windows" ]; then
# https://travis-ci.community/t/vcvarsall-bat-freezes-on-new-1809-based-windows-images/7098/6
# call msbuild using clcache
#cmd.exe //C '"C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Auxiliary\Build\vcvarsall.bat" amd64 && MSBuild.exe FreeCAD.sln /p:CLToolExe=clcache.exe /p:TrackFileAccess=false /p:CLToolPath=C:\Users\travis\build\FreeCAD\FreeCAD /m:2 /nologo /verbosity:minimal /p:Configuration=Release /p:Platform=x64'
cmd.exe //C 'C:\Users\travis\build\FreeCAD\FreeCAD\.travis\build.bat'
# ls -lahR
mkdir bin/
mv ../FreeCADLibs/FreeCADLibs_12.5.3_x64_VC17/bin/* bin/
du -hs bin/
# show clcache hit stats
cmd.exe //C 'C:\Users\travis\build\FreeCAD\FreeCAD\clcache.exe -s'
# run the tests
#cmd.exe //C 'cd C:\Users\travis\build\FreeCAD\FreeCAD\build\bin && FreeCADCmd.exe --run-test 0'
# Make build fail if ANY of the following fails
#set -ev
winpty.exe -Xallow-non-tty -Xplain /C/Users/travis/build/FreeCAD/FreeCAD/build/bin/FreeCADCmd.exe --run-test 0 | tee runlog.txt
grep -q FAILED runlog.txt ; [ $? == 1 ] && echo "Build succeeded and tests passed!" || ( echo "Tests failed!" && false )
else
# Stop compiling (GCC) after 2 hrs 50 min (3 hrs limit).
# Preserves created ccache for the next build job.
# if [ "${TRAVIS_OS_NAME}" == "linux" ]; then sudo timeout -k 175m 170m make -j2 install || true; fi
# if [ "${TRAVIS_OS_NAME}" == "osx" ]; then sudo gtimeout -s KILL make -j2 install; fi
cat $HOME/.ccache/ccache.conf
ccache -z -s
df -h
if [ "${TRAVIS_OS_NAME}" == "osx" ]; then export PATH="/usr/local/opt/ccacche/libexec:$PATH"; sudo gtimeout -s KILL 7200 make -j2; [ $? == 124 ] && { ccache -s; return 0; } fi
if [ "${TRAVIS_OS_NAME}" == "linux" ]; then sudo timeout -k 175m 170m make -j2 install || true; fi
sudo make -j2 install
ccache -s
${INSTALLED_APP_PATH} --console --run-test 0 || travis_terminate 1
${INSTALLED_APP_PATH} --log-file /tmp/FreeCAD_installed.log &
sleep 10 && pkill FreeCAD
cat /tmp/FreeCAD_installed.log
grep --file=../.log_errors /tmp/FreeCAD_installed.log ; [ $? == 1 ] && echo "No errors from .log_errors file found in the log after start from /usr/local/bin" || ( echo "Error from .log_errors found!" && false )
fi
#after_success:
# Package and deploy the build to GitHub. This will only run for builds on
# master (i.e. pull requests are only built and tested but not deployed).
#
# GH_TOKEN must be set in order to deploy releases to GitHub
#
#- |
# if [ "${TRAVIS_OS_NAME}" == "osx" -a "${TRAVIS_PULL_REQUEST}" == "false" -a "${DEPLOY}" == "1" ]; then
# brew ls --versions jq || brew install jq
# npm install -g appdmg
# export VSN=$(python ${TRAVIS_BUILD_DIR}/src/Tools/ArchiveNameFromVersionHeader.py ${TRAVIS_BUILD_DIR}/build/src/Build/Version.h)
# export DEPLOYMENT_ARCHIVE=${VSN}-${QT}.dmg
# appdmg ${TRAVIS_BUILD_DIR}/src/MacAppBundle/DiskImage/layout.json "${DEPLOYMENT_ARCHIVE}"
# deployContext=$(create_helper_context repo=${TRAVIS_REPO_SLUG} auth_token=${GH_TOKEN} release=${DEPLOY_RELEASE})
# gitHub_deploy_asset_to_release_named $deployContext ${DEPLOYMENT_ARCHIVE}
# gitHub_prune_assets_for_release_named $deployContext "-${QT}" 1
# fi
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。