.mod=.mod .fh=.fh .SUFFIXES: .SUFFIXES: .f90 .F90 $(.mod) .F .f .c .o ####################### Section 1 ####################### # Define your compilers and compiler flags here # ########################################################## IFC9=/opt/intel/fc/9.1.033 F90=$(IFC9)/bin/ifort FC=$(IFC9)/bin/ifort F77=$(FC) CC=gcc F90COPT=-O3 FCOPT=-O3 CCOPT=-O3 # # Which flag does your compiler use for module inclusion? # Most compilers use -I but Sun uses -M # FIFLAG is for INCLUDE FMFLAG=-I FIFLAG=-I ####################### Section 2 ####################### # Define your linker and linker flags here # # Does your MPI provide mpi.mod or mpif.h? # # MPI_FINC=-DMPI_H or MPI_FINC=-DMPI_MOD # # If necessary add MPIINCDIR # ########################################################## MPIDIR=/usr/local/mpich-ifc91 MPIBIN=$(MPIDIR)/bin F90LINK=$(MPIBIN)/mpif90 FLINK=$(MPIBIN)/mpif77 MPF90=$(MPIBIN)/mpif90 MPF77=$(MPIBIN)/mpif77 MPCC=$(MPIBIN)/mpicc MPI_FINC=-DMPI_MOD #$(FIFLAG)/opt/SUNWhpc/include ####################### Section 3 ####################### # Specify paths to libraries # ########################################################## BLAS=-lblas-ifort91 -L$(HOME)/LIB BLACS=-lmpiblacs-ifort91 -L$(HOME)/LIB ####################### Section 4 ####################### # Other useful tools&defines # ########################################################## # # The examples can make use of METIS from U. Minnesota. # http://www.cs.umn.edu:~karypis # but it's optional # #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) # Add -DPtr64Bits if needed PSBCDEFINES=-DLowerUnderscore # # Note: MOVE_ALLOC is only on Intel Fortran 9.1, NOT on 9.0 PSBFDEFINES=-DHAVE_KSENDID $(MPI_FINC) -DHAVE_MOVE_ALLOC # -DHAVE_METIS AR=ar -cur RANLIB=ranlib ####################### Section 5 ####################### # Do not edit this # ########################################################## LIBDIR=lib BASELIBNAME=libpsb_base.a PRECLIBNAME=libpsb_prec.a METHDLIBNAME=libpsb_krylov.a UTILLIBNAME=libpsb_util.a CDEFINES=$(PSBCDEFINES) FDEFINES=$(PSBFDEFINES) # Under Linux/gmake there is a rule interpreting .mod as Modula source! $(.mod).o: .c.o: $(CC) $(CCOPT) $(CINCLUDES) $(CDEFINES) -c $< .f.o: $(FC) $(FCOPT) $(FINCLUDES) -c $< .f$(.mod): $(FC) $(FCOPT) $(FINCLUDES) -c $< .f90$(.mod): $(F90) $(F90COPT) $(FINCLUDES) -c $< .f90.o: $(F90) $(F90COPT) $(FINCLUDES) -c $< .F.o: $(FC) $(FCOPT) $(FINCLUDES) $(FDEFINES) -c $< .F90.o: $(F90) $(F90COPT) $(FINCLUDES) $(FDEFINES) -c $< .F90$(.mod): $(F90) $(F90COPT) $(FINCLUDES) $(FDEFINES) -c $<