version 1.4, 2000/01/08 18:30:18 |
version 1.28, 2021/03/25 03:02:40 |
|
|
# $OpenXM: OpenXM/src/pari/Makefile,v 1.3 2000/01/08 18:25:36 maekawa Exp $ |
# $OpenXM: OpenXM/src/pari/Makefile,v 1.27 2020/08/26 06:03:31 noro Exp $ |
|
|
PARI = ../../../OpenXM_contrib/pari |
OpenXM_HOME=../.. |
CURDIR = ../../OpenXM/src/pari |
PREFIX=${OpenXM_HOME} |
BINDIR = ../../bin |
DISTDIR=${OpenXM_HOME}/../OpenXM_dist |
|
RM = /bin/rm |
|
RANLIB=ranlib |
|
PARI=pari-2.11.4 |
|
PATCH_FILE=${PARI}.diff |
|
MASTER_SITE=http://www.math.kobe-u.ac.jp/pub/OpenXM/misc/ |
|
DIST_SUFFIX=.tar.gz |
|
DISTFILES=${PARI}${DIST_SUFFIX} |
|
GALFILES=galdata.tgz galpol.tgz |
|
|
all: configure |
all: build |
@if [ ! -f ./.make_done ]; then \ |
|
(cd $(PARI) ; make all) \ |
fetch: |
|
-mkdir work |
|
@if [ ! -f work/.fetch_done ]; then \ |
|
for i in ${DISTFILES} ${GALFILES}; do \ |
|
${OpenXM_HOME}/bin/oxfetch.sh ${MASTER_SITE}"$$i" ${DISTDIR}; \ |
|
done; \ |
|
fi |
|
@touch work/.fetch_done |
|
|
|
extract: fetch |
|
@if [ ! -f work/.extract_done ]; then \ |
|
cat ${DISTDIR}/${DISTFILES} | (cd work ; tar xzvf -) ; \ |
|
for i in ${GALFILES}; do \ |
|
cat ${DISTDIR}/"$$i" | (cd work/${PARI} ; tar xzvf -) ; \ |
|
done; \ |
|
fi |
|
@touch work/.extract_done |
|
|
|
patch: extract |
|
@if [ ! -f work/.patch_done ]; then \ |
|
if [ -f "${PATCH_FILE}" ]; then \ |
|
cat ${PATCH_FILE} | (cd work/${PARI} ; patch -p1 ) ; \ |
|
fi \ |
|
fi |
|
@touch work/.patch_done |
|
|
|
configure: patch |
|
@if [ ! -f work/.configure_done ]; then \ |
|
prefix=`cd ${OpenXM_HOME}; pwd` ; \ |
|
(cd work/${PARI} ; ./Configure --prefix="$$prefix" ) ; \ |
fi |
fi |
@touch ./.make_done |
@touch work/.configure_done |
|
|
install: all |
build: configure |
@if [ ! -f ./.install_done ]; then \ |
@if [ ! -f work/.build_done ]; then \ |
(cd $(PARI) ; make install install-lib-sta) \ |
d=`cd work/${PARI} ; config/objdir` ; \ |
|
(cd work/${PARI}/$$d ; ${MAKE} lib-sta; ${MAKE} gp) ; \ |
fi |
fi |
@touch ./.install_done |
@touch work/.build_done |
|
|
clean: |
build-doc: configure |
@if [ -f ./.make_done ]; then \ |
@if [ ! -f work/.build_doc_done ]; then \ |
(cd $(PARI) ; make clean) \ |
(cd work/${PARI} ; ${MAKE} doc) ; \ |
fi |
fi |
@rm -f ./.make_done ./.configure_done |
@touch work/.build_doc_done |
|
|
distclean: |
install: build |
rm -rf ../../lib/libpari.* ../../lib/pari |
-mkdir ${PREFIX}/bin ${PREFIX}/lib |
rm -rf ../../include/pari |
@if [ ! -f work/.install_done ]; then \ |
rm -rf $(BINDIR)/gp $(BINDIR)/gp-2.0 |
d=`cd work/${PARI} ; config/objdir` ; \ |
@rm -f ./.install_done |
(cd work/${PARI}/$$d ; ${MAKE} install-lib-sta install-include install-lib-dyn install-data) ; \ |
|
${RANLIB} ${PREFIX}/lib/libpari.a ; \ |
|
fi |
|
@touch work/.install_done |
|
|
configure: |
install-doc: build-doc |
@if [ ! -f ./.configure_done ]; then \ |
-mkdir ${PREFIX}/doc/pari |
(cd $(PARI) ; ./Configure --prefix=../../../OpenXM) \ |
@if [ ! -f work/.install_doc_done ]; then \ |
|
for i in users.dvi tutorial.dvi; do \ |
|
cp work/${PARI}/doc/$$i ${PREDIX}/doc/pari ; \ |
|
done ; \ |
fi |
fi |
@touch ./.configure_done |
@touch work/.install_doc_done |
|
|
|
clean: |
|
-${RM} -rf work |
|
|
|
distclean: clean |