packages feed

dataframe-fusion-0.2.0.0: dataframe-fusion.cabal

cabal-version:      3.0
name:               dataframe-fusion
version:            0.2.0.0
synopsis: Apache DataFusion backend for the dataframe typed API.

description: A typed, plan-based wrapper around Apache DataFusion. Mirrors
             the DataFrame.Typed.Lazy surface but lowers each operation to
             a DataFusion logical plan via a Rust bridge crate. Results are
             returned via the Arrow C Data Interface and reconstructed as
             ordinary TypedDataFrames in Haskell.

bug-reports: https://github.com/mchav/dataframe/issues
license:            MIT
author:             Michael Chavinda
maintainer:         mschavinda@gmail.com

copyright: (c) 2024-2026 Michael Chavinda
category: Data
build-type: Custom

extra-source-files: cbits/dfusion_bridge.h
                    rust/dfusion-bridge/Cargo.toml
                    rust/dfusion-bridge/src/lib.rs

-- The license is the same as the parent dataframe package.

custom-setup
    setup-depends: base       >= 4   && < 5,
                   Cabal      >= 3.0 && < 4,
                   directory  >= 1.3 && < 2,
                   filepath   >= 1.4 && < 2,
                   process    >= 1.6 && < 2

common warnings
    ghc-options:
        -Wincomplete-patterns
        -Wincomplete-uni-patterns
        -Wunused-imports
        -Wunused-local-binds
        -Wunused-packages

-- Mirror the meta-package's opt-out flags. dataframe-fusion depends on
-- `dataframe-arrow-bridge`, which always needs the CSV and Parquet readers,
-- so the library has to disappear in lockstep when either is disabled.
-- Pass the matching flag (e.g. `--constraint="dataframe-fusion +no-csv"`)
-- when building the meta package with `--flags="no-csv"` against the full
-- cabal.project.
flag no-csv
    default:     False
    manual:      True
    description: Skip building dataframe-fusion when the meta package's
                 CSV backend is disabled.

flag no-parquet
    default:     False
    manual:      True
    description: Skip building dataframe-fusion when the meta package's
                 Parquet backend is disabled.

library
    import: warnings
    if flag(no-csv) || flag(no-parquet)
        buildable: False
    exposed-modules:  DataFrame.Fusion.FFI
                      DataFrame.Fusion.Plan
                      DataFrame.Fusion.Typed
    build-depends:    base       >= 4    && < 5,
                      bytestring >= 0.11 && < 0.14,
                      aeson      >= 0.11 && < 3,
                      dataframe-core ^>= 2.5,
                      dataframe-lazy ^>= 2.4.1,
                      dataframe-operations ^>= 2.5,
                      dataframe-arrow-bridge ^>= 1.0,
                      text       >= 2.1  && < 3
    hs-source-dirs:   src
    include-dirs:     cbits
    includes:         dfusion_bridge.h
    install-includes: dfusion_bridge.h
    -- iconv lives in glibc on Linux; only macOS exposes it as a separate lib.
    extra-libraries:  dfusion_bridge bz2 lzma z
    if os(darwin)
        extra-libraries: iconv
        ld-options: -framework CoreFoundation -framework Security -framework SystemConfiguration
    default-language: Haskell2010

test-suite tests
    import: warnings
    type: exitcode-stdio-1.0
    main-is: Main.hs
    if flag(no-csv) || flag(no-parquet)
        buildable: False
    build-depends:    base       >= 4    && < 5,
                      dataframe-core ^>= 2.5,
                      dataframe-fusion,
                      dataframe-operations ^>= 2.5,
                      directory  >= 1.3  && < 2,
                      filepath   >= 1.4  && < 2,
                      HUnit      >= 1.6 && < 1.8,
                      text       >= 2.1  && < 3
    hs-source-dirs:   tests
    -- iconv lives in glibc on Linux; only macOS exposes it as a separate lib.
    extra-libraries:  dfusion_bridge bz2 lzma z
    if os(darwin)
        extra-libraries: iconv
        ld-options: -framework CoreFoundation -framework Security -framework SystemConfiguration
    default-language: Haskell2010