git: edf46ccd6570 - main - math/dqfun: new port, double-quad precision package with special functions

From: Thierry Thomas <thierry_at_FreeBSD.org>
Date: Sun, 05 Nov 2023 18:32:53 UTC
The branch main has been updated by thierry:

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

commit edf46ccd6570ec12e80e2344605fb1c24713ea26
Author:     Thierry Thomas <thierry@FreeBSD.org>
AuthorDate: 2023-11-05 18:28:24 +0000
Commit:     Thierry Thomas <thierry@FreeBSD.org>
CommitDate: 2023-11-05 18:32:49 +0000

    math/dqfun: new port, double-quad precision package with special functions
---
 math/dqfun/Makefile  | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 math/dqfun/distinfo  |  3 +++
 math/dqfun/pkg-descr | 10 ++++++++++
 math/dqfun/pkg-plist | 10 ++++++++++
 4 files changed, 77 insertions(+)

diff --git a/math/dqfun/Makefile b/math/dqfun/Makefile
new file mode 100644
index 000000000000..a2a5fa1b0e2e
--- /dev/null
+++ b/math/dqfun/Makefile
@@ -0,0 +1,54 @@
+PORTNAME=	dqfun
+DISTVERSIONPREFIX=v
+DISTVERSION=	03
+CATEGORIES=	math
+MASTER_SITES=	https://www.davidhbailey.com/dhbsoftware/
+
+MAINTAINER=	fortran@FreeBSD.org
+COMMENT=	Double-quad precision package with special functions
+WWW=		https://crd-legacy.lbl.gov/~dhbailey/mpdist
+
+LICENSE=	BSD3CLAUSE
+LICENSE_FILE=	${WRKSRC}/DISCLAIMER.txt
+
+USES=		fortran
+
+BINARY_ALIAS=	gfortran=${FC}
+FFLAGS+=	-O3
+BUILD_WRKSRC=	${WRKSRC}/fortran
+
+OPTIONS_DEFINE=	DOCS EXAMPLES
+
+pre-configure:
+.for f in gnu-complib-dq.scr gnu-complink-dq.scr
+	${REINPLACE_CMD} -e 's|-O3|${FFLAGS}|' ${BUILD_WRKSRC}/${f}
+.endfor
+
+do-build:
+	cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ./gnu-complib-dq.scr
+
+do-build-EXAMPLES-on:
+	cd ${BUILD_WRKSRC} &&	\
+		${SETENV} ${MAKE_ENV} ./gnu-complink-dq.scr tpslqm1dq
+
+do-install:
+	${MKDIR} ${STAGEDIR}${PREFIX}/include
+	cd ${BUILD_WRKSRC} &&	\
+	${INSTALL_DATA} *.mod ${STAGEDIR}${PREFIX}/include
+
+do-install-EXAMPLES-on:
+	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+	cd ${BUILD_WRKSRC} &&	\
+	${INSTALL_PROGRAM} tpslqm1dq ${STAGEDIR}${EXAMPLESDIR}	&&	\
+	${INSTALL_DATA} tpslqm1dq.f90 ${STAGEDIR}${EXAMPLESDIR}
+
+do-install-DOCS-on:
+	${MKDIR} ${STAGEDIR}${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README-dqfun.txt ${STAGEDIR}${DOCSDIR}
+	cd ${BUILD_WRKSRC} &&	\
+	${INSTALL_DATA} *.ref.txt ${STAGEDIR}${DOCSDIR}
+
+do-test:
+	cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ./gnu-dqfun-tests.scr
+
+.include <bsd.port.mk>
diff --git a/math/dqfun/distinfo b/math/dqfun/distinfo
new file mode 100644
index 000000000000..ddaeb76cc122
--- /dev/null
+++ b/math/dqfun/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1699200080
+SHA256 (dqfun-v03.tar.gz) = 3ad51ea391dfbfe69c0f84ef988fe136d5910a2cafe860ddc6c78d3589468295
+SIZE (dqfun-v03.tar.gz) = 99019
diff --git a/math/dqfun/pkg-descr b/math/dqfun/pkg-descr
new file mode 100644
index 000000000000..6416f2a3345f
--- /dev/null
+++ b/math/dqfun/pkg-descr
@@ -0,0 +1,10 @@
+DQFUN: A double-quad precision package with special functions (approximately 66
+digit precision).
+
+This package permits one to perform floating-point computations (real and
+complex) to double-quad precision (approximately 65 digits), by making only
+relatively minor changes to existing Fortran programs. All basic arithmetic
+operations and transcendental functions are supported, together with numerous
+special functions. The package should run correctly on any Unix-based system
+supporting a Fortran-2008 compiler and IEEE 128-bit floating-point arithmetic
+(in hardware or software).
diff --git a/math/dqfun/pkg-plist b/math/dqfun/pkg-plist
new file mode 100644
index 000000000000..feec48d87a4a
--- /dev/null
+++ b/math/dqfun/pkg-plist
@@ -0,0 +1,10 @@
+include/dqfuna.mod
+include/dqfune.mod
+include/dqmodule.mod
+%%PORTDOCS%%%%DOCSDIR%%/README-dqfun.txt
+%%PORTDOCS%%%%DOCSDIR%%/testdqfun.ref.txt
+%%PORTDOCS%%%%DOCSDIR%%/tpphixdq.ref.txt
+%%PORTDOCS%%%%DOCSDIR%%/tpslqm1dq.ref.txt
+%%PORTDOCS%%%%DOCSDIR%%/tquaddq.ref.txt
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tpslqm1dq
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tpslqm1dq.f90