From 923ffa03b843bd1c3cd491e564936abaa7f63653 Mon Sep 17 00:00:00 2001 From: Bryan Weber Date: Sun, 1 Dec 2024 11:38:55 -0500 Subject: [PATCH] Update build options and dependencies for packages in CMake (#2) * Bump Zlib version and don't build unnecessary SUNDIALS libraries * Remove extra steps to build Cantera * Replace License file This code is now fully independent from the former upstream at h5py * Update SUNDIALS and fmtlib versions * Typos in the README --- CMakeLists.txt | 15 ++++++++++----- Dockerfile | 15 --------------- LICENSE | 29 ----------------------------- License.txt | 37 +++++++++++++++++++++++++++++++++++++ README.md | 4 ++-- 5 files changed, 49 insertions(+), 51 deletions(-) delete mode 100644 LICENSE create mode 100644 License.txt diff --git a/CMakeLists.txt b/CMakeLists.txt index 1e39402..03e791e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,7 +20,7 @@ ExternalProject_Add( ) set(LIBHDF5_VERSION 1.14.5) -set(ZLIB_VERSION 1.3) +set(ZLIB_VERSION 1.3.1) set(LIBAEC_VERSION 1.1.3) ExternalProject_Add( libhdf5 @@ -77,11 +77,11 @@ ExternalProject_Add( DOWNLOAD_DIR ${DOWNLOAD_DIR} ) -set(SUNDIALS_VERSION 7.0.0) +set(SUNDIALS_VERSION 7.1.1) ExternalProject_Add( sundials URL https://github.com/LLNL/sundials/releases/download/v${SUNDIALS_VERSION}/sundials-${SUNDIALS_VERSION}.tar.gz - URL_HASH SHA256=d762a7950ef4097fbe9d289f67a8fb717a0b9f90f87ed82170eb5c36c0a07989 + URL_HASH SHA256=ea7d6edfb52448ddfdc1ec48f89a721fe6c0a259c10f8ef56f60fcded87a94bb CMAKE_GENERATOR Ninja CMAKE_CACHE_ARGS -DCMAKE_BUILD_TYPE:STRING=Release @@ -89,16 +89,21 @@ ExternalProject_Add( -DBUILD_SHARED_LIBS:BOOL=OFF -DEXAMPLES_ENABLE_C:BOOL=OFF -DEXAMPLES_INSTALL:BOOL=OFF + -DBUILD_ARKODE:BOOL=OFF + -DBUILD_CVODE:BOOL=OFF + -DBUILD_IDA:BOOL=OFF + -DBUILD_KINSOL:BOOL=OFF + -DBUILD_CPODES:BOOL=OFF -DENABLE_LAPACK:BOOL=ON -DBLA_VENDOR:STRING=OpenBLAS DOWNLOAD_DIR ${DOWNLOAD_DIR} ) -set(FMT_VERSION 10.2.1) +set(FMT_VERSION 11.0.2) ExternalProject_Add( fmt URL https://github.com/fmtlib/fmt/releases/download/${FMT_VERSION}/fmt-${FMT_VERSION}.zip - URL_HASH SHA256=312151a2d13c8327f5c9c586ac6cf7cddc1658e8f53edae0ec56509c8fa516c9 + URL_HASH SHA256=40fc58bebcf38c759e11a7bd8fdc163507d2423ef5058bba7f26280c5b9c5465 CMAKE_GENERATOR Ninja CMAKE_CACHE_ARGS -DCMAKE_BUILD_TYPE:STRING=Release diff --git a/Dockerfile b/Dockerfile index d936b61..d627c5a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -23,18 +23,3 @@ RUN --mount=type=cache,target=/cache \ && ninja \ && popd \ && rm -rf build - -# FROM builder AS tester - -# RUN yum install -y python3.12-pip \ -# && python3.12 -m pip install --root-user-action=ignore build auditwheel - -# COPY cantera-3.1.0a4.tar.gz /project/ - -# RUN --mount=type=cache,target=/root/.cache \ -# pushd project \ -# && tar --strip-components=1 -zxf cantera-*.tar.gz \ -# && rm -f cantera-*.tar.gz \ -# && python3.12 -m build --wheel . \ -# && pushd dist \ -# && auditwheel repair -w . cantera*.whl diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 96d75e3..0000000 --- a/LICENSE +++ /dev/null @@ -1,29 +0,0 @@ -BSD 3-Clause License - -Copyright (c) 2021, Andrew Collette and contributors -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - -1. Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - -2. Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - -3. Neither the name of the copyright holder nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/License.txt b/License.txt new file mode 100644 index 0000000..016b821 --- /dev/null +++ b/License.txt @@ -0,0 +1,37 @@ +Copyright (c) 2001-2009, California Institute of Technology +All rights reserved. + +Copyright (c) 2009 Sandia Corporation. Under the terms of +Contract AC04-94AL85000 with Sandia Corporation, the U.S. Government +retains certain rights in this software. + +Copyright (c) 2011-2024, Cantera Developers. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + +- Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +- Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +- Neither the name of the California Institute of Technology, Sandia + Corporation nor the names of other contributors may be used to + endorse or promote products derived from this software without + specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/README.md b/README.md index f5d9328..207d712 100644 --- a/README.md +++ b/README.md @@ -2,5 +2,5 @@ Images are published on the GitHub container registry: -- [cantera-base-manylinux_2_28-x86_64](https://github.com/orgs/Cantera/packages/container/package/cantera-base-manylinux_2_28-x86_64). -- [cantera-base-manylinux_2_28-aarch64](https://github.com/orgs/Cantera/packages/container/package/cantera-base-manylinux_2_28-aarch64). +- [cantera-base-manylinux_2_28-x86_64](https://github.com/orgs/Cantera/packages/container/package/cantera-base-manylinux_2_28-x86_64) +- [cantera-base-manylinux_2_28-aarch64](https://github.com/orgs/Cantera/packages/container/package/cantera-base-manylinux_2_28-aarch64)