1cdb0f33dSPierre Jolivet-include ../../../petscdir.mk 2c4762a1bSJed BrownCFLAGS = 3c4762a1bSJed BrownFFLAGS = 4c4762a1bSJed BrownCPPFLAGS = 5c4762a1bSJed BrownFPPFLAGS = 6c4762a1bSJed BrownLOCDIR = src/sys/tests/ 7c4762a1bSJed BrownEXAMPLESC = ex1.c ex2.c ex3.c ex6.c ex7.c ex8.c ex9.c ex10.c ex11.c ex12.c \ 8c4762a1bSJed Brown ex14.c ex16.c ex18.c ex19.c ex20.c ex21.c \ 9c4762a1bSJed Brown ex22.c ex23.c ex24.c ex25.c ex26.c ex27.c ex28.c ex29.c ex30.c ex31.c ex32.c ex35.c ex37.c \ 10c4762a1bSJed Brown ex44.cxx ex45.cxx ex46.cxx ex47.c ex49.c \ 11f0463fa0SJunchao Zhang ex50.c ex51.c ex52.c ex53.c 12c4762a1bSJed BrownEXAMPLESF = ex1f.F90 ex5f.F ex6f.F ex17f.F ex36f.F90 ex38f.F90 ex47f.F90 ex48f90.F90 ex49f.F90 13c4762a1bSJed BrownMANSEC = Sys 14c4762a1bSJed Brown 15c4762a1bSJed Browninclude ${PETSC_DIR}/lib/petsc/conf/variables 16c4762a1bSJed Browninclude ${PETSC_DIR}/lib/petsc/conf/rules 17c4762a1bSJed Browninclude ${PETSC_DIR}/lib/petsc/conf/test 18*b6efb0a5SBarry Smith 19*b6efb0a5SBarry Smithtestex55: 20*b6efb0a5SBarry Smith -@if [ "${PETSC_WITH_BATCH}" != "" ]; then \ 21*b6efb0a5SBarry Smith echo "Running with batch filesystem; to test run src/sys/tests/ex55.py with" ; \ 22*b6efb0a5SBarry Smith echo "your systems batch system"; \ 23*b6efb0a5SBarry Smith elif [ "${MPIEXEC}" = "/bin/false" ]; then \ 24*b6efb0a5SBarry Smith echo "*mpiexec not found*. Please run src/sys/tests/ex55.py manually"; \ 25*b6efb0a5SBarry Smith else \ 26*b6efb0a5SBarry Smith if [[ -d ${PETSC_DIR}/${PETSC_ARCH}/lib/mpi4py && "X${PYTHONPATH}" == "X" ]]; then \ 27*b6efb0a5SBarry Smith export PYTHONPATH=${PETSC_DIR}/${PETSC_ARCH}/lib; \ 28*b6efb0a5SBarry Smith echo "Setting PYTHONPATH to $${PYTHONPATH} to locate mpi4py for test"; \ 29*b6efb0a5SBarry Smith fi; \ 30*b6efb0a5SBarry Smith ${MPIEXEC} -n 2 ${PYTHON} ./ex55.py > ex55_1.tmp 2>&1;\ 31*b6efb0a5SBarry Smith if (${DIFF} output/ex55_1.testout ex55_1.tmp > /dev/null 2>&1) then \ 32*b6efb0a5SBarry Smith echo "C/C++ mpi4py python example src/sys/tests/ex55.py run successfully with 2 MPI process"; \ 33*b6efb0a5SBarry Smith else echo "Possible error running Python src/sys/tests/ex55.py with 2 MPI processes"; \ 34*b6efb0a5SBarry Smith echo "See http://www.mcs.anl.gov/petsc/documentation/faq.html";\ 35*b6efb0a5SBarry Smith cat ex55_1.tmp; fi; \ 36*b6efb0a5SBarry Smith ${RM} -f ex55.tmp; fi 37