Annotation of OpenXM_contrib2/asir2000/Makefile.am, Revision 1.25
1.25 ! saito 1: ## $OpenXM: OpenXM_contrib2/asir2000/Makefile.am,v 1.24 2007/02/18 08:46:47 ohara Exp $
1.1 ohara 2:
3: AUTOMAKE_OPTIONS = foreign no-dependencies 1.5
4: if USE_PLOT
5: PLOTDIR = plot
6: PLLIB = plot/libplot.a
1.10 ohara 7: X11LIB = @X_LIBS@ -lXaw -lXmu -lXt @X_PRE_LIBS@ @XPMLIB@ -lXext -lX11 @X_EXTRA_LIBS@
1.1 ohara 8: endif
9:
10: SUBDIRS = asm builtin engine fft include io lib parse ${PLOTDIR}
11:
1.17 ohara 12: asirdir = ${libdir}/asir
13: asir_PROGRAMS = asir
14: asir_SOURCES = parse/main.c
15: asir_LDADD = libasir.a libasir-gc.a
16: CLEANFILES = ${asir_LDADD} asir-openxm-${VERSION}.tgz
17:
1.24 ohara 18: GC = gc6.8
1.22 ohara 19: GC_TAR_GZ = ${GC}.tar.gz
1.25 ! saito 20: GC_PATCH = gc6.5-risa.diff
1.22 ohara 21: GC_DISTDIR = @GC_DISTDIR@
22: GC_MASTER_SITE=ftp://ftp.math.kobe-u.ac.jp/pub/OpenXM/misc/
23: OX_FETCH = ${bindir}/oxfetch.sh
1.21 noro 24:
1.17 ohara 25: DEFS = @DEFS@ -DASIR_LIBDIR=\"${asirdir}\"
1.1 ohara 26: INCLUDES = -I${top_srcdir}/include -I${top_srcdir}/parse -I${top_srcdir}/io \
1.22 ohara 27: -I${top_srcdir}/${GC}/include \
1.1 ohara 28: @PARIINC@ @MPIINC@ @X_CFLAGS@
29:
30: GLIB = libasir-gc.a
31: ALIB = asm/libasm.a
32: BLIB = builtin/libfunc.a
33: ELIB = engine/libca.a
34: FLIB = fft/libdft.a
35: IOLIB = io/libio.a
36: PLIB = parse/libparse.a
37:
38: ASIRLIB = ${BLIB} ${PLIB} ${IOLIB} ${PLLIB} ${ELIB} ${FLIB} ${ALIB}
39: LIBS = @LIBS@ @PARILIB@ @MPILIB@ @LAPACKLIB@ ${X11LIB} ${FEPLIB} -lm ${EXTRALIBS}
40: # EXTRALIBS = @EXTRALIBS@
41:
42: umain.o: parse/main.c
43: ${COMPILE} -DUINIT main.c -o umain.o
44:
1.25 ! saito 45: libasir-gc.a: ${GC_PATCH} parse/gc_risa.c
1.22 ohara 46: -if [ ! -f ${top_srcdir}/.gc_fetch_done ]; then \
47: if [ ! -f ${GC_DISTDIR}/${GC_TAR_GZ} ]; then \
48: ${OX_FETCH} ${GC_MASTER_SITE}${GC_TAR_GZ} ${GC_DISTDIR}; \
49: fi ; \
50: touch ${top_srcdir}/.gc_fetch_done ; \
51: fi
52: -if [ ! -f ${top_srcdir}/.gc_risa_done ]; then \
1.23 ohara 53: (cd ${top_srcdir}; tar xzvf ${GC_DISTDIR}/${GC_TAR_GZ}) ; \
1.25 ! saito 54: (cd ${top_srcdir}/${GC}; patch -p1 < ../${GC_PATCH}) ; \
1.22 ohara 55: touch ${top_srcdir}/.gc_risa_done ; \
1.21 noro 56: fi
1.11 ohara 57: -if [ "${USE_GC_ZEROPAGE}" = yes \
1.22 ohara 58: -a ! -f ${top_srcdir}/${GC}/.patch_gc_zeropage_done ]; then \
59: (cd ${top_srcdir}/${GC}; patch < ../gc_zeropage.diff) ; \
60: touch ${top_srcdir}/${GC}/.patch_gc_zeropage_done ; \
1.19 ohara 61: fi
62: -if [ "${USE_GC_INTERIX}" = yes \
1.22 ohara 63: -a ! -f ${top_srcdir}/${GC}/.patch_gc_interix_done ]; then \
64: (cd ${top_srcdir}/${GC}; patch -p0 < ../gc_interix.diff) ; \
65: touch ${top_srcdir}/${GC}/.patch_gc_interix_done ; \
1.20 ohara 66: fi
67: -if [ "${USE_GC_SPARC64}" = yes \
1.22 ohara 68: -a ! -f ${top_srcdir}/${GC}/.patch_gc_sparc64_done ]; then \
69: (cd ${top_srcdir}/${GC}; patch -p0 < ../gc_sparc64.diff) ; \
70: touch ${top_srcdir}/${GC}/.patch_gc_sparc64_done ; \
1.11 ohara 71: fi
1.22 ohara 72: -if [ ! -f ${top_srcdir}/${GC}/.configure_done ]; then \
1.12 ohara 73: if [ -n "${host_alias}" ]; then \
1.22 ohara 74: (cd ${top_srcdir}/${GC}; ./configure --host=${host_alias} --disable-threads) ; \
1.12 ohara 75: else \
1.22 ohara 76: (cd ${top_srcdir}/${GC}; ./configure --disable-threads) ; \
1.12 ohara 77: fi ; \
1.22 ohara 78: touch ${top_srcdir}/${GC}/.configure_done ; \
1.1 ohara 79: fi
1.22 ohara 80: (cd ${top_srcdir}/${GC}; ${MAKE})
81: cp ${top_srcdir}/${GC}/.libs/libgc.a ${GLIB}
1.13 ohara 82: (cd ${top_srcdir}/parse; ${MAKE} gc_risa.o)
83: ${AR} q ${GLIB} ${top_srcdir}/parse/gc_risa.o
84: ${RANLIB} ${GLIB}
1.1 ohara 85:
86: libasir.a: ${ASIRLIB}
87: -mkdir ${top_srcdir}/libtmp
88: -rm -f ${top_srcdir}/libtmp/* ${top_srcdir}/$@
89: for i in ${ASIRLIB}; do (cd ${top_srcdir}/libtmp; ar x ../$$i; chmod 644 *) done
90: (cd ${top_srcdir}/libtmp; ${AR} cq ../$@ *.o)
91: (cd ${top_srcdir}; ${RANLIB} $@)
92: -rm -rf ${top_srcdir}/libtmp
93:
94: #asir.o: umain.o ${ASIRLIB} ${GLIB}
95: # -rm $@
96: # ld -r $@ umain.o ${ASIRLIB} ${GLIB} ${LIBS} ${EXTRALIBS}
97:
1.3 ohara 98: install-libasir: libasir.a
1.17 ohara 99: mkdir -p ${DESTDIR}${libdir}
100: ${INSTALL_DATA} libasir.a ${DESTDIR}${libdir}/libasir${libasir_postfix}.a
1.4 ohara 101:
1.18 ohara 102: install-libasir-gc: libasir-gc.a
103: mkdir -p ${DESTDIR}${libdir}
104: ${INSTALL_DATA} libasir-gc.a ${DESTDIR}${libdir}/libasir-gc.a
105:
106: install-openxm: asir${EXEEXT} install-libasir install-libasir-gc
1.17 ohara 107: -mkdir -p ${DESTDIR}${bindir}
108: ${INSTALL_PROGRAM} asir ${DESTDIR}${bindir}
109: -mkdir -p ${DESTDIR}${asirdir}
1.4 ohara 110: (cd ${top_srcdir}/lib; ${MAKE} install-doc install-lib)
1.17 ohara 111: -rm -f ${DESTDIR}${bindir}/ox_asir${EXEEXT}
112: (cd ${DESTDIR}${bindir} ; ${LN_S} asir${EXEEXT} ox_asir${EXEEXT})
113: -(cd ${DESTDIR}${asirdir}; \
1.5 ohara 114: rm -f asir${EXEEXT} ox_asir${EXEEXT} ox_launch${EXEEXT} ox_plot${EXEEXT})
1.17 ohara 115: (cd ${DESTDIR}${asirdir} ; \
1.5 ohara 116: ${LN_S} ../../bin/asir${EXEEXT} asir${EXEEXT} ; \
117: ${LN_S} asir${EXEEXT} ox_asir${EXEEXT} ; \
118: ${LN_S} asir${EXEEXT} ox_launch${EXEEXT} ; \
119: ${LN_S} asir${EXEEXT} ox_plot${EXEEXT})
1.7 ohara 120: (cd ${top_srcdir}/include; ${MAKE} install)
1.8 ohara 121: (cd ${top_srcdir}/parse; ${MAKE} install)
1.4 ohara 122:
123: install-lib:
124: (cd ${top_srcdir}/lib; ${MAKE} install-lib)
1.17 ohara 125: -(cd ${DESTDIR}${asirdir}; \
1.6 ohara 126: rm -f ox_asir${EXEEXT} ox_launch${EXEEXT} ox_plot${EXEEXT})
1.17 ohara 127: (cd ${DESTDIR}${asirdir} ; \
1.4 ohara 128: ${LN_S} asir${EXEEXT} ox_asir${EXEEXT} ; \
129: ${LN_S} asir${EXEEXT} ox_launch${EXEEXT} ; \
130: ${LN_S} asir${EXEEXT} ox_plot${EXEEXT})
1.17 ohara 131: -mkdir -p ${DESTDIR}${bindir}
132: -rm -f ${DESTDIR}${bindir}/asir${EXEEXT}
133: (cd ${DESTDIR}${bindir} ; ${LN_S} ../lib/asir/asir${EXEEXT} asir${EXEEXT})
1.4 ohara 134:
135: install-doc:
136: (cd ${top_srcdir}/lib; ${MAKE} install-doc)
1.16 ohara 137:
138: tarball:
139: -rm -rf tmp
140: -mkdir tmp
141: DESTDIR=`cd tmp; pwd` ${MAKE} install-openxm
142: (cd tmp${prefix}; tar cf - * ) | gzip -c > asir-openxm-${VERSION}.tgz
143: -rm -rf tmp
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>