aboutsummaryrefslogtreecommitdiff
path: root/math
diff options
context:
space:
mode:
authorYuri Victorovich <yuri@FreeBSD.org>2018-03-12 08:56:30 +0000
committerYuri Victorovich <yuri@FreeBSD.org>2018-03-12 08:56:30 +0000
commit8f733ea1be989de95acc98396f898e4a5f520d45 (patch)
treebdf72b6c91eb141fb060ad49702158add7c7ce21 /math
parent781ec3cca43f76744a41591206928f93171c88f9 (diff)
downloadports-8f733ea1be989de95acc98396f898e4a5f520d45.tar.gz
ports-8f733ea1be989de95acc98396f898e4a5f520d45.zip
New port: math/xtensor: Multi-dimensional arrays with broadcasting and lazy computing
Notes
Notes: svn path=/head/; revision=464237
Diffstat (limited to 'math')
-rw-r--r--math/Makefile1
-rw-r--r--math/xtensor/Makefile32
-rw-r--r--math/xtensor/distinfo5
-rw-r--r--math/xtensor/files/patch-CMakeLists.txt13
-rw-r--r--math/xtensor/files/patch-test_CMakeLists.txt29
-rw-r--r--math/xtensor/pkg-descr9
-rw-r--r--math/xtensor/pkg-plist77
7 files changed, 166 insertions, 0 deletions
diff --git a/math/Makefile b/math/Makefile
index 4e98f8b5aec5..76caa58092f3 100644
--- a/math/Makefile
+++ b/math/Makefile
@@ -773,6 +773,7 @@
SUBDIR += xplot
SUBDIR += xppaut
SUBDIR += xspread
+ SUBDIR += xtensor
SUBDIR += yacas
SUBDIR += z3
SUBDIR += zimpl
diff --git a/math/xtensor/Makefile b/math/xtensor/Makefile
new file mode 100644
index 000000000000..e0e00db06db1
--- /dev/null
+++ b/math/xtensor/Makefile
@@ -0,0 +1,32 @@
+# $FreeBSD$
+
+PORTNAME= xtensor
+DISTVERSION= 0.15.4
+CATEGORIES= math
+
+MAINTAINER= yuri@FreeBSD.org
+COMMENT= Multi-dimensional arrays with broadcasting and lazy computing
+
+LICENSE= BSD3CLAUSE
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+TEST_DEPENDS= googletest>0:devel/googletest
+
+USES= cmake
+USE_GITHUB= yes
+GH_ACCOUNT= QuantStack
+GH_TUPLE= QuantStack:xtl:0.4.4:xtl/xtl
+NO_BUILD= yes
+NO_ARCH= yes
+
+post-install:
+ cd ${WRKSRC}/xtl/include && ${COPYTREE_SHARE} xtl ${STAGEDIR}${PREFIX}/include
+
+do-test: # 1 test is known to fail: https://github.com/QuantStack/xtensor/issues/674
+ @${RLN} ${STAGEDIR}${PREFIX}/include ${WRKSRC}/test/staged-include
+ @cd ${WRKSRC}/test && \
+ ${CMAKE_BIN} ${CMAKE_ARGS} . && \
+ ${MAKE_CMD} && \
+ ${MAKE_CMD} xtest
+
+.include <bsd.port.mk>
diff --git a/math/xtensor/distinfo b/math/xtensor/distinfo
new file mode 100644
index 000000000000..456b7fd642ed
--- /dev/null
+++ b/math/xtensor/distinfo
@@ -0,0 +1,5 @@
+TIMESTAMP = 1520842745
+SHA256 (QuantStack-xtensor-0.15.4_GH0.tar.gz) = 1383d34d79c4c579d577a502b145b458f74e1d76749d31a893beec5c6799098c
+SIZE (QuantStack-xtensor-0.15.4_GH0.tar.gz) = 702792
+SHA256 (QuantStack-xtl-0.4.4_GH0.tar.gz) = 2e24ae1e990b36c21134ee8b2017e4d8f1aa760ba0e62e57c9de8f6339052f7f
+SIZE (QuantStack-xtl-0.4.4_GH0.tar.gz) = 80592
diff --git a/math/xtensor/files/patch-CMakeLists.txt b/math/xtensor/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..e700e86e57ff
--- /dev/null
+++ b/math/xtensor/files/patch-CMakeLists.txt
@@ -0,0 +1,13 @@
+--- CMakeLists.txt.orig 2018-03-12 08:10:41 UTC
++++ CMakeLists.txt
+@@ -28,8 +28,8 @@ message(STATUS "Building xtensor v${${PR
+ # Dependencies
+ # ============
+
+-find_package(xtl 0.4 REQUIRED)
+-message(STATUS "Found xtl: ${xtl_INCLUDE_DIRS}/xtl")
++#find_package(xtl 0.4 REQUIRED)
++message(STATUS "Found xtl: xtl/include")
+
+ # Build
+ # =====
diff --git a/math/xtensor/files/patch-test_CMakeLists.txt b/math/xtensor/files/patch-test_CMakeLists.txt
new file mode 100644
index 000000000000..0246b525bc41
--- /dev/null
+++ b/math/xtensor/files/patch-test_CMakeLists.txt
@@ -0,0 +1,29 @@
+--- test/CMakeLists.txt.orig 2018-02-16 23:52:29 UTC
++++ test/CMakeLists.txt
+@@ -8,12 +8,12 @@
+
+ cmake_minimum_required(VERSION 3.1)
+
+-if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
+- project(xtensor-test)
++#if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
++ #project(xtensor-test)
+
+- find_package(xtensor REQUIRED CONFIG)
+- set(XTENSOR_INCLUDE_DIR ${xtensor_INCLUDE_DIRS})
+-endif ()
++ #find_package(xtensor REQUIRED CONFIG)
++ include_directories(staged-include)
++#endif ()
+
+ message(STATUS "Forcing tests build type to Release")
+ set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build." FORCE)
+@@ -156,7 +156,7 @@ add_executable(${XTENSOR_TARGET} ${XTENS
+ if(DOWNLOAD_GTEST OR GTEST_SRC_DIR)
+ add_dependencies(${XTENSOR_TARGET} gtest_main)
+ endif()
+-target_link_libraries(${XTENSOR_TARGET} xtensor ${GTEST_BOTH_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
++target_link_libraries(${XTENSOR_TARGET} ${GTEST_BOTH_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
+
+ add_custom_target(xtest COMMAND test_xtensor DEPENDS ${XTENSOR_TARGET})
+
diff --git a/math/xtensor/pkg-descr b/math/xtensor/pkg-descr
new file mode 100644
index 000000000000..ffd4698ef5be
--- /dev/null
+++ b/math/xtensor/pkg-descr
@@ -0,0 +1,9 @@
+xtensor is a C++ library meant for numerical analysis with multi-dimensional
+array expressions.
+
+xtensor provides:
+* an extensible expression system enabling lazy broadcasting
+* an API following the idioms of the C++ standard library
+* tools to manipulate array expressions and build upon xtensor
+
+WWW: https://quantstack.net/xtensor
diff --git a/math/xtensor/pkg-plist b/math/xtensor/pkg-plist
new file mode 100644
index 000000000000..ec0ec683bfa7
--- /dev/null
+++ b/math/xtensor/pkg-plist
@@ -0,0 +1,77 @@
+include/xtensor/xaccumulator.hpp
+include/xtensor/xadapt.hpp
+include/xtensor/xarray.hpp
+include/xtensor/xassign.hpp
+include/xtensor/xaxis_iterator.hpp
+include/xtensor/xbroadcast.hpp
+include/xtensor/xbuffer_adaptor.hpp
+include/xtensor/xbuilder.hpp
+include/xtensor/xcomplex.hpp
+include/xtensor/xconcepts.hpp
+include/xtensor/xcontainer.hpp
+include/xtensor/xcsv.hpp
+include/xtensor/xeval.hpp
+include/xtensor/xexception.hpp
+include/xtensor/xexpression.hpp
+include/xtensor/xfixed.hpp
+include/xtensor/xfunction.hpp
+include/xtensor/xfunctor_view.hpp
+include/xtensor/xgenerator.hpp
+include/xtensor/xindex_view.hpp
+include/xtensor/xinfo.hpp
+include/xtensor/xio.hpp
+include/xtensor/xiterable.hpp
+include/xtensor/xiterator.hpp
+include/xtensor/xlayout.hpp
+include/xtensor/xmath.hpp
+include/xtensor/xnoalias.hpp
+include/xtensor/xnorm.hpp
+include/xtensor/xnpy.hpp
+include/xtensor/xoffset_view.hpp
+include/xtensor/xoperation.hpp
+include/xtensor/xoptional.hpp
+include/xtensor/xoptional_assembly.hpp
+include/xtensor/xoptional_assembly_base.hpp
+include/xtensor/xrandom.hpp
+include/xtensor/xreducer.hpp
+include/xtensor/xscalar.hpp
+include/xtensor/xsemantic.hpp
+include/xtensor/xshape.hpp
+include/xtensor/xslice.hpp
+include/xtensor/xsort.hpp
+include/xtensor/xstorage.hpp
+include/xtensor/xstrided_view.hpp
+include/xtensor/xstrides.hpp
+include/xtensor/xtensor.hpp
+include/xtensor/xtensor_config.hpp
+include/xtensor/xtensor_forward.hpp
+include/xtensor/xtensor_simd.hpp
+include/xtensor/xutils.hpp
+include/xtensor/xvectorize.hpp
+include/xtensor/xview.hpp
+include/xtensor/xview_utils.hpp
+include/xtl/xany.hpp
+include/xtl/xbase64.hpp
+include/xtl/xbasic_fixed_string.hpp
+include/xtl/xclosure.hpp
+include/xtl/xcomplex.hpp
+include/xtl/xcrtp.hpp
+include/xtl/xdynamic_bitset.hpp
+include/xtl/xfunctional.hpp
+include/xtl/xhash.hpp
+include/xtl/xhierarchy_generator.hpp
+include/xtl/xholder.hpp
+include/xtl/xiterator_base.hpp
+include/xtl/xmeta_utils.hpp
+include/xtl/xoptional.hpp
+include/xtl/xoptional_sequence.hpp
+include/xtl/xproxy_wrapper.hpp
+include/xtl/xsequence.hpp
+include/xtl/xtl_config.hpp
+include/xtl/xtype_traits.hpp
+include/xtl/xvariant.hpp
+include/xtl/xvariant_impl.hpp
+lib/cmake/xtensor/xtensorConfig.cmake
+lib/cmake/xtensor/xtensorConfigVersion.cmake
+lib/cmake/xtensor/xtensorTargets.cmake
+libdata/pkgconfig/xtensor.pc