Annotation of rpl/rplcas/Makefile.in, revision 1.51

1.1       bertrand    1: srcdir=@srcdir@
                      2: top_builddir=@abs_top_builddir@
1.12      bertrand    3: CFLAGS=@CFLAGS@
                      4: CXXFLAGS=@CXXFLAGS@
                      5: LDFLAGS=@LDFLAGS@
1.25      bertrand    6: OBJEXT=@OBJEXT@
1.12      bertrand    7: 
1.39      bertrand    8: .PHONY: configure clean distclean
1.3       bertrand    9: 
1.7       bertrand   10: all: lib/librplcas.a
1.2       bertrand   11: 
1.25      bertrand   12: lib/@LIB_PREFIX@gmp.a:
1.1       bertrand   13:    if [ ! -d @GMP@ ]; then \
                     14:        mkdir @GMP@; \
                     15:    fi
                     16:    if [ ! -f @GMP@/config.log ]; then \
1.12      bertrand   17:        (cd @GMP@ && \
1.13      bertrand   18:                CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
1.10      bertrand   19:                ../$(srcdir)/@GMP@/configure --with-readline=no \
1.49      bertrand   20:                --host=@HOST@ --enable-cxx \
1.4       bertrand   21:                --disable-shared --enable-static \
                     22:                --prefix=$(top_builddir)/rplcas); \
1.1       bertrand   23:    fi
1.16      bertrand   24:    $(MAKE) -C @GMP@ $(AM_MAKEFLAGS) all && \
                     25:            $(MAKE) -C $(AM_MAKEFLAGS) @GMP@ install
1.3       bertrand   26: 
1.25      bertrand   27: lib/@LIB_PREFIX@mpfr.a: lib/@LIB_PREFIX@gmp.a
1.2       bertrand   28:    if [ ! -d @MPFR@ ]; then \
                     29:        mkdir @MPFR@ ; \
                     30:    fi
1.1       bertrand   31:    if [ ! -f @MPFR@/config.log ]; then \
1.28      bertrand   32:        if [ @BUILD@ = @HOST@ ]; then \
                     33:            (cd @MPFR@ && \
                     34:                    CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                     35:                    ../$(srcdir)/@MPFR@/configure \
                     36:                    --with-gmp=$(top_builddir)/rplcas \
                     37:                    --disable-shared --enable-static \
                     38:                    --prefix=$(top_builddir)/rplcas); \
                     39:        else \
                     40:            (cd @MPFR@ && \
                     41:                    CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                     42:                    ../$(srcdir)/@MPFR@/configure \
                     43:                    --host=@HOST@ \
                     44:                    --with-gmp=$(top_builddir)/rplcas \
                     45:                    --disable-shared --enable-static \
                     46:                    --prefix=$(top_builddir)/rplcas); \
                     47:        fi; \
1.1       bertrand   48:    fi
1.16      bertrand   49:    $(MAKE) -C @MPFR@ $(AM_MAKEFLAGS) all && \
                     50:            $(MAKE) -C @MPFR@ $(AM_MAKEFLAGS) install
1.3       bertrand   51: 
1.44      bertrand   52: lib/@LIB_PREFIX@mpfi.a: lib/@LIB_PREFIX@gmp.a lib/@LIB_PREFIX@mpfr.a
                     53:    if [ ! -d @MPFI@ ]; then \
                     54:        mkdir @MPFI@ ; \
                     55:    fi
                     56:    if [ ! -f @MPFI@/config.log ]; then \
                     57:        if [ @BUILD@ = @HOST@ ]; then \
                     58:            (cd @MPFI@ && \
                     59:                    CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                     60:                    ../$(srcdir)/@MPFI@/configure \
                     61:                    --with-gmp=$(top_builddir)/rplcas \
                     62:                    --with-mpfr=$(top_builddir)/rplcas \
                     63:                    --disable-shared --enable-static \
                     64:                    --prefix=$(top_builddir)/rplcas); \
                     65:        else \
                     66:            (cd @MPFI@ && \
                     67:                    CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                     68:                    ../$(srcdir)/@MPFI@/configure \
                     69:                    --host=@HOST@ \
                     70:                    --with-gmp=$(top_builddir)/rplcas \
                     71:                    --with-mpfr=$(top_builddir)/rplcas \
                     72:                    --disable-shared --enable-static \
                     73:                    --prefix=$(top_builddir)/rplcas); \
                     74:        fi; \
                     75:    fi
                     76:    $(MAKE) -C @MPFI@ $(AM_MAKEFLAGS) all && \
                     77:            $(MAKE) -C @MPFI@ $(AM_MAKEFLAGS) install
                     78: 
