diff -r -u mpfrcpp-1.4.2/doc/.XML/installation.xml mpfrcpp/doc/.XML/installation.xml --- mpfrcpp-1.4.2/doc/.XML/installation.xml 2007-06-10 22:35:04.000000000 +0200 +++ mpfrcpp/doc/.XML/installation.xml 2009-04-13 02:31:19.000000000 +0200 @@ -10,12 +10,24 @@

GMP should be made with C++ features support.

-

GMP and MPFR come with GNU Automake files and documentation on installation on GNU system. If you are using Microsoft Windows, you could try GMP and MPFR port for Microsoft Visual Studio 2005 by Brian Gladman.

- -

To use MPFRCPP you need to place sources in the mpfrcpp and nacre subdirectories of some root directory of compiler include path (/usr/include/ or /usr/local/include/).

- -

The only one file you need to embed in static library is mpfrcpp/initialization.cpp. However it is optional and you could drop it if you want to drop pre-defined MPFRCPP global objects.

+

GMP and MPFR come with GNU Automake files and documentation on installation on GNU systems. +If you are using Microsoft Windows, you could try +GMP and MPFR port for Microsoft Visual Studio 2005 +by Brian Gladman.

+ +

To install MPFRCPP proper, run make; make install in this directory.

+ +

The installtion needs to copy the src/mpfrcpp and src/nacre directories +to some root directory of the compiler's include path +(/usr/include/ or /usr/local/include/). +You can control the location by setting the PREF variable in the makefile. +

+ +

The only one file you need to embed in a static library is mpfrcpp/initialization.cpp. +However, it is optional, and you could drop it if you want to drop pre-defined MPFRCPP global objects. +See Interface.

+

To uninstall, find the copy of the Makefile in $(PREF)/share/doc/mpfrcpp, and run uninstall.

diff -r -u mpfrcpp-1.4.2/examples/quick_start.cpp mpfrcpp/examples/quick_start.cpp --- mpfrcpp-1.4.2/examples/quick_start.cpp 2007-05-11 03:53:59.000000000 +0200 +++ mpfrcpp/examples/quick_start.cpp 2009-04-11 18:28:39.000000000 +0200 @@ -36,7 +36,7 @@ int main () { internal::copyleft(); Library.setPrecision( Precision( 200 ) ); - cout << "Example of calculating a lower bound on 1 + 1/2! + ... + 1/100! with precision " + cout << "Example of calculating a lower bound on 1 + 1/1! + 1/2! + ... + 1/100! with precision " << Library.getPrecision().getMpfrPrecT () << endl; cout << endl; diff -r -u mpfrcpp-1.4.2/Makefile mpfrcpp/Makefile --- mpfrcpp-1.4.2/Makefile 2007-08-18 04:01:42.000000000 +0200 +++ mpfrcpp/Makefile 2009-04-13 02:25:54.000000000 +0200 @@ -20,6 +20,13 @@ OPTIONS = -lmpfrcpp -lgmp -lmpfr --pedantic --std=c++98 -Wall CC = g++ +PREF=/usr/local +includedir = $(PREF)/include +docdir = $(PREF)/share/doc +libdir = $(PREF)/lib + +logfile = check.log + testdir = test/ exampledir = examples/ @@ -28,15 +35,13 @@ binpostfix = -includedir = /usr/local/include -docdir = /usr/share/doc -libdir = /usr/local/lib +all: -logfile = check.log + cd src/mpfrcpp; make -install : +install : all - cd src/mpfrcpp; make; mv *.a $(libdir) + cd src/mpfrcpp; mv *.a $(libdir) rm -rf $(includedir)/mpfrcpp mkdir $(includedir)/mpfrcpp @@ -47,8 +52,16 @@ cp -r src/nacre/* $(includedir)/nacre rm -rf $(docdir)/mpfrcpp - mkdir $(docdir)/mpfrcpp + mkdir -p $(docdir)/mpfrcpp cp -r doc/* $(docdir)/mpfrcpp + cp ./Makefile $(docdir)/mpfrcpp + +uninstall : + + rm -f $(libdir)/libmpfr.a + rm -rf $(includedir)/mpfrcpp + rm -rf $(includedir)/nacre + rm -rf $(docdir)/mpfrcpp check : @@ -111,7 +124,7 @@ ./$(exampleprefix)nacre_polynomial$(binpostfix) >> $(logfile) ./$(exampleprefix)nacre_polynomial_roots$(binpostfix) >> $(logfile) ./$(exampleprefix)serialization$(binpostfix) >> $(logfile) - cd $(exampledir); ../$(exampleprefix)gauss-legendre$(binpostfix) >> $(logfile) + (cd $(exampledir); ../$(exampleprefix)gauss-legendre$(binpostfix)) >> $(logfile) ./$(testprefix)separate_compilation$(binpostfix) >> $(logfile) # rm $(exampleprefix)*$(binpostfix) $(testprefix)*$(binpostfix) diff -r -u mpfrcpp-1.4.2/src/mpfrcpp/real/to_string.hpp mpfrcpp/src/mpfrcpp/real/to_string.hpp --- mpfrcpp-1.4.2/src/mpfrcpp/real/to_string.hpp 2007-06-10 21:40:02.000000000 +0200 +++ mpfrcpp/src/mpfrcpp/real/to_string.hpp 2009-04-11 18:06:23.000000000 +0200 @@ -34,6 +34,7 @@ #include #include #include +#include namespace mpfr {