xref: /petsc/src/sys/tests/makefile (revision 792fecdfe9134cce4d631112660ddd34f063bc17)
1-include ../../../petscdir.mk
2
3LOCDIR          = src/sys/tests/
4MANSEC          = Sys
5
6include ${PETSC_DIR}/lib/petsc/conf/variables
7include ${PETSC_DIR}/lib/petsc/conf/rules
8include ${PETSC_DIR}/lib/petsc/conf/test
9
10testex55:
11	-@if [ "${PETSC_WITH_BATCH}" != "" ]; then \
12           echo "Running with batch filesystem; to test run src/sys/tests/ex55.py with" ; \
13           echo "your systems batch system"; \
14        elif [ "${MPIEXEC}" = "/bin/false" ]; then \
15           echo "*mpiexec not found*. Please run src/sys/tests/ex55.py manually"; \
16	else \
17           export PYTHONPATH=${PYTHONPATH:+$PYTHONPATH:}${PETSC_MPI4PY_PYTHONPATH}; \
18           echo "Using PYTHONPATH=$${PYTHONPATH} to locate mpi4py for test"; \
19           ${MPIEXEC} -n 2 ${PYTHON} ./ex55.py > ex55_1.tmp  2>&1;\
20	   if (${DIFF} output/ex55_1.testout ex55_1.tmp > /dev/null 2>&1) then \
21           echo "C/C++ mpi4py python example src/sys/tests/ex55.py run successfully with 2 MPI process"; \
22	   else echo "Possible error running Python src/sys/tests/ex55.py with 2 MPI processes"; \
23           echo "See https://petsc.org/release/faq/";\
24           cat ex55_1.tmp; fi; \
25        ${RM} -f ex55.tmp; fi
26