1# 2# This is the makefile for installing TAO. See the file 3# docs/installation.html for directions on installing TAO. 4# See also bmake/common for additional commands. 5# 6ALL: all 7 8 9# Call make recursively in these directory 10DIRS = src include docs tests 11 12include ${TAO_DIR}/conf/tao_base 13 14# 15# Basic targets to build TAO libraries. 16# all : builds the C/C++ and Fortran libraries 17all : tao_info tao_chk_tao_dir tao_chk_lib_dir tao_deletelibs tao_build tao_shared 18# 19# Prints information about the system and version of TAO being compiled 20# 21tao_info: 22 -@echo "==========================================" 23 -@echo " " 24 -@echo "See docs/troubleshooting.html and docs/bugreporting.html" 25 -@echo "for help with installation problems. Please send EVERYTHING" 26 -@echo "printed out below when reporting problems." 27 -@echo " " 28 -@echo "To subscribe to the TAO users mailing list, please " 29 -@echo "visit https://lists.mcs.anl.gov/mailman/listinfo/tao-news" 30 -@echo " " 31 -@echo "==========================================" 32 -@echo On `date` on `hostname` 33 -@echo Machine characteristics: `uname -a` 34 -@echo "-----------------------------------------" 35 -@echo "Using PETSc directory: ${PETSC_DIR}" 36 -@echo "Using PETSc arch: ${PETSC_ARCH}" 37 -@echo "Using TAO directory: ${TAO_DIR}" 38 -@echo "-----------------------------------------" 39 -@grep "define PETSC_VERSION" ${PETSC_DIR}/include/petscversion.h | ${SED} "s/........//" 40 -@grep TAO_VERSION_NUMBER include/tao_version.h | sed "s/........//" 41 -@echo "-----------------------------------------" 42 -@echo "Using include paths: ${TAO_INCLUDE}" 43 -@echo "------------------------------------------" 44 -@echo "Using C/C++ compiler: ${CC} ${CC_FLAGS} ${COPTFLAGS} ${CFLAGS}" 45 -@echo "C/C++ Compiler version: " `${CCV}` 46 -@if [ "${FC}" != "" ]; then \ 47 echo "Using Fortran compiler: ${FC} ${FC_FLAGS} ${FFLAGS} ${FPP_FLAGS}";\ 48 echo "Fortran Compiler version: " `${FCV}`;\ 49 fi 50 -@echo "-----------------------------------------" 51 -@echo "Using C/C++ linker: ${CC_LINKER}" 52 -@if [ "${FC}" != "" ]; then \ 53 echo "Using Fortran linker: ${FC_LINKER}";\ 54 fi 55 -@echo "-----------------------------------------" 56 -@echo "Using libraries: ${TAO_LIB}" 57 -@echo "------------------------------------------" 58 -@echo "Using mpiexec: ${MPIEXEC}" 59 -@echo "==========================================" 60 61MINFO = ${PETSC_DIR}/${PETSC_ARCH}/include/petscmachineinfo.h 62tao_info_h: 63 -@$(RM) -f ${MINFO} MINFO 64 -@echo "static const char *petscmachineinfo = \"\__n__\"" >> MINFO 65 -@echo "\"-----------------------------------------\__n__\"" >> MINFO 66 -@if [ -f /usr/bin/cygcheck.exe ]; then \ 67 echo "\"Libraries compiled on `date` on `hostname|/usr/bin/dos2unix` \__n__\"" >> MINFO; \ 68 else \ 69 echo "\"Libraries compiled on `date` on `hostname` \__n__\"" >> MINFO; \ 70 fi 71 -@echo "\"Machine characteristics: `uname -a` \__n__\"" >> MINFO 72 -@echo "\"Using PETSc directory: ${PETSC_DIR}\__n__\"" >> MINFO 73 -@echo "\"Using PETSc arch: ${PETSC_ARCH}\__n__\"" >> MINFO 74 -@echo "\"-----------------------------------------\"; " >> MINFO 75 -@echo "static const char *petsccompilerinfo = \"\__n__\"" >> MINFO 76 -@echo "\"Using C compiler: ${PCC} ${PCC_FLAGS} ${COPTFLAGS} ${CFLAGS}\__n__\"" >> MINFO 77 -@echo "\"Using Fortran compiler: ${FC} ${FC_FLAGS} ${FFLAGS} ${FPP_FLAGS}\__n__\"" >> MINFO 78 -@echo "\"-----------------------------------------\"; " >> MINFO 79 -@echo "static const char *petsccompilerflagsinfo = \"\__n__\"" >> MINFO 80 -@echo "\"Using include paths: ${PETSC_INCLUDE}\__n__\"" >> MINFO 81 -@echo "\"------------------------------------------\"; " >> MINFO 82 -@echo "static const char *petsclinkerinfo = \"\__n__\"" >> MINFO 83 -@echo "\"Using C linker: ${CLINKER}\__n__\"" >> MINFO 84 -@echo "\"Using Fortran linker: ${FLINKER}\__n__\"" >> MINFO 85 -@echo "\"Using libraries: ${PETSC_LIB} \__n__\"" >> MINFO 86 -@echo "\"------------------------------------------\"; " >> MINFO 87 -@cat MINFO | ${SED} -e 's/\\ /\\\\ /g' | ${SED} -e 's/__n__/n/g' > ${MINFO} 88 -@ if [ -f /usr/bin/cygcheck.exe ]; then /usr/bin/dos2unix ${MINFO} 2> /dev/null; fi 89 -@$(RM) -f MINFO 90 91 92 93 94# 95# Builds the TAO libraries 96# This target also builds fortran77 and f90 interface 97# files and compiles .F files 98# 99tao_build: 100 -@echo "BEGINNING TO COMPILE LIBRARIES IN ALL DIRECTORIES" 101 -@echo "=========================================" 102 -@${OMAKE} PETSC_ARCH=${PETSC_ARCH} PETSC_DIR=${PETSC_DIR} TAO_DIR=${TAO_DIR} ACTION=libfast tree 103 -@${RANLIB} ${TAO_LIB_DIR}/*.${AR_LIB_SUFFIX} 104 -@echo "Completed building libraries" 105 -@echo "=========================================" 106 107# 108 109# Deletes TAO libraries 110tao_deletelibs: 111 -${RM} -f ${TAO_LIB_DIR}/libtao*.* 112 113 114tao_shared: shared 115 116 117tao_alletags: 118 -@maint/generateetags.py 119 120 121tao_testexamples: 122 -@PYTHONPATH=${TAO_DIR}/maint ./maint/runTests.py -d 123 124tao_allfortranstubs: 125 -@maint/generatefortranstubs.py ${BFORT} 126 127tao_manual: 128 cd docs/tex/manual; ${OMAKE} manual.pdf 129 130tao_deletemanpages: 131 ${RM} -f ${TAO_DIR}/docs/manpages/*/*.html \ 132 ${TAO_DIR}/docs/manpages/manpages.cit 133 134tao_allmanpages: tao_htmlpages tao_deletemanpages 135 @mkdir -p ${TAO_DIR}/docs/manpages/taosolver 136 @mkdir -p ${TAO_DIR}/docs/manpages/taolinesearch 137 138 139 -${OMAKE} ACTION=tao_manpages_buildcite tree 140 -${OMAKE} ACTION=tao_manpages tree 141 -${OMAKE} ACTION=tao_manexamples tree LOC=${TAO_DIR} 142 -maint/wwwindex.py ${TAO_DIR} 143 144tao_htmlpages: 145 -${OMAKE} ACTION=tao_html TAO_DIR=${TAO_DIR} PETSC_DIR=${PETSC_DIR} alltree LOC=${TAO_DIR} 146 147 148tao_chk_lib_dir: chklib_dir 149