<pre style='margin:0'>
Ryan Schmidt (ryandesign) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/f20fee92371a35d17fd867cb7de19c550b5796cd">https://github.com/macports/macports-ports/commit/f20fee92371a35d17fd867cb7de19c550b5796cd</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new f20fee92371 libfaiss: Update to version 1.6.4, add Python ports
</span>f20fee92371 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit f20fee92371a35d17fd867cb7de19c550b5796cd
</span>Author: Steven Thomas Smith <s.t.smith@ieee.org>
AuthorDate: Wed Jun 24 18:49:54 2020 -0400
<span style='display:block; white-space:pre;color:#404040;'> libfaiss: Update to version 1.6.4, add Python ports
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> * Update to version 1.6.4
</span><span style='display:block; white-space:pre;color:#404040;'> * Add python ports
</span>---
math/libfaiss/Portfile | 156 ++++++++++++++++++++++++++++++++++++-------------
1 file changed, 114 insertions(+), 42 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/math/libfaiss/Portfile b/math/libfaiss/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 78f7a761a00..0aa0a142616 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/math/libfaiss/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/math/libfaiss/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,57 +1,47 @@
</span> # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
PortSystem 1.0
<span style='display:block; white-space:pre;background:#e0ffe0;'>+PortGroup cmake 1.1
</span> PortGroup github 1.0
<span style='display:block; white-space:pre;background:#ffe0e0;'>-PortGroup compilers 1.0
</span>
<span style='display:block; white-space:pre;background:#ffe0e0;'>-github.setup facebookresearch faiss 56383610bcb982d6591e2e2bea3516cb7723e04a
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+github.setup facebookresearch faiss 1.6.4 v
</span> name libfaiss
<span style='display:block; white-space:pre;background:#ffe0e0;'>-version 20180214
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-checksums rmd160 e699f7ec89d8c6d5c4957022d26d162ab3b85d62 \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- sha256 6ef05ff911e68bb4ff3f209d2abb3a2e57d36f308176e1555266ecd055c565bf
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+epoch 1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> categories math
license BSD
platforms darwin
maintainers {@beauby fb.com:hoss} {@mdouze fb.com:matthijs} \
openmaintainer
<span style='display:block; white-space:pre;background:#ffe0e0;'>-description Efficient similarity search library from Facebook AI Research.
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-long_description Library for efficient similarity search and clustering of \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- dense vectors. It contains algorithms that search in sets \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- of vectors of any size, up to ones that possibly do not \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- fit in RAM. It also contains supporting code for \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- evaluation and parameter tuning. Faiss is written in C++ \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- with complete wrappers for Python/numpy. Some of the most \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- useful algorithms are implemented on the GPU.
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-compilers.choose cxx
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# The Apple native llvm compiler does not support OpenMP.
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-compiler.blacklist llvm-gcc-4.2
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-compiler.fallback macports-gcc-7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-compilers.setup
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-use_configure no
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-pre-build {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- touch ${worksrcpath}/makefile.inc
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append CC=${configure.cxx}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append "CFLAGS=-fPIC -m64 -Wall -g -O3 -msse4 -mpopcnt -fopenmp \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- -Wno-sign-compare -std=c++11 -I/usr/include/malloc/"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append "LDFLAGS=-g -fPIC -fopenmp"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append SHAREDEXT=dylib
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append "SHAREDFLAGS=-Wl,-F. -bundle -undefined dynamic_lookup"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append FAISSSHAREDFLAGS=-dynamiclib
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append BLASCFLAGS=-DFINTEGER=int
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.env-append "BLASLDFLAGS=-framework Accelerate"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-build.target libfaiss.a libfaiss.dylib
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-destroot.target
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-destroot.destdir
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-destroot.cmd mkdir -p ${destroot}${prefix}/lib && \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- cp libfaiss.a libfaiss.dylib ${destroot}${prefix}/lib && \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- mkdir -p ${destroot}${prefix}/include/faiss && \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- cp -R ./*.h ${destroot}${prefix}/include/faiss/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+description Efficient similarity search library from \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ Facebook AI Research.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+long_description Library for efficient similarity search and \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ clustering of dense vectors. It contains \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ algorithms that search in sets of vectors of any \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ size, up to ones that possibly do not fit in \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ RAM. It also contains supporting code for \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ evaluation and parameter tuning. Faiss is written \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ in C++ with complete wrappers for \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ Python/numpy. Some of the most useful algorithms \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ are implemented on the GPU.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+checksums rmd160 0b352405e6814d245e8ca892a5dd70570babe57b \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 465ace5acc0af16df53ba8a921aaa574c00f56781edeafe7f74e0d9071ec8431 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ size 2758059
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+compiler.cxx_standard 2011
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+compiler.openmp_version 2.5
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+configure.ldflags-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -L${prefix}/lib/libomp \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -lomp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+configure.args-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DFAISS_ENABLE_GPU:BOOL=OFF \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DFAISS_ENABLE_PYTHON:BOOL=OFF
</span>
variant openblas description {Use OpenBLAS instead of Apple's Accelerate framework} {
depends_lib-append port:OpenBLAS
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -60,3 +50,85 @@ variant openblas description {Use OpenBLAS instead of Apple's Accelerate framewo
</span> }
default_variants +openblas
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# create Python subports
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+set python_versions {37 38}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+foreach v ${python_versions} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ subport py${v}-${github.project} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PortGroup python 1.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ python.default_version ${v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Python bindings for supported Python versions
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {[string match "py*" ${subport}]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ github.setup ${github.author} ${github.project} ${github.version} ${github.tag_prefix}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ categories-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ math
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ description Python ${python.branch} bindings for ${description}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ long_description \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ This package provides Python ${python.branch} bindings, \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ modules, and scripts.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_build-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-setuptools \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:swig \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:swig-python
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_lib-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-numpy
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_test-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:py${python.version}-pytest
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Build instructions:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # https://github.com/facebookresearch/faiss/blob/master/INSTALL.md#compile-from-source
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ use_configure yes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-replace \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DFAISS_ENABLE_PYTHON:BOOL=OFF \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DFAISS_ENABLE_PYTHON:BOOL=ON
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DPython_EXECUTABLE=${python.bin} \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DSWIG_EXECUTABLE=${prefix}/bin/swig
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.pre_args-delete \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ --prefix=${prefix}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.pre_args-replace \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ "-DCMAKE_MAKE_PROGRAM=${python.bin} setup.py --no-user-cfg" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DCMAKE_MAKE_PROGRAM=[portbuild::build_getmaketype]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ pre-build {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ system -W ${configure.dir} "[portbuild::build_getmaketype] -w all[portbuild::build_getjobsarg] ${build.post_args}"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ build.post_args-delete \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ VERBOSE=ON
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ build.dir ${configure.dir}/faiss/python
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ destroot.dir ${build.dir}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ destroot.target install
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ post-destroot {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set docdir ${prefix}/share/doc/${subport}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set tutorialdir ${prefix}/share/${subport}/tutorial
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ xinstall -d \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${destroot}${docdir} \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${destroot}${tutorialdir}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ xinstall -m 0644 -W ${worksrcpath} README.md LICENSE \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${destroot}${docdir}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ copy ${worksrcpath}/tutorial/python \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${destroot}${tutorialdir}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.run yes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.dir ${worksrcpath}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.cmd py.test-${python.branch}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.target tests
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.env-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ "PATH=$env(PATH):${python.prefix}/bin" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ "PYTHONPATH=${configure.dir}/faiss/python"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ livecheck.type none
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span></pre><pre style='margin:0'>
</pre>