diff --git a/package/ci/pybind11-system-includes.patch b/package/ci/pybind11-system-includes.patch deleted file mode 100644 index 60d8954..0000000 --- a/package/ci/pybind11-system-includes.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/tools/pybind11Tools.cmake b/tools/pybind11Tools.cmake -index 52a70c2..1e9d033 100644 ---- a/tools/pybind11Tools.cmake -+++ b/tools/pybind11Tools.cmake -@@ -130,7 +130,7 @@ function(pybind11_add_module target_name) - - add_library(${target_name} ${lib_type} ${exclude_from_all} ${ARG_UNPARSED_ARGUMENTS}) - -- target_include_directories(${target_name} -+ target_include_directories(${target_name} SYSTEM - PRIVATE ${PYBIND11_INCLUDE_DIR} # from project CMakeLists.txt - PRIVATE ${pybind11_INCLUDE_DIR} # from pybind11Config - PRIVATE ${PYTHON_INCLUDE_DIRS}) diff --git a/package/ci/setup-pybind11.sh b/package/ci/setup-pybind11.sh index da2327a..553d896 100755 --- a/package/ci/setup-pybind11.sh +++ b/package/ci/setup-pybind11.sh @@ -1,17 +1,8 @@ set -e -wget --no-clobber https://github.com/pybind/pybind11/archive/v2.2.4.tar.gz && tar -xzf v2.2.4.tar.gz +wget --no-clobber https://github.com/pybind/pybind11/archive/v2.3.0.tar.gz && tar -xzf v2.3.0.tar.gz -cd pybind11-2.2.4 - -# Patch the CMake macro to add include paths as SYSTEM because otherwise GCC -# 4.8 gets very loud. This is already done in -# https://github.com/pybind/pybind11/pull/1416 but it's opt-in and not part of -# any release yet. For Git releases this is handled inside -# src/python/CMakeLists.txt (detecting version and applying SYSTEM), but I want -# to ensure compatibility with 2.2.4 *and* have useful CI output, so I am -# patching it here as well. -patch -p1 < $TRAVIS_BUILD_DIR/package/ci/pybind11-system-includes.patch +cd pybind11-2.3.0 mkdir -p build && cd build cmake .. \ diff --git a/package/ci/travis.yml b/package/ci/travis.yml index db1941e..37e1f55 100644 --- a/package/ci/travis.yml +++ b/package/ci/travis.yml @@ -100,9 +100,15 @@ install: # Code coverage of python bindings - if [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ]; then pip3 install coverage codecov; fi -# pybind11 (cached) +# pybind11 (cached). On macOS the version 2.3.0 needs a brew update, the stale +# Travis image has just 2.2.4. - if [ "$TRAVIS_OS_NAME" == "linux" ] && [ ! -e "$HOME/pybind11/bin" ]; then $TRAVIS_BUILD_DIR/package/ci/setup-pybind11.sh; fi -- if [ "$TRAVIS_OS_NAME" == "osx" ]; then HOMEBREW_NO_AUTO_UPDATE=1 brew install pybind11; fi +- if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install pybind11; fi + +# numpy on macOS -- probably because we updated Homebrew to install new pybind +# (and thus python as well, apparently), the preinstalled numpy is no longer +# visible. +- if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew upgrade numpy; fi # SwiftShader on Linux (cached). Taken from Chromium snapshot 587878 # (swiftshader-bin Arch package).