| 1 |
Copyright 2001, 2003, 2004 Free Software Foundation, Inc. |
| 2 |
|
| 3 |
This file is part of the GNU MP Library. |
| 4 |
|
| 5 |
The GNU MP Library is free software; you can redistribute it and/or modify |
| 6 |
it under the terms of either: |
| 7 |
|
| 8 |
* the GNU Lesser General Public License as published by the Free |
| 9 |
Software Foundation; either version 3 of the License, or (at your |
| 10 |
option) any later version. |
| 11 |
|
| 12 |
or |
| 13 |
|
| 14 |
* the GNU General Public License as published by the Free Software |
| 15 |
Foundation; either version 2 of the License, or (at your option) any |
| 16 |
later version. |
| 17 |
|
| 18 |
or both in parallel, as here. |
| 19 |
|
| 20 |
The GNU MP Library is distributed in the hope that it will be useful, but |
| 21 |
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY |
| 22 |
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
| 23 |
for more details. |
| 24 |
|
| 25 |
You should have received copies of the GNU General Public License and the |
| 26 |
GNU Lesser General Public License along with the GNU MP Library. If not, |
| 27 |
see https://www.gnu.org/licenses/. |
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
GMP PERL MODULE INSTALLATION |
| 34 |
|
| 35 |
|
| 36 |
This module can be compiled within the GMP source directory or moved |
| 37 |
elsewhere and compiled. An installed GMP can be used, or a specified |
| 38 |
GMP build tree. Both static and shared GMP builds will work. |
| 39 |
|
| 40 |
The simplest case is when GMP has been installed to a standard system |
| 41 |
location |
| 42 |
|
| 43 |
perl Makefile.PL |
| 44 |
make |
| 45 |
|
| 46 |
If not yet installed then the top-level GMP build directory must be |
| 47 |
specified |
| 48 |
|
| 49 |
perl Makefile.PL GMP_BUILDDIR=/my/gmp/build |
| 50 |
make |
| 51 |
|
| 52 |
In any case, with the module built, the sample program provided can be |
| 53 |
run |
| 54 |
|
| 55 |
perl -Iblib/arch sample.pl |
| 56 |
|
| 57 |
If you built a shared version of libgmp but haven't yet installed it, |
| 58 |
then it might be necessary to add a run-time path to it. For example |
| 59 |
|
| 60 |
LD_LIBRARY_PATH=/my/gmp/build/.libs perl -Iblib/arch sample.pl |
| 61 |
|
| 62 |
Documentation is provided in pod format in GMP.pm, and will have been |
| 63 |
"man"-ified in the module build |
| 64 |
|
| 65 |
man -l blib/man3/GMP.3pm |
| 66 |
or |
| 67 |
man -M`pwd`/blib GMP |
| 68 |
|
| 69 |
A test script is provided, running a large number of more or less |
| 70 |
trivial checks |
| 71 |
|
| 72 |
make test |
| 73 |
|
| 74 |
The module and its documentation can be installed in the usual way |
| 75 |
|
| 76 |
make install |
| 77 |
|
| 78 |
This will be into /usr/local or wherever the perl Config module |
| 79 |
directs, but that can be controlled back at the Makefile.PL stage with |
| 80 |
the usual ExtUtils::MakeMaker options. |
| 81 |
|
| 82 |
Once installed, programs using the GMP module become simply |
| 83 |
|
| 84 |
perl sample.pl |
| 85 |
|
| 86 |
And the documentation read directly too |
| 87 |
|
| 88 |
man GMP |