science/polytope: New port: Library for generating Voronoi and Voronoi-like tessellations

This commit is contained in:
Yuri Victorovich 2022-12-03 01:17:57 -08:00
parent b19fde26dc
commit 27ca116ba8
7 changed files with 123 additions and 0 deletions

View file

@ -265,6 +265,7 @@
SUBDIR += phonopy
SUBDIR += plumed
SUBDIR += pnetcdf
SUBDIR += polytope
SUBDIR += precice
SUBDIR += psi4
SUBDIR += pulseview

33
science/polytope/Makefile Normal file
View file

@ -0,0 +1,33 @@
PORTNAME= polytope
DISTVERSION= 0.6.2-2
DISTVERSIONSUFFIX= -g764fd19
CATEGORIES= science
MAINTAINER= yuri@FreeBSD.org
COMMENT= Library for generating Voronoi and Voronoi-like tessellations
WWW= https://github.com/pbtoast/polytope
LICENSE= BSD3CLAUSE
LICENSE_FILE= ${WRKSRC}/LICENSE
BUILD_DEPENDS= ${LOCALBASE}/include/boost/geometry.hpp:devel/boost-libs
LIB_DEPENDS= libsz.so:science/libaec
USES= cmake:testing
USE_LDCONFIG= yes
USE_GITHUB= yes
GH_ACCOUNT= pbtoast
CMAKE_ON= BUILD_SHARED_LIBS
CMAKE_OFF= TESTING
CMAKE_TESTING_ON= TESTING # 1 test is known to fail, see https://github.com/pbtoast/polytope/issues/18
OPTIONS_DEFINE= SILO
OPTIONS_DEFAULT= SILO
SILO_DESC= Use SILO reader/writer
SILO_CMAKE_BOOL= USE_SILO
SILO_LIB_DEPENDS= libsiloh5.so:science/silo
.include <bsd.port.mk>

View file

@ -0,0 +1,3 @@
TIMESTAMP = 1670054925
SHA256 (pbtoast-polytope-0.6.2-2-g764fd19_GH0.tar.gz) = e28a965271e3c1c4cd09c015d7f1d4410b3092a64b994c41d27b9c577bebdc8c
SIZE (pbtoast-polytope-0.6.2-2-g764fd19_GH0.tar.gz) = 6858333

View file

@ -0,0 +1,11 @@
--- CMakeLists.txt.orig 2022-12-03 08:13:57 UTC
+++ CMakeLists.txt
@@ -10,7 +10,7 @@ set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/Modul
project(Polytope)
# We require at least C++11
-set(CMAKE_CXX_STANDARD 11)
+set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)

View file

@ -0,0 +1,22 @@
- uses std::integer_sequence C++14 feature
--- src/CMakeLists.txt.orig 2022-12-03 08:18:04 UTC
+++ src/CMakeLists.txt
@@ -17,7 +17,7 @@ endif()
# TriangleTessellator and triangle source
if (HAVE_TRIANGLE)
list(APPEND TESSELLATOR_SOURCES TriangleTessellator.cc)
- add_library(triangle STATIC predicates.cc triangle.c)
+ add_library(triangle predicates.cc triangle.c)
#set(TRIANGLE_LIB triangle PARENT_SCOPE)
set(TRIANGLE_LIB triangle)
set_target_properties(triangle PROPERTIES
@@ -49,7 +49,7 @@ endif()
file(GLOB HEADERS *.hh)
list(APPEND HEADERS "${PROJECT_BINARY_DIR}/polytope.hh")
-add_library(polytope STATIC
+add_library(polytope
${TESSELLATOR_SOURCES} ${IO_SOURCES} ErrorHandler.cc
polytope_internal_abort.cc)

View file

@ -0,0 +1,8 @@
Polytope is a C++ library for generating polygonal and polyhedral meshes.
It makes use of various 2D and 3D tessellation techniques, but provides
a single representation for these tessellations, and a simple interface
for generating them.
Polytope has a simple C interface for use with other languages. It also
includes bindings for Python. These bindings allow you to easily incorporate
Polytope into your own mesh generation tools.

View file

@ -0,0 +1,45 @@
include/polytope/BoostOrphanage.hh
include/polytope/BoostTessellator.hh
include/polytope/BoostTessellatorTraits.hh
include/polytope/Clipper2d.hh
include/polytope/DimensionTraits.hh
include/polytope/ErrorHandler.hh
include/polytope/IntPointMap.hh
include/polytope/KeyTraits.hh
include/polytope/MeshEditor.hh
include/polytope/OrphanageBase.hh
include/polytope/PLC.hh
include/polytope/PLC_Boost_2d.hh
include/polytope/PLC_CSG_2d.hh
include/polytope/PLC_CSG_3d.hh
include/polytope/Point.hh
include/polytope/QuantTessellation.hh
include/polytope/QuantizedCoordinates.hh
include/polytope/QuantizedTessellation2d.hh
include/polytope/QuantizedTessellation3d.hh
include/polytope/ReducedPLC.hh
include/polytope/SiloReader.hh
include/polytope/SiloWriter.hh
include/polytope/Tessellation.hh
include/polytope/Tessellator.hh
include/polytope/TessellatorInline.hh
include/polytope/TetgenTessellator.hh
include/polytope/TriangleTessellator.hh
include/polytope/VoroPP_2d.hh
include/polytope/VoroPP_3d.hh
include/polytope/clipQuantizedTessellation.hh
include/polytope/convexHull_2d.hh
include/polytope/convexHull_3d.hh
include/polytope/findBoundaryElements.hh
include/polytope/makeBoxPLC.hh
include/polytope/polytope.hh
include/polytope/polytope_geometric_utilities.hh
include/polytope/polytope_internal.hh
include/polytope/polytope_parallel_utilities.hh
include/polytope/polytope_serialize.hh
include/polytope/polytope_tessellator_utilities.hh
include/polytope/polytope_write_OOGL.hh
include/polytope/removeElements.hh
include/polytope/simplifyPLCfacets.hh
include/polytope/snapToBoundary.hh
lib/libpolytope.so