diff --git a/.travis.yml b/.travis.yml index be8041dcb8..454002e20c 100755 --- a/.travis.yml +++ b/.travis.yml @@ -36,7 +36,7 @@ cache: language: cpp python: - 2.7 - - 3.4 + - 3.6 # Inject osx build into matrix - needed to specify image/dist matrix: @@ -46,26 +46,25 @@ matrix: fast_finish: true # https://blog.travis-ci.com/2013-11-27-fast-finishing-builds include: - os: linux - dist: trusty + dist: bionic compiler: clang - env: - - CMAKE_OPTS="-DBUILD_FEM_NETGEN=ON" - - PYTHON_MAJOR_VERSION=2 - - - os: linux - dist: trusty - compiler: gcc env: - - CMAKE_OPTS="-DBUILD_FEM_NETGEN=ON" - - PYTHON_MAJOR_VERSION=2 - - - os: linux - dist: trusty - compiler: gcc - env: - - CMAKE_OPTS="-DBUILD_FEM_NETGEN=ON" + - CMAKE_OPTS="-DBUILD_FEM_NETGEN=ON -DBUILD_QT5=ON" - PYTHON_MAJOR_VERSION=3 + - os: linux + dist: bionic + compiler: gcc + env: + - CMAKE_OPTS="-DBUILD_FEM_NETGEN=ON -DBUILD_QT5=ON" + - PYTHON_MAJOR_VERSION=3 + + - os: linux + dist: bionic + compiler: gcc + env: + - PYTHON_MAJOR_VERSION=2 + - os: windows language: cpp filter_secrets: false @@ -119,67 +118,54 @@ before_install: 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 \ - doxygen \ - libboost1.55-dev \ - libboost-filesystem1.55-dev \ - libboost-program-options1.55-dev \ - libboost-python1.55-dev \ - libboost-regex1.55-dev \ - libboost-signals1.55-dev \ - libboost-system1.55-dev \ - libboost-thread1.55-dev \ - libcoin80 \ - libcoin80-dev \ - liboce-foundation-dev \ - liboce-modeling-dev \ - liboce-ocaf-dev \ - liboce-ocaf-lite-dev \ - liboce-visualization-dev \ - libpyside-dev \ - libqtcore4 \ - libshiboken-dev \ - libxerces-c-dev \ - libxmu-dev \ - libxmu-headers \ - libxmu6 \ - libxmuu-dev \ - libxmuu1 \ - netgen \ - netgen-headers \ - oce-draw \ - pyside-tools \ python-dev \ python-pyside \ python-matplotlib \ python3-dev \ python3-pyside \ python3-matplotlib \ - qt4-dev-tools \ + 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 \ + swig \ qt4-qmake \ libqt4-opengl-dev \ - shiboken \ - swig \ - libvtk6-dev \ - libmed-dev \ - libmedc-dev \ - asciidoc - - # Make sure dpkg is upgraded for Ubuntu 14.04 (required for eigen3) - sudo apt-get install -y dpkg - - # Use latest Eigen3 package - curl -L http://security.ubuntu.com/ubuntu/pool/universe/e/eigen3/libeigen3-dev_3.3.4-4_all.deb -o libeigen3.deb \ - && sudo dpkg -i libeigen3.deb - - # Install ccache to reduce successive build times (use newer version to minimize issues) - # XXX: ccache <=3.4.3 always builds manuals, requiring asciidoc/xsltproc - # XXX: 3.4.4 might have --disable-man (at least its present in their git) - sudo apt install -y xsltproc - curl -L "https://codeload.github.com/ccache/ccache/tar.gz/v3.4.3" | tar xvz && cd ccache-* - ./autogen.sh && ./configure CC=gcc && sudo make install - cd ${TRAVIS_BUILD_DIR} + 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 \ + netgen \ + netgen-headers \ + libmetis-dev \ + libspnav-dev export DISPLAY=:99.0 sh -e /etc/init.d/xvfb start @@ -189,8 +175,7 @@ before_install: then export CMAKE_ARGS="${CMAKE_OPTS} -DPYTHON_EXECUTABLE=/usr/bin/python" else - export CMAKE_ARGS="${CMAKE_OPTS} -DPYTHON_EXECUTABLE=/usr/bin/python3.4 -DPYTHON_BASENAME=.cpython-34m \ - -DPYTHON_SUFFIX=.cpython-34m" + export CMAKE_ARGS="${CMAKE_OPTS} -DPYTHON_EXECUTABLE=/usr/bin/python3" fi export INSTALLED_APP_PATH="/usr/local/bin/FreeCAD" ;; @@ -287,7 +272,10 @@ script: 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 - sudo make -j2 install + # Stop compiling (GCC) after 2 hrs 15 min (2 hrs 30 min limit). + # Preserves created ccache for the next build job. + if [ "${TRAVIS_OS_NAME}" == "linux" ]; then sudo timeout -k 140m 135m make -j2 install || true; fi + if [ "${TRAVIS_OS_NAME}" == "osx" ]; then sudo make -j2 install; fi ${INSTALLED_APP_PATH} --console --run-test 0 ${INSTALLED_APP_PATH} --log-file /tmp/FreeCAD_installed.log & sleep 10 && pkill FreeCAD