[BACK]Return to README.WIN CVS log [TXT][DIR] Up to [local] / OpenXM_contrib / pari-2.2

File: [local] / OpenXM_contrib / pari-2.2 / Attic / README.WIN (download)

Revision 1.1, Tue Oct 2 11:16:55 2001 UTC (22 years, 7 months ago) by noro
Branch: MAIN

Initial revision

This file describes the various ways you can run PARI/GP in a win32 environment
(Windows 95,98,2000,NT). For earlier versions of Windows, see README.DOS.

WARNING: The only way to have a fully functional GP is to install GNU/Linux.
It's a one hour job to install a minimal Linux system from current Linux
distributions. The LILO boot system enables you to have Windows and Linux
coexisting peacefully on your hard drive, so you can have the best of both
worlds. The other solutions all stick to the Windows environment, suffer from
various problems, and are discussed in the rest of this document.

It is also advised, but not mandatory to get the Documentation and Examples
archive

  ftp://megrez.math.u-bordeaux.fr/pub/pari/dos/GPDxxx.ZIP

which contains the following directories:

  + DOC, containing
     - user's manual, tutorial and reference card in TeX format You will
       need TeX to compile them (see www.CTAN.org for how to get TeX). The
       same documents are available in PDF and PostScript format from

         ftp://megrez.math.u-bordeaux.fr/pub/pari/manuals/

       (and so is the "readline" reference manual if you use one of the
        solutions providing line editing)

     - the script GPHELP (translates Pari documentation to plain text and
       handles "apropos help"), which requires PERL (see www.CPAN.org for how
       to get it). You may have to fix paths in the first lines of the script.
       Set your GPRC file so that the 'help' default points to the place where
       you deposit GPHELP (see MISC/GPRC.DOS).

  + MISC, containing
      - a sample GPRC file (GPRC.DOS). Copy it to C:\_GPRC (or \etc\GPRC) and
        adapt it to your needs
      - a sample alias file (GPALIAS).

  + EXAMPLES, containing sample GP scripts, and a sample INPUTRC file (for
    readline, you can use it to customize GP line editing).

NOTE: all .gz and .ZIP files are compressed files (or archives). Extract them
[ with Winzip (see www.winzip.com) for instance ] once you have downloaded them.

%%%%%%%%%%%%%  Solution 1: The CYGWIN library  %%%%%%%%%%%%%%%%%%%%%%%%

This is the preferred solution, but it requires fetching the cygwin
compatibility library first. We provide this file as 

  ftp://megrez.math.u-bordeaux.fr/pub/pari/windows/cygwin/cygwin1.dll.gz

(size: 268k, 600k uncompressed). It needs to be downloaded only once.
Then fetch the GP binary

  ftp://megrez.math.u-bordeaux.fr/pub/pari/windows/cygwin/gp-xxx.exe.gz
 
and put it in the same directory as the dll (or dump the dll somewhere in
your PATH, as you prefer).

PROBLEMS:
  * no hi-res plots, most graphics commands disabled (you can still output to
    a PostScript file)

NOTE: you might wish to download the full cygwin distribution from
http://sources.redhat.com/cygwin/ [ the Download and Installation process is
automated and quite simple, you should be home in a few mouse clicks...
provided your internet connection is good enough. ]. It provides a neat
gcc-based development environment under Windows, under which most Unix
packages can easily be ported. In particular you will be able to build GP
from the generic (unix) sources.


%%%%%%%%%%%%%  Solution 2: The native (mingw) binary %%%%%%%%%%%%%%%%%

Fetch the GP binary (cross-compiled using the gcc-mingw compiler):
EITHER

  ftp://megrez.math.u-bordeaux.fr/pub/pari/windows/gp-xxx.exe.gz
(includes readline line-editing, history, keyword completion, facilities)

OR

  ftp://megrez.math.u-bordeaux.fr/pub/pari/windows/gp-norl-xxx.exe.gz
(doesn't include readline).

PROBLEMS:
  * no hi-res plots, most graphics commands disabled (you can still output to
    a PostScript file)

  * doesn't work well when started in a console from a MS-DOS shell:
      - on ^C gp quits
      - redirecting standard input as in 'gp < file' crashes gp

    SOLUTION: None of these things occur if you start gp by double-clicking
    on its icon, as is customary for Windows application. ^C still doesn't
    always interrupt computations, but at least it doesn't kill gp.

  * colors don't work (escape sequences printed "as is").
 
  * no extended on-line help

  * [readline binary only]: the AltGr key doesn't work. If you have a US
    keyboard, you don't care. But if you have, e.g a French keyboard, you
    won't be able to produce {}, [], \, ...

    SOLUTION:
      create an INPUTRC file for readline (cf user's manual or readline
      manual). E.g add a line 

      set INPUTRC=C:\INPUTRC.txt  (for instance).

    to your AUTOEXEC.BAT. Then create this file, and add lines of the form

    "\M-\\": "\\"   (\M stands for ALT or META, \C for CONTROL)
    "\M-\[": "["

    etc... This binds (for readline purposes only, doesn't affect regular
    Windows operations) the key sequence on the LHS, to some "meaning" on the
    RHS, here an ordinary character. E.g inserting a line

    "a": "b"

    will cause GP to insert a "b" when you type an "a". Depending on your
    precise keyboard layout, you may have to fiddle a bit with the keyseq and
    replacement text before getting something sensible.

%%%%%%%%%%%%%  Solution 3: The RSX runtime package %%%%%%%%%%%%%%%%%%%

You can use the GP binary from the archive

  ftp://megrez.math.u-bordeaux.fr/pub/pari/dos/GPBxxx.ZIP

PROBLEMS:
  * no hi-res plots, most graphics commands disabled (you can still output to
    a PostScript file).

  * more than twice SLOWER than all the other binaries described here.

%%%%%%%%%%%%%  Solution 4: Build GP from sources   %%%%%%%%%%%%%%%%%%%

That is, the generic Unix sources

  ftp://megrez.math.u-bordeaux.fr/pub/pari/pari.tgz

It is quite easy to build (or cross-build) GP and readline from the unix
sources using mingw, but if you have installed mingw you probably also have
Cygwin, in which case it's even easier to use the generic build process as
under Unix, as mentioned in Solution 1. IMPORTANT NOTE: you have to type
"make gp-sta" since Configure defaults to building the dynamic version, which
doesn't work (see below) [this is a bug in Configure].

So I'm assuming from now on that you're stuck with something which is not
gcc. If you have MSVC, then check Odos/README.MSVC in the archive which
explains in detail all steps involved. If you have some other compiler, and
succeed in compiling GP, we'd be quite happy to hear from you.

PROBLEMS:
  * no hi-res plots, most graphics commands disabled (you can still output to
    a PostScript file).

  * slower than all gcc-compiled binaries (faster than RSX version though).

  * no extended on-line help

  * no line-editing facilities (GP not linked with readline).

%%%%%%%%%%%%%  What about library programming ? %%%%%%%%%%%%%%%%%%%%%%

Building a static LIBPARI.A Library should be straightforward. It is possible
but painful to build a LIBPARI.DLL and .def file using gcc-mingw (or
gcc-cygwin) + dlltool and some header magic; but GP itself, when linked with
such a library, crashes on startup.  No other decent compiler being available
to us, we won't provide prebuilt libraries. For this one, you're on your own.
Sorry.