50 lines
2.0 KiB
Bash
50 lines
2.0 KiB
Bash
# Maintainer: Peter Budai <peterbudai@hotmail.com>
|
|
|
|
_realname=imbalanced-learn
|
|
pkgbase=mingw-w64-python-${_realname}
|
|
pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
|
|
provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
|
conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
|
replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
|
pkgver=0.12.2
|
|
pkgrel=2
|
|
pkgdesc="A Python Package to Tackle the Curse of Imbalanced Datasets in Machine Learning (mingw-w64)"
|
|
arch=('any')
|
|
mingw_arch=('mingw64' 'ucrt64' 'clang64' 'clangarm64')
|
|
url='https://imbalanced-learn.org/'
|
|
msys2_repository_url='https://github.com/scikit-learn-contrib/imbalanced-learn'
|
|
msys2_references=(
|
|
'pypi: imbalanced-learn'
|
|
)
|
|
license=('spdx:MIT')
|
|
depends=("${MINGW_PACKAGE_PREFIX}-python"
|
|
"${MINGW_PACKAGE_PREFIX}-python-joblib"
|
|
"${MINGW_PACKAGE_PREFIX}-python-numpy"
|
|
"${MINGW_PACKAGE_PREFIX}-python-scikit-learn"
|
|
"${MINGW_PACKAGE_PREFIX}-python-scipy"
|
|
"${MINGW_PACKAGE_PREFIX}-python-threadpoolctl")
|
|
makedepends=("${MINGW_PACKAGE_PREFIX}-python-build"
|
|
"${MINGW_PACKAGE_PREFIX}-python-installer"
|
|
"${MINGW_PACKAGE_PREFIX}-python-setuptools"
|
|
"${MINGW_PACKAGE_PREFIX}-python-wheel")
|
|
optdepends=("${MINGW_PACKAGE_PREFIX}-python-keras"
|
|
"${MINGW_PACKAGE_PREFIX}-python-tensoflow")
|
|
source=("https://pypi.org/packages/source/${_realname::1}/${_realname}/${_realname}-${pkgver}.tar.gz")
|
|
sha256sums=('a80c56cedcb07124f266be62d3a5d2ab5b5779909a7343fdf1b993479662f6c1')
|
|
|
|
build() {
|
|
cp -r "${_realname}-${pkgver}" "python-build-${MSYSTEM}" && cd "python-build-${MSYSTEM}"
|
|
|
|
${MINGW_PREFIX}/bin/python -m build --wheel --skip-dependency-check --no-isolation
|
|
}
|
|
|
|
package() {
|
|
cd "${srcdir}/python-build-${MSYSTEM}"
|
|
|
|
MSYS2_ARG_CONV_EXCL="--prefix=" \
|
|
${MINGW_PREFIX}/bin/python -m installer --prefix=${MINGW_PREFIX} \
|
|
--destdir="${pkgdir}" dist/*.whl
|
|
|
|
install -D LICENSE "$pkgdir"/${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE
|
|
}
|