1.18      bertrand   79: lib/ntl.a:
1.28      bertrand   80:    if [ @BUILD@ = @HOST@ ]; then \
                     81:        (cd @NTL@/src && ./configure GMP_PREFIX=$(top_builddir)/rplcas \
1.47      bertrand   82:                SHARED=off CXXFLAGS="$(CXXFLAGS)"); \
1.28      bertrand   83:    else \
                     84:        (cd @NTL@/src && ./configure GMP_PREFIX=$(top_builddir)/rplcas \
                     85:                SHARED=off CC=@HOST@-gcc CXX=@HOST@-g++ \
1.47      bertrand   86:                CXXFLAGS="@SYSROOT@ $(CXXFLAGS)" \
1.28      bertrand   87:                LDFLAGS="-L@SYSROOT2@/usr/lib"); \
                     88:    fi
1.30      bertrand   89:    (cd @NTL@/src && \
1.32      bertrand   90:        if [ -z '$(make -v | grep "^GNU Make")' -a $(shell uname) != Linux ]; \
                     91:                    then \
1.30      bertrand   92:                sed 's/make /gmake /g' makefile > makefile2 && \
                     93:                \mv -f makefile2 makefile && \
                     94:                sed 's/make /gmake /g' WizardAux > WizardAux2 && \
1.32      bertrand   95:                \mv -f WizardAux2 WizardAux; \
1.30      bertrand   96:        fi && \
                     97:        $(MAKE) $(AM_MAKEFLAGS) -f makefile)
1.4       bertrand   98:    cp @NTL@/src/ntl.a lib/ntl.a
                     99:    cp @NTL@/src/ntl.a lib/ntl.a
                    100:    cp -R @NTL@/include/NTL include
1.3       bertrand  101: 
1.25      bertrand  102: lib/libcocoa.a: lib/@LIB_PREFIX@gmp.a
1.50      bertrand  103: #  MakeUnifiedHeader.sh (interpreter)
1.51    ! bertrand  104:    for i in $(shell find @COCOA@ -name "*" -exec grep /bin/bash {} /dev/null \;); \
        !           105:    do
1.50      bertrand  106:        sed '1,1s/^#! *\/bin\/bash/#!@BASH@/g' $$i > $$i.2; \
                    107:        mv -f $$i.2 $$i; \
                    108:        chmod 755 $$i; \
                    109:    done;
1.2       bertrand  110:    if [ ! -f @COCOA@/configuration/autoconf.mk ]; then \
1.28      bertrand  111:        if [ @BUILD@ = @HOST@ ]; then \
                    112:            (cd @COCOA@ && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                    113:                    ./configure --with-libgmp=../lib/libgmp.a \
                    114:                    --with-libgsl=../../tools/@GSL@/.libs/libgsl.a); \
                    115:        else \
                    116:            (cd @COCOA@ && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                    117:                    ./configure --with-libgmp=../lib/libgmp.a \
                    118:                    --with-cxx=@HOST@-g++ \
                    119:                    --with-cxxflags="@SYSROOT@ $(CXXFLAGS)" \
                    120:                    --with-libgsl=../../tools/@GSL@/.libs/libgsl.a); \
                    121:        fi; \
1.2       bertrand  122:    fi
1.16      bertrand  123:    $(MAKE) -C @COCOA@ $(AM_MAKEFLAGS) library
1.4       bertrand  124:    cp @COCOA@/lib/libcocoa.a lib/libcocoa.a
                    125:    cp -R @COCOA@/include/CoCoA include
1.3       bertrand  126: 
1.25      bertrand  127: lib/libpari.a: lib/@LIB_PREFIX@gmp.a
1.4       bertrand  128:    if [ ! -f @PARI@/configured ]; then \
1.28      bertrand  129:        if [ @BUILD@ = @HOST@ ]; then \
                    130:            (cd @PARI@ && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
                    131:                    LDFLAGS="$(LDFLAGS)" \
                    132:                    ./Configure --prefix=$(top_builddir)/rplcas \
                    133:                    --with-gmp=../lib/libgmp.a \
                    134:                    --without-readline --graphic=none -s); \
                    135:        else \
                    136:            (cd @PARI@ && CC=@HOST@-gcc LD=@HOST@-ld \
                    137:                    CFLAGS="@SYSROOT@ $(CFLAGS)" \
                    138:                    CXXFLAGS="$(CXXFLAGS)" \
                    139:                    LDFLAGS="-L@SYSROOT2@/usr/lib $(LDFLAGS)" \
                    140:                    ./Configure --prefix=$(top_builddir)/rplcas \
                    141:                    --with-gmp=../lib/libgmp.a \
                    142:                    --without-readline --graphic=none -s); \
                    143:        fi; \
