mirror of
https://github.com/termux-pacman/termux-packages.git
synced 2026-01-26 20:52:34 +00:00
Update to numpy 2, and update reverse dependencies: - matplotlib from 3.9.1 to 3.9.2 - python-contourpy from 1.2.1 to 1.3.0 - python-numpy from 1.26.5 to 2.1.1 - python-onnxruntime from 1.19.0 to 1.19.2 - python-scipy from 1.14.0 to 1.14.1 - python-torch from 2.1.2 to 2.4.1 - python-torchaudio from 2.0.1 to 2.4.1 - python-torchvision from 0.15.1 to `0.19.1 - Revbump: python-pyarrow, inkscape and opencv Some of these packages does not currently build before this PR. Getting these updated and buildable is a nice step to prepare for [python 3.12](https://github.com/termux/termux-packages/pull/18078). Fixes #21059, #21110, #21194 and #21284. Co-authored-by: Chongyun Lee <45286352+licy183@users.noreply.github.com>
45 lines
1.6 KiB
Bash
45 lines
1.6 KiB
Bash
TERMUX_PKG_HOMEPAGE=https://github.com/apache/arrow
|
|
TERMUX_PKG_DESCRIPTION="Python bindings for Apache Arrow"
|
|
TERMUX_PKG_LICENSE="Apache-2.0"
|
|
TERMUX_PKG_MAINTAINER="@termux"
|
|
# Align the version with `libarrow-cpp` package.
|
|
TERMUX_PKG_VERSION="17.0.0"
|
|
TERMUX_PKG_REVISION=2
|
|
TERMUX_PKG_SRCURL=https://github.com/apache/arrow/archive/refs/tags/apache-arrow-${TERMUX_PKG_VERSION}.tar.gz
|
|
TERMUX_PKG_SHA256=8379554d89f19f2c8db63620721cabade62541f47a4e706dfb0a401f05a713ef
|
|
TERMUX_PKG_AUTO_UPDATE=true
|
|
TERMUX_PKG_UPDATE_METHOD=repology
|
|
TERMUX_PKG_DEPENDS="abseil-cpp, libarrow-cpp (>= ${TERMUX_PKG_VERSION}), libc++, python, python-numpy"
|
|
TERMUX_PKG_PYTHON_COMMON_DEPS="build, Cython, numpy, 'setuptools==65.7.0', setuptools-scm, wheel"
|
|
TERMUX_PKG_PROVIDES="libarrow-python"
|
|
|
|
termux_step_pre_configure() {
|
|
TERMUX_PKG_SRCDIR+="/python"
|
|
TERMUX_PKG_BUILDDIR="$TERMUX_PKG_SRCDIR"
|
|
|
|
export PYARROW_CMAKE_OPTIONS="
|
|
-DCMAKE_PREFIX_PATH=$TERMUX_PREFIX/lib/cmake
|
|
-DNUMPY_INCLUDE_DIRS=$TERMUX_PYTHON_HOME/site-packages/numpy/_core/include
|
|
"
|
|
export PYARROW_WITH_DATASET=1
|
|
export PYARROW_WITH_HDFS=1
|
|
export PYARROW_WITH_ORC=1
|
|
export PYARROW_WITH_PARQUET=1
|
|
}
|
|
|
|
termux_step_configure() {
|
|
# cmake is not intended to be invoked directly.
|
|
termux_setup_cmake
|
|
termux_setup_ninja
|
|
}
|
|
|
|
termux_step_make() {
|
|
PYTHONPATH='' python -m build -w -n -x "$TERMUX_PKG_SRCDIR"
|
|
}
|
|
|
|
termux_step_make_install() {
|
|
local _pyver="${TERMUX_PYTHON_VERSION//./}"
|
|
local _wheel="pyarrow-${TERMUX_PKG_VERSION}-cp${_pyver}-cp${_pyver}-linux_${TERMUX_ARCH}.whl"
|
|
pip install --no-deps --prefix="$TERMUX_PREFIX" "$TERMUX_PKG_SRCDIR/dist/${_wheel}"
|
|
}
|