=================================================================== RCS file: /home/cvs/OpenXM/src/pari/Makefile,v retrieving revision 1.15 retrieving revision 1.25 diff -u -p -r1.15 -r1.25 --- OpenXM/src/pari/Makefile 2001/12/27 08:31:38 1.15 +++ OpenXM/src/pari/Makefile 2017/03/31 03:17:59 1.25 @@ -1,66 +1,29 @@ -# $OpenXM: OpenXM/src/pari/Makefile,v 1.14 2001/12/27 07:16:01 noro Exp $ +# $OpenXM: OpenXM/src/pari/Makefile,v 1.24 2017/03/31 02:18:33 takayama Exp $ -PARI = ../../../OpenXM_contrib/pari-2.2 -OpenXM_ROOT = ../../../OpenXM +# Choose one of pari version. +# Example. +# $ make install ( for PARI/GP 2.0.x) +# $ make PARI_VER=2.2 install ( for PARI/GP 2.2.x) -all: configure - @if [ ! -f ./.make_done ]; then \ - if [ "`uname | sed -e 's/_.*$$//'`" = "CYGWIN" ]; then\ - (cd $(PARI)/O*-* ; make lib-sta); \ - else \ - (cd $(PARI) ; make all); \ - fi \ - fi - @touch ./.make_done +#PARI_VER=2.0 +#PARI_VER=2.2 +PARI_VER=2.3 -install: install-lib-bin +## for PARI/GP unstable (2.2) +PARI_DEVEL_VER=pari-2.2.8.alpha +PARI_DEVEL_SUFFIX=.tar.gz -install-lib-bin: all install-lib - (cd $(PARI)/O*-* ; make install-include) - if [ "`uname | sed -e 's/_.*$$//'`" != "CYGWIN" ]; then \ - (cd $(PARI)/O*-* ; make install-lib-dyn); \ - (cd $(PARI)/O*-* ; make install-bin); \ - (cd $(PARI)/O*-* ; make install-misc); \ - (cd $(PARI)/O*-* ; make install-man); \ - (cd $(PARI)/O*-* ; make install-data); \ - fi +## for PARI/GP unstable (2.2) +PARI_23_VER=pari-2.3.4 +PARI_23_SUFFIX=.tar.gz +all: build -install-doc: all - (cd $(PARI) ; make doc) - @if [ ! -d $(OpenXM_ROOT)/doc/pari ]; then \ - mkdir $(OpenXM_ROOT)/doc/pari ;\ +fetch extract patch configure build build-doc install install-doc clean distclean: + @if [ "${PARI_VER}" = 2.3 ]; then \ + ${MAKE} -f Makefile.2.0 PARI=${PARI_23_VER} DIST_SUFFIX=${PARI_23_SUFFIX} PATCH_FILE=${PARI_DEVEL_VER}.diff $@ ; \ + elif [ "${PARI_VER}" = 2.2 ]; then \ + ${MAKE} -f Makefile.2.0 PARI=${PARI_DEVEL_VER} DIST_SUFFIX=${PARI_DEVEL_SUFFIX} $@ ; \ + else \ + ${MAKE} -f Makefile.2.0 $@ ; \ fi - -cp $(OpenXM_ROOT)/lib/pari/users.dvi $(OpenXM_ROOT)/doc/pari/users.dvi - -cp $(OpenXM_ROOT)/lib/pari/tutorial.dvi $(OpenXM_ROOT)/doc/pari/tutorial.dvi - -clean: patch-clean - @if [ -f ./.make_done ]; then \ - (cd $(PARI) ; make clean) \ - fi - @rm -f ./.make_done ./.configure_done - -distclean: - @cat BINARIES | xargs -t rm -rf - -configure: patch - @if [ ! -f ./.configure_done ]; then \ - (cd $(PARI) ; ./Configure --prefix=../../../OpenXM) \ - fi - @touch ./.configure_done - -patch: - @if [ ! -f ./.patch_done ]; then \ - (cd $(PARI)/config ; patch < ../../../OpenXM/src/pari/Makefile.SH.diff) \ - fi - @touch ./.patch_done - -patch-clean: - @if [ -f ./.patch_done ]; then \ - (cd $(PARI)/config ; patch -R < ../../../OpenXM/src/pari/Makefile.SH.diff) \ - fi - @rm -f ./.patch_done - -install-lib: all - (cd $(PARI) ; make install-lib-sta) - ranlib ../../lib/libpari-2.2.a