summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Enge <andreas.enge@inria.fr>2020-06-30 16:08:05 +0200
committerAndreas Enge <andreas.enge@inria.fr>2020-06-30 16:11:21 +0200
commit83975da8b13b867dc5f741b9506799cd0529ef1b (patch)
treec19f8eb03621ba26e4a4e996bc79c3ad3e7d5499
parent5eee65ef075b7cbfd878c7d176988014d1d4f352 (diff)
downloadmpc-git-83975da8b13b867dc5f741b9506799cd0529ef1b.tar.gz
mpcheck: Move the tool from tests/ to its own subdirectory inside tools/.
* tests/mpcheck-*: Move to... * tools/mpcheck/mpcheck-*: ...this. * tests/Makefile.am: Drop all references to mpcheck. * tools/mpcheck/Makefile.am, tools/mpcheck/README: New files. * tools/Makefile.am: Reference the new subdirectory. * configure.ac: Reference tools/mpcheck/Makefile. * Makefile.am: Add a target "mpcheck". * NEWS: Add an item. * doc/version.texi: Spurious update.
-rw-r--r--Makefile.am5
-rw-r--r--NEWS1
-rw-r--r--configure.ac4
-rw-r--r--doc/version.texi8
-rw-r--r--tests/Makefile.am7
-rw-r--r--tools/Makefile.am3
-rw-r--r--tools/mpcheck/Makefile.am31
-rw-r--r--tools/mpcheck/README3
-rw-r--r--tools/mpcheck/mpcheck-common.c (renamed from tests/mpcheck-common.c)0
-rw-r--r--tools/mpcheck/mpcheck-double.c (renamed from tests/mpcheck-double.c)3
-rw-r--r--tools/mpcheck/mpcheck-float.c (renamed from tests/mpcheck-float.c)3
-rw-r--r--tools/mpcheck/mpcheck-float128.c (renamed from tests/mpcheck-float128.c)3
-rw-r--r--tools/mpcheck/mpcheck-longdouble.c (renamed from tests/mpcheck-longdouble.c)3
-rw-r--r--tools/mpcheck/mpcheck-template1.c (renamed from tests/mpcheck-template1.c)0
-rw-r--r--tools/mpcheck/mpcheck-template2.c (renamed from tests/mpcheck-template2.c)0
-rw-r--r--tools/mpcheck/mpcheck-template3.c (renamed from tests/mpcheck-template3.c)0
16 files changed, 57 insertions, 17 deletions
diff --git a/Makefile.am b/Makefile.am
index a286ce7..be2ade6 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,6 @@
## Makefile.am -- Process this file with automake to produce Makefile.in
##
-## Copyright (C) 2008, 2010, 2011, 2012, 2013, 2014 INRIA
+## Copyright (C) 2008, 2010, 2011, 2012, 2013, 2014, 2020 INRIA
##
## This file is part of GNU MPC.
##
@@ -32,3 +32,6 @@ EXTRA_DIST = doc/fdl-1.3.texi src/mpc-log.h Makefile.vc
bench :
cd tools/bench && $(MAKE) $(AM_MAKEFLAGS) bench
+mpcheck :
+ cd tools/mpcheck && $(MAKE) $(AM_MAKEFLAGS) mpcheck
+
diff --git a/NEWS b/NEWS
index 528ad71..b0c2aa6 100644
--- a/NEWS
+++ b/NEWS
@@ -2,6 +2,7 @@ Changes in version xxx:
- New functions: mpc_sum, mpc_dot
- Several functions are more robust with a reduced exponent range
(for example corresponding to IEEE 754 binary formats)
+ - New tool mpcheck.
Changes in version 1.1.0:
- Minimally required library versions: GMP 5.0.0 and MPFR 3.0.0
diff --git a/configure.ac b/configure.ac
index a97485c..9f8069b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
-# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2014, 2016, 2017, 2018 INRIA
+# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2014, 2016, 2017, 2018, 2020 INRIA
#
# This file is part of GNU MPC.
#
@@ -253,5 +253,5 @@ AC_DEFINE_UNQUOTED([MPC_GCC_VERSION], ["$GCC_VERSION"], [Version of gcc])
# Looks for short git hash if the version string contains "dev"
MPC_GITVERSION
-AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile doc/Makefile tools/Makefile tools/bench/Makefile])
+AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile doc/Makefile tools/Makefile tools/bench/Makefile tools/mpcheck/Makefile])
AC_OUTPUT
diff --git a/doc/version.texi b/doc/version.texi
index 56a933c..2fdcf8b 100644
--- a/doc/version.texi
+++ b/doc/version.texi
@@ -1,4 +1,4 @@
-@set UPDATED 11 January 2018
-@set UPDATED-MONTH January 2018
-@set EDITION 1.1.0
-@set VERSION 1.1.0
+@set UPDATED 16 January 2019
+@set UPDATED-MONTH January 2019
+@set EDITION 1.1.1dev
+@set VERSION 1.1.1dev
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 6f6ec61..f211d5c 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -1,6 +1,6 @@
## tests/Makefile.am -- Process this file with automake to produce Makefile.in
##
-## Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2016 INRIA
+## Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2016, 2020 INRIA
##
## This file is part of GNU MPC.
##
@@ -65,10 +65,7 @@ DATA_SETS = abs.dat acos.dat acosh.dat add.dat add_fr.dat arg.dat \
pow_fr.dat pow_si.dat pow_ui.dat pow_z.dat proj.dat rootofunity.dat \
sin.dat sinh.dat \
sqr.dat sqrt.dat strtoc.dat sub.dat sub_fr.dat tan.dat tanh.dat
-EXTRA_DIST = data_check.tpl tgeneric.tpl $(DATA_SETS) $(DESCRIPTIONS) \
- mpcheck-float.c mpcheck-double.c mpcheck-longdouble.c \
- mpcheck-float128.c mpcheck-common.c \
- mpcheck-template1.c mpcheck-template2.c mpcheck-template3.c
+EXTRA_DIST = data_check.tpl tgeneric.tpl $(DATA_SETS) $(DESCRIPTIONS)
LOG_COMPILER = $(VALGRIND)
AM_LOG_FLAGS = $(VALGRIND_OPTS)
diff --git a/tools/Makefile.am b/tools/Makefile.am
index 5730d54..86257e1 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -1,6 +1,7 @@
## tools/Makefile.am -- Process this file with automake to produce Makefile.in
##
## Copyright (C) 2014 CNRS
+## Copyright (C) 2020 INRIA
##
## This file is part of GNU MPC.
##
@@ -17,5 +18,5 @@
## You should have received a copy of the GNU Lesser General Public License
## along with this program. If not, see http://www.gnu.org/licenses/ .
-SUBDIRS = bench
+SUBDIRS = bench mpcheck
diff --git a/tools/mpcheck/Makefile.am b/tools/mpcheck/Makefile.am
new file mode 100644
index 0000000..77ed6b0
--- /dev/null
+++ b/tools/mpcheck/Makefile.am
@@ -0,0 +1,31 @@
+## tools/mpcheck/Makefile.am -- Process this file with automake to produce Makefile.in
+##
+## Copyright (C) 2014 CNRS
+## Copyright (C) 2020 INRIA
+##
+## This file is part of GNU MPC.
+##
+## GNU MPC is free software; you can redistribute it and/or modify it under
+## the terms of the GNU Lesser General Public License as published by the
+## Free Software Foundation; either version 3 of the License, or (at your
+## option) any later version.
+##
+## GNU MPC is distributed in the hope that it will be useful, but WITHOUT ANY
+## WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+## FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for
+## more details.
+##
+## You should have received a copy of the GNU Lesser General Public License
+## along with this program. If not, see http://www.gnu.org/licenses/ .
+
+AM_CPPFLAGS = -I$(top_srcdir)/src
+AM_DEFAULT_SOURCE_EXT = .c
+
+LDADD = $(top_builddir)/src/libmpc.la -lm
+
+BINARIES = mpcheck-float mpcheck-double mpcheck-longdouble mpcheck-float128
+EXTRA_PROGRAMS = $(BINARIES)
+CLEANFILES = $(BINARIES)
+
+mpcheck : $(BINARIES)
+
diff --git a/tools/mpcheck/README b/tools/mpcheck/README
new file mode 100644
index 0000000..f35ff80
--- /dev/null
+++ b/tools/mpcheck/README
@@ -0,0 +1,3 @@
+The mpcheck tool provides tests to check the MPC library against the
+C library. It is meant as a tool for developers.
+
diff --git a/tests/mpcheck-common.c b/tools/mpcheck/mpcheck-common.c
index 0133f2a..0133f2a 100644
--- a/tests/mpcheck-common.c
+++ b/tools/mpcheck/mpcheck-common.c
diff --git a/tests/mpcheck-double.c b/tools/mpcheck/mpcheck-double.c
index ba85952..df216aa 100644
--- a/tests/mpcheck-double.c
+++ b/tools/mpcheck/mpcheck-double.c
@@ -32,6 +32,7 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#define _GNU_SOURCE /* for clog10 */
+#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
@@ -41,7 +42,7 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
-#include "mpc-tests.h"
+#include "mpc.h"
#define PRECISION 53
#define EMAX 1024
diff --git a/tests/mpcheck-float.c b/tools/mpcheck/mpcheck-float.c
index fe3cf77..9e4bdea 100644
--- a/tests/mpcheck-float.c
+++ b/tools/mpcheck/mpcheck-float.c
@@ -32,13 +32,14 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#define _GNU_SOURCE /* for clog10 */
+#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
#include <sys/types.h>
#include <unistd.h>
#include <assert.h>
-#include "mpc-tests.h"
+#include "mpc.h"
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
diff --git a/tests/mpcheck-float128.c b/tools/mpcheck/mpcheck-float128.c
index 7b8f495..ba08efd 100644
--- a/tests/mpcheck-float128.c
+++ b/tools/mpcheck/mpcheck-float128.c
@@ -32,6 +32,7 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#define _GNU_SOURCE /* for clog10 */
+#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
@@ -39,7 +40,7 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
#include <unistd.h>
#include <assert.h>
#define MPFR_WANT_FLOAT128
-#include "mpc-tests.h"
+#include "mpc.h"
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
diff --git a/tests/mpcheck-longdouble.c b/tools/mpcheck/mpcheck-longdouble.c
index 3dc1688..6f7aefc 100644
--- a/tests/mpcheck-longdouble.c
+++ b/tools/mpcheck/mpcheck-longdouble.c
@@ -32,13 +32,14 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#define _GNU_SOURCE /* for clog10 */
+#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
#include <sys/types.h>
#include <unistd.h>
#include <assert.h>
-#include "mpc-tests.h"
+#include "mpc.h"
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
diff --git a/tests/mpcheck-template1.c b/tools/mpcheck/mpcheck-template1.c
index ee56e01..ee56e01 100644
--- a/tests/mpcheck-template1.c
+++ b/tools/mpcheck/mpcheck-template1.c
diff --git a/tests/mpcheck-template2.c b/tools/mpcheck/mpcheck-template2.c
index 7a2a8c0..7a2a8c0 100644
--- a/tests/mpcheck-template2.c
+++ b/tools/mpcheck/mpcheck-template2.c
diff --git a/tests/mpcheck-template3.c b/tools/mpcheck/mpcheck-template3.c
index e6718a8..e6718a8 100644
--- a/tests/mpcheck-template3.c
+++ b/tools/mpcheck/mpcheck-template3.c