summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2022-06-16 15:13:53 +0200
committerRicardo Wurmus <rekado@elephly.net>2022-06-16 15:20:59 +0200
commita3613f11d5e034961e791f5a75e0fa55dda3683f (patch)
treed5b9f882ea0c2edb7cefcd6dbd79a79f3a992e38 /gnu
parentc8727617e51c335090daa48a63c61801c41a83ae (diff)
gnu: Add python-pyarrow-0.16.
* gnu/packages/databases.scm (python-pyarrow-0.16): New variable.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/databases.scm58
1 files changed, 58 insertions, 0 deletions
diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm
index 03ea55c6e13..92ab94f4530 100644
--- a/gnu/packages/databases.scm
+++ b/gnu/packages/databases.scm
@@ -4442,6 +4442,64 @@ implementation, along with tools for interoperability with pandas, NumPy, and
4442other traditional Python scientific computing packages.") 4442other traditional Python scientific computing packages.")
4443 (license license:asl2.0))) 4443 (license license:asl2.0)))
4444 4444
4445(define-public python-pyarrow-0.16
4446 (package
4447 (inherit apache-arrow-0.16)
4448 (name "python-pyarrow")
4449 (build-system python-build-system)
4450 (arguments
4451 '(#:tests? #f ; XXX There are no tests in the "python" directory
4452 #:phases
4453 (modify-phases %standard-phases
4454 (delete 'build) ; XXX the build is performed again during the install phase
4455 (add-after 'unpack 'enter-source-directory
4456 (lambda _ (chdir "python")))
4457 (add-after 'unpack 'make-git-checkout-writable
4458 (lambda _
4459 (for-each make-file-writable (find-files "."))))
4460 (add-before 'install 'patch-cmake-variables
4461 (lambda* (#:key inputs #:allow-other-keys)
4462 ;; Replace cmake locations with hardcoded guix links for the
4463 ;; underlying C++ library and headers. This is a pretty awful
4464 ;; hack.
4465 (substitute* "cmake_modules/FindParquet.cmake"
4466 (("# Licensed to the Apache Software Foundation" m)
4467 (string-append "set(PARQUET_INCLUDE_DIR \""
4468 (assoc-ref inputs "apache-arrow:include")
4469 "/share/include\")\n" m))
4470 (("find_package_handle_standard_args" m)
4471 (string-append "set(PARQUET_LIB_DIR \""
4472 (assoc-ref inputs "apache-arrow:lib")
4473 "/lib\")\n" m)))))
4474 (add-before 'install 'patch-parquet-library
4475 (lambda _
4476 (substitute* "CMakeLists.txt"
4477 (("parquet_shared") "parquet"))))
4478 (add-before 'install 'set-PYARROW_WITH_PARQUET
4479 (lambda _
4480 (setenv "PYARROW_WITH_PARQUET" "1"))))))
4481 (propagated-inputs
4482 `(("apache-arrow:lib" ,apache-arrow-0.16)
4483 ("apache-arrow:include" ,apache-arrow-0.16 "include")
4484 ("python-numpy" ,python-numpy)
4485 ("python-pandas" ,python-pandas)
4486 ("python-six" ,python-six)))
4487 (native-inputs
4488 (list cmake-minimal
4489 pkg-config
4490 python-cython
4491 python-pytest
4492 python-pytest-runner
4493 python-setuptools-scm))
4494 (outputs '("out"))
4495 (home-page "https://arrow.apache.org/docs/python/")
4496 (synopsis "Python bindings for Apache Arrow")
4497 (description
4498 "This library provides a Pythonic API wrapper for the reference Arrow C++
4499implementation, along with tools for interoperability with pandas, NumPy, and
4500other traditional Python scientific computing packages.")
4501 (license license:asl2.0)))
4502
4445(define-public python-crate 4503(define-public python-crate
4446 (package 4504 (package
4447 (name "python-crate") 4505 (name "python-crate")