packages feed

dataframe-arrow-1.0.2.0: dataframe-arrow.cabal

cabal-version:      3.0
name:               dataframe-arrow
version:            1.0.2.0
synopsis: Arrow C Data Interface foreign library for the dataframe Python bindings.

description: Native-shared library exposing the dataframe lazy executor to
             Python via the Arrow C Data Interface.  Defaults to the
             SIMD CSV reader from @dataframe-fastcsv@.
             Can be used as a standalone FFI library for other languages as well.

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: Simple

extra-source-files: cbits/arrow_abi.h
                    cbits/dataframe_arrow.h
                    cbits/rts_init.c

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

-- Mirror the meta-package's opt-out flags so the foreign library disappears
-- in lockstep with `dataframe:arrow-bridge`, which sets `buildable: False`
-- under the same conditions. Pass the matching flag to dataframe-arrow
-- (e.g. `--constraint="dataframe-arrow +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-arrow when the meta package's
                 CSV backend is disabled (arrow-bridge becomes unbuildable).

flag no-parquet
    default:     False
    manual:      True
    description: Skip building dataframe-arrow when the meta package's
                 Parquet backend is disabled (arrow-bridge becomes
                 unbuildable).

foreign-library dataframe-arrow
    import: warnings
    if flag(no-csv) || flag(no-parquet)
        buildable: False
    type:             native-shared
    hs-source-dirs:   ffi-export
    other-modules:    DataFrame.FFI
    build-depends:
        base                  >= 4   && < 5,
        dataframe-core ^>= 2.4,
        dataframe-learn ^>= 2.4,
        dataframe:arrow-bridge >= 1   && < 4,
        dataframe-fastcsv     ^>= 1.4.0.1,
        text                  >= 2.1 && < 3,
        aeson                 >= 0.11 && < 3,
        bytestring            >= 0.11 && < 0.14,
        vector                >= 0.13 && < 0.15
    c-sources:        cbits/rts_init.c
    include-dirs:     cbits
    includes:         arrow_abi.h dataframe_arrow.h
    install-includes: arrow_abi.h dataframe_arrow.h
    ghc-options:      -threaded
    default-language: Haskell2010