1-include ../../../../../petscdir.mk 2 3CXXFLAGS = ${AMREX_INCLUDE} 4OBJECTS = main.o MyTest.o initEB.o 5 6include ${PETSC_DIR}/lib/petsc/conf/variables 7include ${PETSC_DIR}/lib/petsc/conf/rules 8 9V ?= 0 10QUIET = $(shell [ "$(V)" = "0" ] && echo @) 11 12# TODO: have configure determine -Wl,-undefined,dynamic_lookup for all OS 13 14amrex: $(OBJECTS) 15 -${CXXLINKER} -o amrex $(OBJECTS) ${AMREX_LIB} -Wl,-undefined,dynamic_lookup ${PETSC_KSP_LIB} 16 ${RM} $(OBJECTS) 17 18#------------------------------------------------------------------------- 19 20# these tests are used by the makefile in PETSC_DIR for basic tests of the install and should not be removed 21testamrex: amrex 22 -${QUIET}${MPIEXEC} -n 1 ${MPIEXEC_TAIL} ./amrex inputs.rt.2d.petsc | grep -E -v "(AMReX|Timers)" > amrex.tmp 2>&1; 23 -${QUIET}${DIFF} output/amrex_1.testout amrex.tmp > amrex.dtmp; 24 -@if [ ! -s amrex.dtmp ]; then\ 25 echo "example src/ksp/ksp/tutorials/amrex/amrex run successfully with 1 MPI process";\ 26 else echo "Possible error running example src/ksp/ksp/tutorials/amrex/amrex with 1 MPI process";\ 27 echo "See https://petsc.org/release/faq/";\ 28 cat amrex.tmp;\ 29 fi;\ 30 ${RM} -f amrex.tmp amrex.dtmp; 31