Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09-beta 52 lines 1.4 kB view raw
1{ lib, buildPythonPackage, python, isPy3k, arrow-cpp, cmake, cython, futures, hypothesis, numpy, pandas, pytestCheckHook, pytest-lazy-fixture, pkgconfig, setuptools_scm, six }: 2 3let 4 _arrow-cpp = arrow-cpp.override { python3 = python; }; 5in 6 7buildPythonPackage rec { 8 pname = "pyarrow"; 9 disabled = !isPy3k; 10 11 inherit (_arrow-cpp) version src; 12 13 sourceRoot = "apache-arrow-${version}/python"; 14 15 nativeBuildInputs = [ cmake cython pkgconfig setuptools_scm ]; 16 propagatedBuildInputs = [ numpy six ]; 17 checkInputs = [ hypothesis pandas pytestCheckHook pytest-lazy-fixture ]; 18 19 PYARROW_BUILD_TYPE = "release"; 20 PYARROW_WITH_PARQUET = true; 21 PYARROW_CMAKE_OPTIONS = [ 22 "-DCMAKE_INSTALL_RPATH=${ARROW_HOME}/lib" 23 24 # This doesn't use setup hook to call cmake so we need to workaround #54606 25 # ourselves 26 "-DCMAKE_POLICY_DEFAULT_CMP0025=NEW" 27 ]; 28 ARROW_HOME = _arrow-cpp; 29 PARQUET_HOME = _arrow-cpp; 30 31 dontUseCmakeConfigure = true; 32 33 preBuild = '' 34 export PYARROW_PARALLEL=$NIX_BUILD_CORES 35 ''; 36 37 dontUseSetuptoolsCheck = true; 38 preCheck = '' 39 mv pyarrow/tests tests 40 rm -rf pyarrow 41 mkdir pyarrow 42 mv tests pyarrow/tests 43 ''; 44 45 meta = with lib; { 46 description = "A cross-language development platform for in-memory data"; 47 homepage = "https://arrow.apache.org/"; 48 license = lib.licenses.asl20; 49 platforms = platforms.unix; 50 maintainers = with lib.maintainers; [ veprbl ]; 51 }; 52}