git: fd28496df498 - main - graphics/cxxplot: New port: C++ 2D plotting library

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Wed, 09 Nov 2022 09:31:04 UTC
The branch main has been updated by yuri:

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

commit fd28496df4987f8d04d571d021935cefc04e956e
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2022-11-09 09:30:18 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2022-11-09 09:31:02 +0000

    graphics/cxxplot: New port: C++ 2D plotting library
---
 graphics/Makefile                           |  1 +
 graphics/cxxplot/Makefile                   | 29 +++++++++++++++++++++++++++++
 graphics/cxxplot/distinfo                   |  3 +++
 graphics/cxxplot/files/patch-CMakeLists.txt | 26 ++++++++++++++++++++++++++
 graphics/cxxplot/pkg-descr                  |  7 +++++++
 graphics/cxxplot/pkg-plist                  | 21 +++++++++++++++++++++
 6 files changed, 87 insertions(+)

diff --git a/graphics/Makefile b/graphics/Makefile
index 9b11aa1a9411..9e1d8321ed0a 100644
--- a/graphics/Makefile
+++ b/graphics/Makefile
@@ -117,6 +117,7 @@
     SUBDIR += curator
     SUBDIR += curtail
     SUBDIR += cuttlefish
+    SUBDIR += cxxplot
     SUBDIR += darktable
     SUBDIR += dataplot
     SUBDIR += dbow2
diff --git a/graphics/cxxplot/Makefile b/graphics/cxxplot/Makefile
new file mode 100644
index 000000000000..cfcdb202ccf6
--- /dev/null
+++ b/graphics/cxxplot/Makefile
@@ -0,0 +1,29 @@
+PORTNAME=	cxxplot
+DISTVERSIONPREFIX=	v
+DISTVERSION=	0.3.0-2
+DISTVERSIONSUFFIX=	-g750b54b
+CATEGORIES=	graphics
+
+MAINTAINER=	yuri@FreeBSD.org
+COMMENT=	C++ 2D plotting library
+WWW=		https://github.com/USNavalResearchLaboratory/cxxplot
+
+LICENSE=	BSD3CLAUSE
+LICENSE_FILE=	${WRKSRC}/license.txt
+
+USES=		cmake:testing compiler:c++20-lang gl qt:5
+USE_QT=		core gui opengl printsupport widgets buildtools:build qmake:build
+USE_GL=		gl opengl
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	USNavalResearchLaboratory
+
+CMAKE_ON=		BUILD_SHARED_LIBS
+
+do-test: # 'make test' opens a lot of windows
+.for name in 01_test 02_test 03_test 04_test 05_test 06_test_csv 07_test_image
+	@${ECHO} "==> Running the test ${name}"
+	@${TEST_WRKSRC}/tests/${name}/libcxxplot_${name:C/test_.*/test/}
+.endfor
+
+.include <bsd.port.mk>
diff --git a/graphics/cxxplot/distinfo b/graphics/cxxplot/distinfo
new file mode 100644
index 000000000000..45c22a2ce1af
--- /dev/null
+++ b/graphics/cxxplot/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1667983462
+SHA256 (USNavalResearchLaboratory-cxxplot-v0.3.0-2-g750b54b_GH0.tar.gz) = 4d4d3aa5e9076589b29a578a0fa10af14ce71b5ba690c1361b696f33e1cad53c
+SIZE (USNavalResearchLaboratory-cxxplot-v0.3.0-2-g750b54b_GH0.tar.gz) = 4385268
diff --git a/graphics/cxxplot/files/patch-CMakeLists.txt b/graphics/cxxplot/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..b4b8fd7841c9
--- /dev/null
+++ b/graphics/cxxplot/files/patch-CMakeLists.txt
@@ -0,0 +1,26 @@
+--- CMakeLists.txt.orig	2022-04-04 11:38:46 UTC
++++ CMakeLists.txt
+@@ -164,7 +164,7 @@ target_link_libraries( cxxplot
+ 
+ target_compile_options( cxxplot PRIVATE
+   $<$<CXX_COMPILER_ID:MSVC>:> # TODO ADD /W4 /WX here by fixing cxxplot_WARNOFF / ON
+-  $<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -pedantic -Werror>
++  $<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -pedantic>
+ )
+ 
+ # Install, export targets, cmake config and version
+@@ -224,9 +224,10 @@ install(
+   )
+ 
+ # tests/examples
+-if ( CXXPLOT_NOT_SUBPROJECT )
+-
++if (BUILD_TESTING)
+ add_subdirectory( tests )
+-add_subdirectory( examples )
++endif()
+ 
+-endif( CXXPLOT_NOT_SUBPROJECT )
++if (BUILD_EXAMPLES)
++add_subdirectory( examples )
++endif()
diff --git a/graphics/cxxplot/pkg-descr b/graphics/cxxplot/pkg-descr
new file mode 100644
index 000000000000..ff26b5d20251
--- /dev/null
+++ b/graphics/cxxplot/pkg-descr
@@ -0,0 +1,7 @@
+cxxplot is a C++ plotting library meant to be used in science, engineering and
+data analysis. The main objectives of the project are:
+* Provide syntax that is familiar to scientists and engineers.
+* Enable low setup times.
+* Be more performant than typical plotting libraries.
+* Operate in asynchronous mode. Therefore plot calls and user code can be
+  combined and still retain GUI interactivity.
diff --git a/graphics/cxxplot/pkg-plist b/graphics/cxxplot/pkg-plist
new file mode 100644
index 000000000000..f4d459feae48
--- /dev/null
+++ b/graphics/cxxplot/pkg-plist
@@ -0,0 +1,21 @@
+include/cxxplot-0.3.0/cxxplot/align.hpp
+include/cxxplot-0.3.0/cxxplot/color.hpp
+include/cxxplot-0.3.0/cxxplot/concepts.hpp
+include/cxxplot-0.3.0/cxxplot/cxxplot
+include/cxxplot-0.3.0/cxxplot/execution.hpp
+include/cxxplot-0.3.0/cxxplot/figure.hpp
+include/cxxplot-0.3.0/cxxplot/gettersetter.hpp
+include/cxxplot-0.3.0/cxxplot/graph.hpp
+include/cxxplot-0.3.0/cxxplot/image.hpp
+include/cxxplot-0.3.0/cxxplot/named_parameter.hpp
+include/cxxplot-0.3.0/cxxplot/point2d.hpp
+include/cxxplot-0.3.0/cxxplot/range.hpp
+include/cxxplot-0.3.0/cxxplot/styles.hpp
+include/cxxplot-0.3.0/cxxplot/typetraits.hpp
+include/cxxplot-0.3.0/cxxplot/utils.hpp
+include/cxxplot-0.3.0/cxxplot/window.hpp
+lib/cmake/cxxplot-0.3.0/cxxplotConfig.cmake
+lib/cmake/cxxplot-0.3.0/cxxplotConfigVersion.cmake
+lib/cmake/cxxplot-0.3.0/cxxplotTargets-%%CMAKE_BUILD_TYPE%%.cmake
+lib/cmake/cxxplot-0.3.0/cxxplotTargets.cmake
+lib/cxxplot-0.3.0/libcxxplot.so