Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Jul 2024 20:42:02 GMT
From:      Po-Chuan Hsieh <sunpoet@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 67dbf4470b2f - main - math/py-faiss: Fix build with swig 4.2.0+
Message-ID:  <202407132042.46DKg25O095471@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=67dbf4470b2fdf11f0f651dd631f7b1d0bc31e62

commit 67dbf4470b2fdf11f0f651dd631f7b1d0bc31e62
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2024-07-13 20:19:02 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2024-07-13 20:19:02 +0000

    math/py-faiss: Fix build with swig 4.2.0+
    
    PR:             279489
    Obtained from:  https://github.com/facebookresearch/faiss/commit/d6854136afa3b987defb2c8e8108bad76ebdb949
---
 math/py-faiss/files/patch-swig | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/math/py-faiss/files/patch-swig b/math/py-faiss/files/patch-swig
new file mode 100644
index 000000000000..1aa5f58bcbd8
--- /dev/null
+++ b/math/py-faiss/files/patch-swig
@@ -0,0 +1,21 @@
+Obtained from:	https://github.com/facebookresearch/faiss/commit/d6854136afa3b987defb2c8e8108bad76ebdb949
+
+--- swigfaiss.swig.orig	2024-02-29 21:24:50 UTC
++++ swigfaiss.swig
+@@ -1022,14 +1022,14 @@ PyObject *swig_ptr (PyObject *a)
+         return SWIG_NewPointerObj(data, SWIGTYPE_p_bool, 0);
+     }
+     if(PyArray_TYPE(ao) == NPY_UINT64) {
+-#ifdef SWIGWORDSIZE64
++#if (__SIZEOF_LONG__ == 8)
+         return SWIG_NewPointerObj(data, SWIGTYPE_p_unsigned_long, 0);
+ #else
+         return SWIG_NewPointerObj(data, SWIGTYPE_p_unsigned_long_long, 0);
+ #endif
+     }
+     if(PyArray_TYPE(ao) == NPY_INT64) {
+-#ifdef SWIGWORDSIZE64
++#if  (__SIZEOF_LONG__ == 8)
+         return SWIG_NewPointerObj(data, SWIGTYPE_p_long, 0);
+ #else
+         return SWIG_NewPointerObj(data, SWIGTYPE_p_long_long, 0);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202407132042.46DKg25O095471>