git: 6d9ce49d9243 - main - math/lmfit: New port: Library for Levenberg-Marquardt minimization and least-squares fitting

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Tue, 24 Jan 2023 08:58:39 UTC
The branch main has been updated by yuri:

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

commit 6d9ce49d9243982d78c3004be9e72a0b0e565096
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2023-01-24 08:58:16 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2023-01-24 08:58:16 +0000

    math/lmfit: New port: Library for Levenberg-Marquardt minimization and least-squares fitting
---
 math/Makefile                         |  1 +
 math/lmfit/Makefile                   | 26 ++++++++++++++++++++++++++
 math/lmfit/distinfo                   |  3 +++
 math/lmfit/files/patch-CMakeLists.txt | 12 ++++++++++++
 math/lmfit/pkg-descr                  |  2 ++
 math/lmfit/pkg-plist                  | 15 +++++++++++++++
 6 files changed, 59 insertions(+)

diff --git a/math/Makefile b/math/Makefile
index 86788152869b..33346fa9eeb9 100644
--- a/math/Makefile
+++ b/math/Makefile
@@ -465,6 +465,7 @@
     SUBDIR += linpack
     SUBDIR += lis
     SUBDIR += lll_spect
+    SUBDIR += lmfit
     SUBDIR += lp_solve
     SUBDIR += lrcalc
     SUBDIR += lrng
diff --git a/math/lmfit/Makefile b/math/lmfit/Makefile
new file mode 100644
index 000000000000..efd8b1b0dff4
--- /dev/null
+++ b/math/lmfit/Makefile
@@ -0,0 +1,26 @@
+PORTNAME=	lmfit
+DISTVERSION=	9.0
+CATEGORIES=	math
+MASTER_SITES=	https://jugit.fz-juelich.de/mlz/${PORTNAME}/-/archive/v${DISTVERSION}/
+DISTNAME=	${PORTNAME}-v${DISTVERSION}
+
+MAINTAINER=	yuri@FreeBSD.org
+COMMENT=	Library for Levenberg-Marquardt minimization and least-squares fitting
+WWW=		https://jugit.fz-juelich.de/mlz/lmfit
+
+LICENSE=	BSD2CLAUSE
+LICENSE_FILE=	${WRKSRC}/COPYING
+
+BUILD_DEPENDS=	libheinz>0:devel/libheinz
+
+USES=		cmake:testing perl5
+USE_PERL5=	build # only for pod2html
+USE_LDCONFIG=	yes
+
+CMAKE_OFF=	BUILD_TESTING
+CMAKE_TESTING_ON=	BUILD_TESTING
+
+OPTIONS_DEFINE=	DOCS
+PORTDOCS=	*
+
+.include <bsd.port.mk>
diff --git a/math/lmfit/distinfo b/math/lmfit/distinfo
new file mode 100644
index 000000000000..297874a06a49
--- /dev/null
+++ b/math/lmfit/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1674550325
+SHA256 (lmfit-v9.0.tar.gz) = 2e854c4b0a8f0ecddd4b8a63cfb8266ace02d191c4362762cb80aa84e781b0c3
+SIZE (lmfit-v9.0.tar.gz) = 36686
diff --git a/math/lmfit/files/patch-CMakeLists.txt b/math/lmfit/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..90b6136fc6b3
--- /dev/null
+++ b/math/lmfit/files/patch-CMakeLists.txt
@@ -0,0 +1,12 @@
+--- CMakeLists.txt.orig	2023-01-24 08:53:17 UTC
++++ CMakeLists.txt
+@@ -58,7 +58,9 @@ include(CTest)
+ 
+ add_subdirectory(lib)
+ add_subdirectory(demo)
++if (BUILD_TESTING)
+ add_subdirectory(test)
++endif()
+ if(LMFIT_CPPTEST)
+     add_subdirectory(democpp)
+ endif()
diff --git a/math/lmfit/pkg-descr b/math/lmfit/pkg-descr
new file mode 100644
index 000000000000..195a8d3f8fa4
--- /dev/null
+++ b/math/lmfit/pkg-descr
@@ -0,0 +1,2 @@
+lmfit is a C library for Levenberg-Marquardt minimization and least-squares
+fitting.
diff --git a/math/lmfit/pkg-plist b/math/lmfit/pkg-plist
new file mode 100644
index 000000000000..5be0a2f8a774
--- /dev/null
+++ b/math/lmfit/pkg-plist
@@ -0,0 +1,15 @@
+include/lmcurve.h
+include/lmcurve2.h
+include/lmdecls.h
+include/lmfit.hpp
+include/lmmin.h
+include/lmstruct.h
+lib/liblmfit.so
+lib/liblmfit.so.9
+lib/liblmfit.so.9.0.0
+libdata/pkgconfig/lmfit.pc
+share/man/man3/lmcurve.3.gz
+share/man/man3/lmcurve2.3.gz
+share/man/man3/lmmin.3.gz
+share/man/man3/lmmin2.3.gz
+share/man/man7/lmfit.7.gz