diff options
author | pi <pi@FreeBSD.org> | 2016-07-10 15:42:55 +0800 |
---|---|---|
committer | pi <pi@FreeBSD.org> | 2016-07-10 15:42:55 +0800 |
commit | 68863fc37171423cd9b3c2f340f2f61dd1c9850c (patch) | |
tree | f42b63d30d2cbda898963c01fba5fd5f4dccfec6 | |
parent | fff755abbe5342e1d7bf411923605888115e6093 (diff) | |
download | freebsd-ports-gnome-68863fc37171423cd9b3c2f340f2f61dd1c9850c.tar.gz freebsd-ports-gnome-68863fc37171423cd9b3c2f340f2f61dd1c9850c.tar.zst freebsd-ports-gnome-68863fc37171423cd9b3c2f340f2f61dd1c9850c.zip |
New port: math/cadabra2
Cadabra is a symbolic computer algebra system (CAS) designed
specifically for the solution of problems encountered in field
theory. It has extensive functionality for tensor computer algebra,
tensor polynomial simplification including multi-term symmetries,
fermions and anti-commuting variables, Clifford algebras and Fierz
transformations, component computations, implicit coordinate
dependence, multiple index types and many more. The input format
is a subset of TeX.
WWW: http://cadabra.science/
PR: 210476
Submitted by: Yuri Victorovich <yuri@rawbw.com>
-rw-r--r-- | math/Makefile | 1 | ||||
-rw-r--r-- | math/cadabra2/Makefile | 65 | ||||
-rw-r--r-- | math/cadabra2/distinfo | 3 | ||||
-rw-r--r-- | math/cadabra2/files/patch-CMakeLists.txt | 15 | ||||
-rw-r--r-- | math/cadabra2/files/patch-client__server_CMakeLists.txt | 21 | ||||
-rw-r--r-- | math/cadabra2/pkg-descr | 10 | ||||
-rw-r--r-- | math/cadabra2/pkg-plist | 25 |
7 files changed, 140 insertions, 0 deletions
diff --git a/math/Makefile b/math/Makefile index 14fc753fe2e1..7ff03313cfb5 100644 --- a/math/Makefile +++ b/math/Makefile @@ -96,6 +96,7 @@ SUBDIR += blitz++ SUBDIR += blocksolve95 SUBDIR += bsdnt + SUBDIR += cadabra2 SUBDIR += calc SUBDIR += calcoo SUBDIR += calctool diff --git a/math/cadabra2/Makefile b/math/cadabra2/Makefile new file mode 100644 index 000000000000..a581932d0e1d --- /dev/null +++ b/math/cadabra2/Makefile @@ -0,0 +1,65 @@ +# Created by: Yuri Victorovich <yuri@rawbw.com> +# $FreeBSD$ + +PORTNAME= cadabra2 +PORTVERSION= 2.0.816 +CATEGORIES= math + +MAINTAINER= yuri@rawbw.com +COMMENT= Computer algebra system for solving field theory problems + +LICENSE= LGPL3 +LICENSE_FILE= ${WRKSRC}/doc/license.txt + +LIB_DEPENDS= libboost_python.so:devel/boost-python-libs \ + libpcrecpp.so:devel/pcre \ + libboost_system.so:devel/boost-libs \ + libjsoncpp.so:devel/jsoncpp \ + libgmp.so:math/gmp \ + libuuid.so:misc/e2fsprogs-libuuid +RUN_DEPENDS= ${PYTHON_SITELIBDIR}/sympy/__init__.py:math/py-sympy \ + ${PYTHON_SITELIBDIR}/matplotlib/__init__.py:math/py-matplotlib + +USE_GITHUB= yes +GH_ACCOUNT= kpeeters +GH_TAGNAME= 8258bfc + +BROKEN_FreeBSD_9= does not build: fatal error: 'type_traits' file not found +GUI_BROKEN= Builds but has a WebSockets communication problem in the runtime +GUI_CONFLICTS_BUILD= websocketpp-* + +OPTIONS_DEFINE= GUI + +USES= compiler:c++11-lang cmake gettext gmake pkgconfig python:2 sqlite +GUI_USE= GNOME=gtkmm30,gdkpixbuf2 +USE_TEX= base +USE_LDCONFIG= yes +OPTIONS_SUB= yes +GUI_INSTALLS_ICONS= yes + +BUILD_DEPENDS+= clang36:lang/clang36 +RUN_DEPENDS+= clang36:lang/clang36 +CC= clang36 +CXX= clang++36 + +CMAKE_ARGS+= -DBOOST_ROOT=${LOCALBASE} +CMAKE_ARGS+= -DUSE_PYTHON_3:BOOL=OFF +GUI_CMAKE_ON+= -DENABLE_FRONTEND:BOOL=ON +CXXFLAGS+= -I${LOCALBASE}/include +CXXFLAGS+= -I${LOCALBASE}/include/jsoncpp +LDFLAGS+= -L${LOCALBASE}/lib -ljsoncpp +CMAKE_CXX_FLAGS=${CXXFLAGS} +CMAKE_INSTALL_PREFIX=${PREFIX} + +post-extract: + ${RM} -r ${WRKSRC}/client_server/jsoncpp + +post-install: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/cadabra2html + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/cadabra-server + ${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/cadabra2.so + +post-install-GUI-on: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/cadabra-gtk + +.include <bsd.port.mk> diff --git a/math/cadabra2/distinfo b/math/cadabra2/distinfo new file mode 100644 index 000000000000..3825c383d9de --- /dev/null +++ b/math/cadabra2/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1466580644 +SHA256 (kpeeters-cadabra2-2.0.816-8258bfc_GH0.tar.gz) = ca8b8179b9745737aaa5185825b00031ec5fa79ad23f27bc287254963a17e318 +SIZE (kpeeters-cadabra2-2.0.816-8258bfc_GH0.tar.gz) = 3880224 diff --git a/math/cadabra2/files/patch-CMakeLists.txt b/math/cadabra2/files/patch-CMakeLists.txt new file mode 100644 index 000000000000..cbec85133cd9 --- /dev/null +++ b/math/cadabra2/files/patch-CMakeLists.txt @@ -0,0 +1,15 @@ +--- CMakeLists.txt.orig 2016-06-20 20:19:43 UTC ++++ CMakeLists.txt +@@ -107,7 +107,11 @@ set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PAT + + add_subdirectory(core) + add_subdirectory(client_server) +-add_subdirectory(frontend) + add_subdirectory(tests) + add_subdirectory(web2 EXCLUDE_FROM_ALL) + ++option(ENABLE_FRONTEND "Enable the UI frontend" OFF) ++if(ENABLE_FRONTEND) ++ add_subdirectory(frontend) ++endif() ++ diff --git a/math/cadabra2/files/patch-client__server_CMakeLists.txt b/math/cadabra2/files/patch-client__server_CMakeLists.txt new file mode 100644 index 000000000000..3e4767d758e1 --- /dev/null +++ b/math/cadabra2/files/patch-client__server_CMakeLists.txt @@ -0,0 +1,21 @@ +--- client_server/CMakeLists.txt.orig 2016-06-23 23:50:35 UTC ++++ client_server/CMakeLists.txt +@@ -78,15 +78,15 @@ add_definitions("-D_WEBSOCKETPP_CPP11_ST + + # Create the server library + link_directories(${UUID_LIBRARY_DIRS}) +-add_library(cadabra_server SHARED Server.cc Snoop.cc jsoncpp/jsoncpp.cpp) ++add_library(cadabra_server SHARED Server.cc Snoop.cc) + target_link_libraries(cadabra_server ${Boost_LIBRARIES} ${SNOOP_LIBRARIES} sqlite3 ${UUID_LIBRARIES} ${PYTHON_LIBRARIES} ) + + # Create the client library. +-add_library(cadabra_client SHARED ComputeThread.cc DocumentThread.cc DataCell.cc Actions.cc popen2.cc Snoop.cc jsoncpp/jsoncpp.cpp) ++add_library(cadabra_client SHARED ComputeThread.cc DocumentThread.cc DataCell.cc Actions.cc popen2.cc Snoop.cc) + target_link_libraries(cadabra_client ${Boost_LIBRARIES} sqlite3 ${UUID_LIBRARIES} ${PYTHON_LIBRARIES}) + + # Create server binary +-include_directories("." "./websocketpp" "./jsoncpp") ++include_directories("." "./websocketpp") + add_executable(cadabra-server cadabra-server.cc) + add_executable(cadabra2html cadabra2html.cc DataCell.cc) + #add_executable(test_talk_to_server test_talk_to_server.cc) diff --git a/math/cadabra2/pkg-descr b/math/cadabra2/pkg-descr new file mode 100644 index 000000000000..548b51cdbb20 --- /dev/null +++ b/math/cadabra2/pkg-descr @@ -0,0 +1,10 @@ +Cadabra is a symbolic computer algebra system (CAS) designed +specifically for the solution of problems encountered in field +theory. It has extensive functionality for tensor computer algebra, +tensor polynomial simplification including multi-term symmetries, +fermions and anti-commuting variables, Clifford algebras and Fierz +transformations, component computations, implicit coordinate +dependence, multiple index types and many more. The input format +is a subset of TeX. + +WWW: http://cadabra.science/ diff --git a/math/cadabra2/pkg-plist b/math/cadabra2/pkg-plist new file mode 100644 index 000000000000..1ca554e959ab --- /dev/null +++ b/math/cadabra2/pkg-plist @@ -0,0 +1,25 @@ +%%GUI%%bin/cadabra-gtk +bin/cadabra-server +bin/cadabra2 +bin/cadabra2html +lib/libcadabra_client.so +lib/libcadabra_server.so +%%GUI%%lib/libtexengine.so +%%PYTHON_SITELIBDIR%%/cadabra2.so +%%PYTHON_SITELIBDIR%%/cadabra2_defaults.py +%%PYTHON_SITELIBDIR%%/cdb/gr.py +%%GUI%%share/applications/cadabra2.desktop +%%GUI%%%%DATADIR%%/images/cadabra2.png +%%GUI%%%%DATADIR%%/manual/algorithms/distribute.cnb +%%GUI%%share/icons/hicolor/256x256/apps/cadabra2.png +%%GUI%%share/icons/hicolor/64x64/apps/cadabra2.png +%%GUI%%share/icons/hicolor/scalable/apps/cadabra2.svg +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/breqn.sty +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/cmbase.sym +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/flexisym.sty +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/mathpazo.sym +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/mathptmx.sym +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/mathstyle.sty +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/msabm.sym +%%GUI%%%%TEXMFLOCALDIR%%/tex/latex/cadabra2/tableaux.sty +%%GUI%%@dir %%DATADIR%%/manual/properties |