Add crlibm , correctly-rounded mathematics library.

This commit is contained in:
Brendan Fabeny 2012-01-11 06:47:02 +00:00
parent f1ecf33f43
commit 11fb6f6ca0
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=288947
5 changed files with 101 additions and 0 deletions

View file

@ -61,6 +61,7 @@
SUBDIR += concorde
SUBDIR += convertall
SUBDIR += coq
SUBDIR += crlibm
SUBDIR += cvc3
SUBDIR += dcdflib
SUBDIR += diehard

61
math/crlibm/Makefile Normal file
View file

@ -0,0 +1,61 @@
# New ports collection makefile for: crlibm
# Date created: 10 January 2012
# Whom: bf@FreeBSD.org
#
# $FreeBSD$
#
PORTNAME= crlibm
DISTVERSION= 1.0beta4
CATEGORIES= math
MASTER_SITES= http://lipforge.ens-lyon.fr/frs/download.php/%SUBDIR%/:1,2,3 \
LOCAL/bf:4
MASTER_SITE_SUBDIR= 162/:1 153/:2 154/:3
DISTFILES= ${DISTNAME}${EXTRACT_SUFX}:1,4
.if make(makesum) || !defined(NOPORTDOCS)
DISTFILES+= crlibm-1.0beta3.pdf:2,4 tripledoubleprocedures-1.0beta3.pdf:3,4
.endif
DIST_SUBDIR= crlibm
EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
MAINTAINER= bf@FreeBSD.org
COMMENT= Correctly-rounded mathematics library
LICENSE= LGPL21
LIB_DEPENDS= mpfr.4:${PORTSDIR}/math/mpfr
GNU_CONFIGURE= yes
CONFIGURE_ARGS = --enable-mpfr
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
.include <bsd.port.pre.mk>
#7-STABLE has log2() in libm after r226457 on 17 Oct 2011, but
#there was no accompanying OSVERSION bump
.if ${OSVERSION} < 802502 || (${OSVERSION} >= 900000 && ${OSVERSION} < 900027)
post-patch:
@${REINPLACE_CMD} \
-e '/testfun_libm[[:blank:]]*=[[:blank:]]*log2;/s/log2/NULL/' \
${WRKSRC}/tests/test_common.c
.endif
post-build:
@cd ${WRKSRC}; ${STRIP_CMD} -x libcrlibm.a scs_lib/libscs.a
check regression-test test: build
@cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${_MAKE_JOBS} \
${MAKE_ARGS} check
.if !defined(NOPORTDOCS)
PORTDOCS= ${DISTFILES:C|\:.*||:M*.pdf}
post-install:
@${INSTALL_DATA} -d ${DOCSDIR}
@cd ${_DISTDIR}; ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}
.endif
.include <bsd.port.post.mk>

6
math/crlibm/distinfo Normal file
View file

@ -0,0 +1,6 @@
SHA256 (crlibm/crlibm-1.0beta4.tar.gz) = 6836b4299f9421c99da2bdcd5e04a8d35577db4eb61161a401aa93751a96375d
SIZE (crlibm/crlibm-1.0beta4.tar.gz) = 2368435
SHA256 (crlibm/crlibm-1.0beta3.pdf) = cbde4b66d1fa331fa7806effb41119deb42a294df64c117c966fd659d947a5ea
SIZE (crlibm/crlibm-1.0beta3.pdf) = 1350926
SHA256 (crlibm/tripledoubleprocedures-1.0beta3.pdf) = 55bd342c623e369e5450b36337da3879e18b1a483d55706e2f979c9cce906fac
SIZE (crlibm/tripledoubleprocedures-1.0beta3.pdf) = 460704

23
math/crlibm/pkg-descr Normal file
View file

@ -0,0 +1,23 @@
CRlibm is an efficient and proven mathematical library, which
provides implementations of the double-precision C99 standard
elementary functions, correctly rounded in the four IEEE-754 rounding
modes, and sufficiently efficient in average time, worst-case time,
and memory consumption to replace existing libms transparently.
The distribution includes extensive documentation with the proof
of each function (currently more than 100 pages), as well as all
the Maple scripts used to develop the functions. This makes this
library an excellent tutorial on software elementary function
development.
CRlibm also includes a lightweight library for multiple precision,
scslib (Software Carry Save Library). This library has been developed
specifically to answer the needs of the CRlibm project: precision
up to a few hundred bits, portability, compatibility with IEEE
floating-point standards, performance comparable to or better than
GMP, and a small footprint. It uses a data-structure which allows
carry propagations to be avoided during multiple-precision
multiplications, and supports addition, subtraction, multiplication,
and conversions.
WWW: http://lipforge.ens-lyon.fr/www/crlibm/

10
math/crlibm/pkg-plist Normal file
View file

@ -0,0 +1,10 @@
bin/crlibm_blindtest
bin/crlibm_generate_test_vectors
bin/crlibm_soaktest
bin/crlibm_testperf
bin/crlibm_testval
include/crlibm.h
include/crlibm_config.h
include/scs.h
lib/libcrlibm.a
lib/libscs.a