1.46      bertrand  144:        (cd @PARI@ && \
                    145:                sed -i -e 's/perl/perl -I./g' \
                    146:                        $$(find . -maxdepth 1 -name "O*")/Makefile); \
1.4       bertrand  147:        touch @PARI@/configured; \
                    148:    fi
1.28      bertrand  149:    $(MAKE) -C @PARI@ $(AM_MAKEFLAGS) gp && \
1.16      bertrand  150:            $(MAKE) -C @PARI@ $(AM_MAKEFLAGS) install
1.4       bertrand  151: 
1.25      bertrand  152: lib/@LIB_PREFIX@giac.a: lib/@LIB_PREFIX@gmp.a lib/@LIB_PREFIX@mpfr.a lib/ntl.a \
1.44      bertrand  153:        lib/libcocoa.a lib/libpari.a lib/@LIB_PREFIX@mpfi.a
1.4       bertrand  154:    if [ ! -d @GIAC@ ]; then \
                    155:        mkdir @GIAC@ ; \
                    156:    fi
1.37      bertrand  157:    if [ @BUILD@ = @HOST@ ]; then \
                    158:        (cd @GIAC@ && \
                    159:                CXX=@CXX@ \
                    160:                CPPFLAGS="-I$(top_builddir)/rplcas/include -I$(top_builddir)/tools/@GSL@ $(CPPFLAGS)" \
                    161:                CXXFLAGS="$(CXXFLAGS) -fpermissive" \
1.44      bertrand  162:                LDFLAGS="$(top_builddir)/rplcas/lib/libpari.a $(top_builddir)/rplcas/lib/ntl.a $(top_builddir)/rplcas/lib/libcocoa.a $(top_builddir)/tools/@GSL@/.libs/libgsl.a $(top_builddir)/rplcas/lib/@LIB_PREFIX@gmp.a $(top_builddir)/rplcas/lib/@LIB_PREFIX@mpfr.a $(top_builddir)/rplcas/lib/@LIB_PREFIX@mpfi.a $(LDFLAGS)" \
1.37      bertrand  163:                ../$(srcdir)/@GIAC@/configure --prefix=$(top_builddir)/rplcas \
1.43      bertrand  164:                --enable-pari \
                    165:                --enable-ntl \
                    166:                --enable-cocoa \
                    167:                --enable-gsl \
1.37      bertrand  168:                --disable-shared --enable-static \
                    169:                --disable-gui --without-x); \
                    170:    else \
                    171:        (cd @GIAC@ && \
                    172:                CPPFLAGS="-I$(top_builddir)/rplcas/include -I$(top_builddir)/tools/@GSL@ @SYSROOT@ $(CPPFLAGS)" \
                    173:                CXXFLAGS="$(CXXFLAGS) -fpermissive" \
1.44      bertrand  174:                LDFLAGS="$(top_builddir)/rplcas/lib/libpari.a $(top_builddir)/rplcas/lib/ntl.a $(top_builddir)/rplcas/lib/libcocoa.a $(top_builddir)/tools/@GSL@/.libs/libgsl.a $(top_builddir)/rplcas/lib/@LIB_PREFIX@gmp.a $(top_builddir)/rplcas/lib/@LIB_PREFIX@mpfr.a $(top_builddir)/rplcas/lib/@LIB_PREFIX@mpfi.a $(LDFLAGS)" \
1.37      bertrand  175:                ../$(srcdir)/@GIAC@/configure --prefix=$(top_builddir)/rplcas \
                    176:                --host=@HOST@ \
1.43      bertrand  177:                --enable-pari \
                    178:                --enable-ntl \
                    179:                --enable-cocoa \
                    180:                --enable-gsl \
1.37      bertrand  181:                --disable-shared --enable-static \
                    182:                --disable-gui --without-x); \
                    183:    fi; \
                    184:    (cd @GIAC@/src && \
                    185:            mv -f config.h config.h.orig && \
                    186:            sed -e 's/#define HAVE_LIBPNG 1//' config.h.orig | \
                    187:            sed -e 's/#define HAVE_PNG_H 1//' > config.h && \
                    188:            rm -f config.h.orig); \
