diff options
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | PKGBUILD | 9 | ||||
-rw-r--r-- | fix_get_numpy_include.patch | 25 |
4 files changed, 35 insertions, 4 deletions
@@ -1,6 +1,6 @@ pkgbase = python-opentsne-git pkgdesc = Extensible, parallel implementations of t-SNE - pkgver = 1.0.0.r1.gb9662b5 + pkgver = 1.0.0.r3.g994cf0b pkgrel = 1 url = https://opentsne.readthedocs.io/en/latest/ arch = x86_64 @@ -18,6 +18,8 @@ pkgbase = python-opentsne-git provides = python-opentsne conflicts = python-opentsne source = git+https://github.com/pavlin-policar/openTSNE.git + source = fix_get_numpy_include.patch sha256sums = SKIP + sha256sums = b7e2ef8a66e665851333a93a44dd0d6d657d6d77988dc159a14b14abeead20a1 pkgname = python-opentsne-git diff --git a/.gitignore b/.gitignore index 018a3de08144..7735b4612827 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ !PKGBUILD !.SRCINFO !.gitignore +!*.patch @@ -2,7 +2,7 @@ # Contributor: Alexandr Parkhomenko <it@52tour.ru> pkgname=python-opentsne-git -pkgver=1.0.0.r1.gb9662b5 +pkgver=1.0.0.r3.g994cf0b pkgrel=1 pkgdesc="Extensible, parallel implementations of t-SNE" url="https://opentsne.readthedocs.io/en/latest/" @@ -16,8 +16,10 @@ optdepends=( ) provides=("${pkgname%-git}") conflicts=("${pkgname%-git}") -source=("git+https://github.com/pavlin-policar/openTSNE.git") -sha256sums=('SKIP') +source=("git+https://github.com/pavlin-policar/openTSNE.git" + "fix_get_numpy_include.patch") +sha256sums=('SKIP' + 'b7e2ef8a66e665851333a93a44dd0d6d657d6d77988dc159a14b14abeead20a1') pkgver () { cd "openTSNE" @@ -27,6 +29,7 @@ pkgver () { prepare() { cd "openTSNE" sed -i 's/oldest-supported-//' pyproject.toml + patch -p1 < ../fix_get_numpy_include.patch } build() { diff --git a/fix_get_numpy_include.patch b/fix_get_numpy_include.patch new file mode 100644 index 000000000000..1f760c68126f --- /dev/null +++ b/fix_get_numpy_include.patch @@ -0,0 +1,25 @@ +diff -ru openTSNE-1.0.0.orig/setup.py openTSNE-1.0.0/setup.py +--- openTSNE-1.0.0.orig/setup.py 2023-08-11 13:36:22.222050683 +0200 ++++ openTSNE-1.0.0/setup.py 2023-08-11 13:36:44.962034085 +0200 +@@ -55,17 +55,10 @@ + writer.write(body, resources, nb_name) + + +-class get_numpy_include: +- """Helper class to determine the numpy include path +- +- The purpose of this class is to postpone importing numpy until it is +- actually installed, so that the ``get_include()`` method can be invoked. +- +- """ +- def __str__(self): +- import numpy +- return numpy.get_include() +- ++def get_numpy_include(): ++ """get the numpy includes without wrapper class""" ++ import numpy ++ return numpy.get_include() + + def get_include_dirs(): + """Get include dirs for the compiler.""" |