diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ed57c1b3ce..06034e6b8f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -113,12 +113,12 @@ jobs: url: "https://github.com/ax3l/openPMD-api/commit/43c4bf4327616e9cf7e7992d91d9b8ccd4ee3a83.patch" target: src/.patch/ - # 0.15.0.post1 bump + # 0.15.0.post2 bump - name: Download Patch 4/4 uses: suisei-cn/actions-download-file@v1 id: setupversion with: - url: "https://gist.githubusercontent.com/ax3l/5e83edefe4b05cf6aa2a971649285fe0/raw/b510a363aac6b68651ec8081efbb40cb3bda1d4b/0001-Bump-setup.py.patch" + url: "https://gist.githubusercontent.com/ax3l/5e83edefe4b05cf6aa2a971649285fe0/raw/023cbd69e06715e5191ece741bb1de56560a9f96/0001-Bump-setup.py.patch" target: src/.patch/ - name: Apply Patches @@ -143,8 +143,8 @@ jobs: CIBW_BEFORE_BUILD_WINDOWS: 'cmd /E:ON /V:ON /C .github\library_builders.bat' # for the openPMD-api build, CMake shall search for # static dependencies of HDF5 and ADIOS1 (see setup.py) - CIBW_ENVIRONMENT: HDF5_USE_STATIC_LIBRARIES='ON' ADIOS_USE_STATIC_LIBS='ON' openPMD_CMAKE_openPMD_USE_HDF5='ON' openPMD_CMAKE_openPMD_USE_ADIOS2='ON' - CIBW_ENVIRONMENT_WINDOWS: HDF5_USE_STATIC_LIBRARIES='ON' openPMD_CMAKE_openPMD_USE_HDF5='ON' openPMD_CMAKE_openPMD_USE_ADIOS2='ON' CMAKE_PREFIX_PATH='C:/Program Files (x86)/ADIOS2;C:/Program Files (x86)/blosc;C:/Program Files (x86)/HDF5;C:/Program Files (x86)/ZFP;C:/Program Files (x86)/zlib' + CIBW_ENVIRONMENT: HDF5_USE_STATIC_LIBRARIES='ON' ZLIB_USE_STATIC_LIBS='ON' ADIOS_USE_STATIC_LIBS='ON' openPMD_CMAKE_openPMD_USE_HDF5='ON' openPMD_CMAKE_openPMD_USE_ADIOS2='ON' + CIBW_ENVIRONMENT_WINDOWS: HDF5_USE_STATIC_LIBRARIES='ON' ZLIB_USE_STATIC_LIBS='ON' openPMD_CMAKE_openPMD_USE_HDF5='ON' openPMD_CMAKE_openPMD_USE_ADIOS2='ON' CMAKE_PREFIX_PATH='C:/Program Files (x86)/ADIOS2;C:/Program Files (x86)/blosc;C:/Program Files (x86)/HDF5;C:/Program Files (x86)/ZFP;C:/Program Files (x86)/zlib' # C++17 support in macOS 10.13+ (partial) and 10.14+ (std::visit) and 10.15+ (std::filesystem::path) # https://cibuildwheel.readthedocs.io/en/stable/cpp_standards/#macos-and-deployment-target-versions # arm64 Python interpreters are built with 11.0 diff --git a/.travis.yml b/.travis.yml index 6fe7b89564..31c80dbb97 100644 --- a/.travis.yml +++ b/.travis.yml @@ -145,7 +145,7 @@ before_script: - curl -sOL https://github.com/ax3l/openPMD-api/commit/b622cc5ea770f866c1e373185a9e389c04bdb54c.patch - curl -sOL https://github.com/ax3l/openPMD-api/commit/a1aac530dbc8261656cf6a07900374bc6ac6fcab.patch - curl -sOL https://github.com/ax3l/openPMD-api/commit/43c4bf4327616e9cf7e7992d91d9b8ccd4ee3a83.patch - - curl -sOL https://gist.githubusercontent.com/ax3l/5e83edefe4b05cf6aa2a971649285fe0/raw/b510a363aac6b68651ec8081efbb40cb3bda1d4b/0001-Bump-setup.py.patch + - curl -sOL https://gist.githubusercontent.com/ax3l/5e83edefe4b05cf6aa2a971649285fe0/raw/023cbd69e06715e5191ece741bb1de56560a9f96/0001-Bump-setup.py.patch - cd .. - python3 -m patch .patch/b622cc5ea770f866c1e373185a9e389c04bdb54c.patch - python3 -m patch .patch/a1aac530dbc8261656cf6a07900374bc6ac6fcab.patch diff --git a/library_builders.bat b/library_builders.bat index 02f08702cb..383e2d13d1 100644 --- a/library_builders.bat +++ b/library_builders.bat @@ -51,6 +51,9 @@ exit /b 0 cmake --build build-adios2 --target install --config Release if errorlevel 1 exit 1 + rmdir /s /q build-adios2 + if errorlevel 1 exit 1 + break > adios2-stamp if errorlevel 1 exit 1 exit /b 0 @@ -68,6 +71,7 @@ exit /b 0 -DBUILD_SHARED=OFF ^ -DBUILD_STATIC=ON ^ -DBUILD_TESTS=OFF ^ + -DZLIB_USE_STATIC_LIBS=ON ^ -DDEACTIVATE_SNAPPY=ON if errorlevel 1 exit 1 @@ -77,6 +81,9 @@ exit /b 0 cmake --build build-blosc --target install --config Release if errorlevel 1 exit 1 + rmdir /s /q build-blosc + if errorlevel 1 exit 1 + break > blosc-stamp if errorlevel 1 exit 1 exit /b 0 @@ -93,6 +100,7 @@ exit /b 0 -DCMAKE_VERBOSE_MAKEFILE=ON ^ -DBUILD_SHARED_LIBS=OFF ^ -DBUILD_TESTING=OFF ^ + -DTEST_SHELL_SCRIPTS=OFF ^ -DHDF5_BUILD_CPP_LIB=OFF ^ -DHDF5_BUILD_EXAMPLES=OFF ^ -DHDF5_BUILD_FORTRAN=OFF ^ @@ -101,6 +109,7 @@ exit /b 0 -DHDF5_ENABLE_PARALLEL=OFF ^ -DHDF5_ENABLE_SZIP_SUPPORT=OFF ^ -DHDF5_ENABLE_Z_LIB_SUPPORT=ON ^ + -DZLIB_USE_STATIC_LIBS=ON ^ -DCMAKE_INSTALL_PREFIX=%BUILD_PREFIX%/HDF5 if errorlevel 1 exit 1 @@ -110,6 +119,9 @@ exit /b 0 cmake --build build-hdf5 --target install --config Release if errorlevel 1 exit 1 + rmdir /s /q build-hdf5 + if errorlevel 1 exit 1 + break > hdf5-stamp if errorlevel 1 exit 1 exit /b 0 @@ -137,6 +149,9 @@ exit /b 0 cmake --build build-zfp --target install --config Release if errorlevel 1 exit 1 + rmdir /s /q build-zfp + if errorlevel 1 exit 1 + break > zfp-stamp if errorlevel 1 exit 1 exit /b 0 @@ -144,12 +159,12 @@ exit /b 0 :build_zlib if exist zlib-stamp exit /b 0 - curl -sLo zlib-1.2.12.zip ^ - https://github.com/madler/zlib/archive/v1.2.12.zip - powershell Expand-Archive zlib-1.2.12.zip -DestinationPath dep-zlib + curl -sLo zlib-1.2.13.zip ^ + https://github.com/madler/zlib/archive/v1.2.13.zip + powershell Expand-Archive zlib-1.2.13.zip -DestinationPath dep-zlib - cmake -S dep-zlib/zlib-1.2.12 -B build-zlib ^ - -DBUILD_SHARED_LIBS=OFF ^ + cmake -S dep-zlib/zlib-1.2.13 -B build-zlib ^ + -DBUILD_SHARED_LIBS=ON ^ -DCMAKE_BUILD_TYPE=Release if errorlevel 1 exit 1 :: Manually-specified variables were not used by the project: @@ -161,6 +176,14 @@ exit /b 0 cmake --build build-zlib --target install --config Release if errorlevel 1 exit 1 + set "zlib_dll=%BUILD_PREFIX:~1,-1%/zlib/bin/zlib1.dll" + set "zlib_dll=%zlib_dll:/=\%" + del "%zlib_dll%" + if errorlevel 1 exit 1 + + rmdir /s /q build-zlib + if errorlevel 1 exit 1 + break > zlib-stamp if errorlevel 1 exit 1 exit /b 0 diff --git a/library_builders.sh b/library_builders.sh index 9377d57f03..6f7dba2ed1 100755 --- a/library_builders.sh +++ b/library_builders.sh @@ -118,8 +118,8 @@ function build_adios2 { ADIOS2_USE_SST=OFF fi - mkdir build-ADIOS2 - cd build-ADIOS2 + mkdir build-adios2 + cd build-adios2 PY_BIN=$(which python3) CMAKE_BIN="$(${PY_BIN} -m pip show cmake 2>/dev/null | grep Location | cut -d' ' -f2)/cmake/data/bin/" if [ "$(uname -s)" = "Linux" ] @@ -153,6 +153,8 @@ function build_adios2 { make install cd - + rm -rf build-adios2 + touch adios2-stamp } @@ -178,8 +180,8 @@ function build_blosc { DEACTIVATE_SSE2=ON fi - mkdir build-c-blosc - cd build-c-blosc + mkdir build-blosc + cd build-blosc PY_BIN=$(which python3) CMAKE_BIN="$(${PY_BIN} -m pip show cmake 2>/dev/null | grep Location | cut -d' ' -f2)/cmake/data/bin/" PATH=${CMAKE_BIN}:${PATH} cmake \ @@ -190,11 +192,14 @@ function build_blosc { -DBUILD_BENCHMARKS=OFF \ -DCMAKE_VERBOSE_MAKEFILE=ON \ -DCMAKE_INSTALL_PREFIX=${BUILD_PREFIX} \ + -DZLIB_USE_STATIC_LIBS=ON \ ../c-blosc-* make -j${CPU_COUNT} make install cd - + rm -rf build-blosc + touch blosc-stamp } @@ -221,13 +226,15 @@ function build_zfp { make install cd - + rm -rf build-zfp + touch zfp-stamp } function build_zlib { if [ -e zlib-stamp ]; then return; fi - ZLIB_VERSION="1.2.12" + ZLIB_VERSION="1.2.13" curl -sLO https://zlib.net/fossils/zlib-$ZLIB_VERSION.tar.gz file zlib*.tar.gz @@ -247,6 +254,8 @@ function build_zlib { PATH=${CMAKE_BIN}:${PATH} cmake --build build-zlib --target install rm -rf ${BUILD_PREFIX}/lib/libz.*dylib ${BUILD_PREFIX}/lib/libz.*so + rm -rf build-zlib + touch zlib-stamp }