1.44      bertrand  189:    (cd @GIAC@/src && \
                    190:            mv -f Makefile Makefile.orig && \
                    191:            sed -e 's/-lntl//' Makefile.orig | \
                    192:            sed -e 's/-lgmp//' | \
                    193:            sed -e 's/-lmpfr//' > Makefile && \
                    194:            rm -f Makefile.orig); \
1.37      bertrand  195:    $(MAKE) -C @GIAC@ $(AM_MAKEFLAGS)
1.23      bertrand  196:    if [ x$(srcdir) != x. ]; then \
                    197:        for i in mkinstalldirs xcas.xpm xcas.desktop xcas.applications; \
                    198:                do cp $(srcdir)/@GIAC@/$$i @GIAC@/$$i; done; \
1.38      bertrand  199:        cp -R $(srcdir)/@GIAC@/icons @GIAC@; \
1.23      bertrand  200:    fi
1.37      bertrand  201:    $(MAKE) -C @GIAC@ $(AM_MAKEFLAGS) install
1.1       bertrand  202: 
1.25      bertrand  203: lib/librplcas.a: lib/@LIB_PREFIX@giac.a lib/@LIB_PREFIX@gmp.a \
1.44      bertrand  204:        lib/@LIB_PREFIX@mpfr.a lib/ntl.a lib/libcocoa.a lib/libpari.a \
                    205:        lib/@LIB_PREFIX@mpfi.a
1.7       bertrand  206:    if [ ! -d tmp ]; then mkdir tmp; fi
1.45      bertrand  207:    for i in `ar t lib/@LIB_PREFIX@giac.a | grep a$$`; \
                    208:    do ar d lib/@LIB_PREFIX@giac.a $$i; \
                    209:    done
1.26      bertrand  210:    @(cd tmp && n=0 && \
1.25      bertrand  211:            rm -f * && \
                    212:            echo Building standalone librplcas.a; \
                    213:            for i in ../lib/@LIB_PREFIX@gmp.a \
                    214:                    ../lib/@LIB_PREFIX@mpfr.a \
1.44      bertrand  215:                    ../lib/@LIB_PREFIX@mpfi.a \
1.25      bertrand  216:                    ../lib/libcocoa.a \
                    217:                    ../lib/libpari.a \
                    218:                    ../lib/ntl.a \
                    219:                    ../lib/@LIB_PREFIX@giac.a; \
                    220:                do echo Extracting $$i; ar x $$i; \
                    221:                for j in `ar t $$i`; \
                    222:                do cp -f $$j $$n-$$j; \
                    223:                    rm -f $$j; \
                    224:                done; \
                    225:                n=`expr $$n + 1`; \
                    226:            done; \
                    227:            L="start"; \
                    228:            while test -n "$$L"; \
                    229:            do \
                    230:                echo -n "Remaining files "; \
                    231:                find . -name "*.$(OBJEXT)" | wc -l; \
                    232:                L=""; j=0; \
                    233:                for i in `find . -name "*.$(OBJEXT)"`; \
                    234:                do \
                    235:                    k=`echo $$i | wc -c`; \
                    236:                    j=`expr $$j + $$k + 1`; \
                    237:                    if test $$j -le 8000; then \
                    238:                        L="$$L $$i"; \
                    239:                    else \
                    240:                        break; \
                    241:                    fi; \
                    242:                done; \
                    243:                if test -n "$$L"; then \
                    244:                    echo -n "Adding files to librplcas.a archive... "; \
1.42      bertrand  245:                    ar cr ../lib/librplcas.a $$L; \
1.25      bertrand  246:                    rm -f $$L; \
                    247:                    echo "done"; \
                    248:                fi; \
                    249:            done; \
                    250:            echo Archive created; \
                    251:            ar s ../lib/librplcas.a; \
                    252:            if [ @OS@ != OS2 -a @OS@ != Darwin ]; then \
                    253:                echo Stripping librplcas.a && strip -d ../lib/librplcas.a; \
                    254:            fi;)
1.45      bertrand  255:    rmdir tmp
1.7       bertrand  256: 
1.14      bertrand  257: install:
1.1       bertrand  258: 
1.24      bertrand  259: uninstall:
                    260: 
1.3       bertrand  261: clean:
1.8       bertrand  262:    \rm -f $(top_builddir)/rplcas/lib/lib*
1.2       bertrand  263: 
                    264: distdir:

CVSweb interface <joel.bertrand@systella.fr>