Bill Allombert on Fri, 12 Nov 2010 19:41:44 +0100


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

cross-gp2c for mingw on linux


Hello PARI-dev,

I managed to configure gp2c on linux so that gp2c-run build mingw DLLs. This works except for the
'install' test (I will try to fix that). I suppose that means that gp2c can work on mingw.

Here a quick summary:

First start by reading:
<http://pari.math.u-bordeaux.fr/archives/pari-dev-0912/msg00013.html>

Start by cross-compiling pari
1) run Configure as follow:
RUNTEST=/path/to/runwine CC=i586-mingw32msvc-gcc ./Configure --host=i586-mingw --prefix=$HOME/mingw
2) compile:
make gp -C Omingw-i586
3) test:
make bench -C Omingw-i586
4) install
make install -C Omingw-i586

Build GP2C:
1) run configure
./configure --with-paricfg=$HOME/mingw/lib/pari/pari.cfg
2) compile
make
3) test:
make check
(currently it stops at install which fails)
4) use: to compile foo.gp:
GP=true ./gp2c-run foo.gp
You get a file 'foo.gp.so' which a mingw DLL.
(You can try it in wine:
GP="wine $HOME/mingw/bin/gp" ./gp2c-run foo.gp

Cheers,
Bill.