diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 00c5aa2..3802d94 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,8 +25,8 @@ on: branches: [main] paths: - ".github/workflows/ci.yml" - - "deps/conanfile.py" - - "deps/generate_makevars.py" + - "tools/conanfile.py" + - "tools/generate_makevars.py" - "R/**" - "inst/extdata/**" - "man/**" @@ -43,8 +43,8 @@ on: pull_request: paths: - ".github/workflows/ci.yml" - - "deps/conanfile.py" - - "deps/generate_makevars.py" + - "tools/conanfile.py" + - "tools/generate_makevars.py" - "R/**" - "inst/extdata/**" - "man/**" @@ -139,7 +139,7 @@ jobs: uses: actions/cache@v4 id: restore-conan-cache with: - key: conan-cache-ci-${{ matrix.os }}-${{ hashFiles( 'configure', 'deps/conanfile.py', 'deps/generate_makevars.py') }} + key: conan-cache-ci-${{ matrix.os }}-${{ hashFiles( 'configure', 'tools/conanfile.py', 'tools/generate_makevars.py') }} path: ${{ env.HICTKR_CONAN_HOME }}/p - name: Build and test package diff --git a/.github/workflows/pkgdown.yml b/.github/workflows/pkgdown.yml index 2995ea9..49c4410 100644 --- a/.github/workflows/pkgdown.yml +++ b/.github/workflows/pkgdown.yml @@ -25,8 +25,8 @@ on: branches: [main] paths: - ".github/workflows/pkgdown.yml" - - "deps/conanfile.py" - - "deps/generate_makevars.py" + - "tools/conanfile.py" + - "tools/generate_makevars.py" - "R/**" - "inst/extdata/**" - "man/**" @@ -44,8 +44,8 @@ on: branches: [main] paths: - ".github/workflows/pkgdown.yml" - - "deps/conanfile.py" - - "deps/generate_makevars.py" + - "tools/conanfile.py" + - "tools/generate_makevars.py" - "R/**" - "inst/extdata/**" - "man/**" @@ -99,7 +99,7 @@ jobs: uses: actions/cache@v4 id: restore-conan-cache with: - key: conan-cache-pkgdown-${{ hashFiles( 'configure', 'deps/conanfile.py', 'deps/generate_makevars.py') }} + key: conan-cache-pkgdown-${{ hashFiles( 'configure', 'tools/conanfile.py', 'tools/generate_makevars.py') }} path: ${{ env.HICTKR_CONAN_HOME }}/p - name: Add requirements diff --git a/.github/workflows/r-build.yml b/.github/workflows/r-build.yml index 1a9d57f..44838aa 100644 --- a/.github/workflows/r-build.yml +++ b/.github/workflows/r-build.yml @@ -25,8 +25,8 @@ on: branches: [main] paths: - ".github/workflows/r-build.yml" - - "deps/conanfile.py" - - "deps/generate_makevars.py" + - "tools/conanfile.py" + - "tools/generate_makevars.py" - "R/**" - "inst/extdata/**" - "man/**" @@ -43,8 +43,8 @@ on: pull_request: paths: - ".github/workflows/r-build.yml" - - "deps/conanfile.py" - - "deps/generate_makevars.py" + - "tools/conanfile.py" + - "tools/generate_makevars.py" - "R/**" - "inst/extdata/**" - "man/**" @@ -109,7 +109,7 @@ jobs: uses: actions/cache@v4 id: restore-conan-cache with: - key: conan-cache-r-build-${{ hashFiles( 'configure', 'deps/conanfile.py', 'deps/generate_makevars.py') }} + key: conan-cache-r-build-${{ hashFiles( 'configure', 'tools/conanfile.py', 'tools/generate_makevars.py') }} path: ${{ env.HICTKR_CONAN_HOME }}/p - name: Build package diff --git a/tools/conanfile.py b/tools/conanfile.py index 407e570..648f38f 100644 --- a/tools/conanfile.py +++ b/tools/conanfile.py @@ -37,7 +37,7 @@ class HictkConan(ConanFile): name = "hictk" - version = "2.1.4" + version = "2.2.0" description = "Blazing fast toolkit to work with .hic and .cool files" license = "MIT" url = "https://github.com/paulsengroup/hictkR" @@ -52,38 +52,38 @@ def __init__(self, *args, **kwargs): "sources": { HictkConan.version: { "url": f"https://github.com/paulsengroup/hictk/archive/refs/tags/v{HictkConan.version}.tar.gz", - "sha256": "3a0030425176dacc25c20afc6fedb5dfbbc3c1a67f773be11ac77d7fa6b7efde", + "sha256": "989b6e84b967309d9822ee3274abf98daba66d3d6e6ae8c9abffcede07b24761", }, }, - "patches": { - "2.1.4": [ - { - "patch_file": "patches/hictk_v2.1.4_eigen_include.patch", - "patch_type": "portability", - "patch_description": "Support including Eigen headers located under eigen3/", - } - ] - }, } def layout(self): cmake_layout(self, src_folder="src") + def build_requirements(self): + self.requires("cmake/[>=3.25]") + def requirements(self): - # Arrow 21.0.0 can't find certain kernels (e.g., sort_indices) - self.requires("arrow/20.0.0#6e04404a336dd16f08062f6923e6f8f1") + # re2 + self.requires("abseil/20250814.0#4e0fdd34a888b97aca482e648fc27a3b", force=True) + # arrow + self.requires("re2/20251105#2eec620fc641f812a5837c642ecb7d66", force=True) + # hdf5 + self.requires("zlib/1.3.1#b8bc2603263cf7eccbd6e17e66b0ed76", force=True) + + self.requires("arrow/22.0.0#e46b173ba20adc478f7926495aeed142") self.requires("bshoshany-thread-pool/5.0.0#d94da300363f0c35b8f41b2c5490c94d") self.requires("concurrentqueue/1.0.4#1e48e1c712bcfd892087c9c622a51502") - self.requires("eigen/3.4.90-unstable+git.2025.08.15#b407f03f085cdb246f6bcbadd84fe9db") - self.requires("fast_float/8.0.2#846ad0ebab16bc265c511095c3b490e9") - self.requires("fmt/11.2.0#579bb2cdf4a7607621beea4eb4651e0f", force=True) - self.requires("hdf5/1.14.6#6f1acd01d23d00735fe97300f4d5980c", force=True) - self.requires("highfive/2.10.0#75c849a0d940b2d4dae6055915132690") - self.requires("libdeflate/1.23#4994bea7cf7e93789da161fac8e26a53") + self.requires("eigen/5.0.0#f7561f543f4aafd6d2dc1f6d677e3075", force=True) + self.requires("fast_float/8.1.0#bbf67486bec084d167da0f3e13eee534") + self.requires("fmt/12.1.0#50abab23274d56bb8f42c94b3b9a40c7", force=True) + self.requires("hdf5/1.14.6#0b780319690d537e6cb0683244919955", force=True) + self.requires("highfive/3.1.1#d0c724526ebc8ce396ffa1bf7f3c7b64") + self.requires("libdeflate/1.25#49fcd3fe6c130c2ec5a01cabb0481ded") self.requires("parallel-hashmap/2.0.0#82acae64ffe2693fff5fb3f9df8e1746") self.requires("readerwriterqueue/1.0.6#aaa5ff6fac60c2aee591e9e51b063b83") self.requires("span-lite/0.11.0#519fd49fff711674cfed8cd17d4ed422") - self.requires("spdlog/1.15.3#3ca0e9e6b83af4d0151e26541d140c86") + self.requires("spdlog/1.16.0#942c2c39562ae25ba575d9c8e2bdf3b6") self.requires("zstd/1.5.7#fde461c0d847a22f16d3066774f61b11", force=True) def package_id(self): @@ -95,9 +95,6 @@ def export_sources(self): def validate(self): check_min_cppstd(self, 17) - def build_requirements(self): - self.tool_requires("cmake/[>=3.25]") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -145,6 +142,9 @@ def package_info(self): self.cpp_info.defines.append("HICTK_WITH_ARROW") self.cpp_info.defines.append("HICTK_WITH_EIGEN") + # TODO These should've been defined by the Arrow Conan recipe + self.cpp_info.defines.append("ARROW_STATIC") + self.cpp_info.defines.append("ARROW_COMPUTE_STATIC") def configure(self): self.options["arrow"].compute = True @@ -154,6 +154,7 @@ def configure(self): self.options["arrow"].with_re2 = True self.options["arrow"].with_thrift = False self.options["arrow"].with_zlib = False + self.options["eigen"].MPL2_only = True self.options["fmt"].header_only = True self.options["hdf5"].enable_cxx = False self.options["hdf5"].hl = False diff --git a/tools/generate_makevars.py b/tools/generate_makevars.py index 5595233..ca90992 100755 --- a/tools/generate_makevars.py +++ b/tools/generate_makevars.py @@ -389,6 +389,8 @@ def run_conan_install( "--settings=build_type=Release", "--settings=compiler.cppstd=17", "--conf=tools.cmake.cmaketoolchain:generator=Ninja", + "--options", + "*/*:shared=False", ] if platform.system() != "Darwin": diff --git a/tools/patches/hictk_v2.1.4_eigen_include.patch b/tools/patches/hictk_v2.1.4_eigen_include.patch deleted file mode 100644 index e93b797..0000000 --- a/tools/patches/hictk_v2.1.4_eigen_include.patch +++ /dev/null @@ -1,87 +0,0 @@ -# Copyright (C) 2025 Roberto Rossini -# -# SPDX-License-Identifier: GPL-2.0-or-later -# -# This library is free software: you can redistribute it and/or -# modify it under the terms of the GNU Public License as published -# by the Free Software Foundation; either version 3 of the License, -# or (at your option) any later version. -# -# This library is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# Library General Public License for more details. -# -# You should have received a copy of the GNU Public License along -# with this library. If not, see -# . - - -diff --git a/src/libhictk/transformers/include/hictk/transformers/impl/to_dense_matrix_impl.hpp b/src/libhictk/transformers/include/hictk/transformers/impl/to_dense_matrix_impl.hpp -index 042d8eb1..1445fab6 100644 ---- a/src/libhictk/transformers/include/hictk/transformers/impl/to_dense_matrix_impl.hpp -+++ b/src/libhictk/transformers/include/hictk/transformers/impl/to_dense_matrix_impl.hpp -@@ -4,7 +4,12 @@ - - #pragma once - -+#if __has_include() -+#include -+#else - #include -+#endif -+ - #include - #include - #include -diff --git a/src/libhictk/transformers/include/hictk/transformers/impl/to_sparse_matrix_impl.hpp b/src/libhictk/transformers/include/hictk/transformers/impl/to_sparse_matrix_impl.hpp -index 98d961c7..032ab4dd 100644 ---- a/src/libhictk/transformers/include/hictk/transformers/impl/to_sparse_matrix_impl.hpp -+++ b/src/libhictk/transformers/include/hictk/transformers/impl/to_sparse_matrix_impl.hpp -@@ -6,7 +6,12 @@ - - #include - -+#if __has_include() -+#include -+#else - #include -+#endif -+ - #include - #include - #include -diff --git a/src/libhictk/transformers/include/hictk/transformers/to_dense_matrix.hpp b/src/libhictk/transformers/include/hictk/transformers/to_dense_matrix.hpp -index 498ecfea..7879be49 100644 ---- a/src/libhictk/transformers/include/hictk/transformers/to_dense_matrix.hpp -+++ b/src/libhictk/transformers/include/hictk/transformers/to_dense_matrix.hpp -@@ -6,7 +6,12 @@ - - #ifdef HICTK_WITH_EIGEN - -+#if __has_include() -+#include -+#else - #include -+#endif -+ - #include - #include - #include -diff --git a/src/libhictk/transformers/include/hictk/transformers/to_sparse_matrix.hpp b/src/libhictk/transformers/include/hictk/transformers/to_sparse_matrix.hpp -index afe0b849..dcd4483a 100644 ---- a/src/libhictk/transformers/include/hictk/transformers/to_sparse_matrix.hpp -+++ b/src/libhictk/transformers/include/hictk/transformers/to_sparse_matrix.hpp -@@ -6,7 +6,12 @@ - - #ifdef HICTK_WITH_EIGEN - -+#if __has_include() -+#include -+#else - #include -+#endif -+ - #include - #include - #include