SHELL=bash #include make.inc #include Make.inc # # This makefile was produced by /usr/bin/fmgen at 12:40:44 AM on 02/22/96 # If it is invoked by the command line # make -f makefile # it will compile the fortran modules indicated by SRCS into the object # modules indicated by OBJS and produce an executable named a.out. # # If it is invoked by the command line # make -f makefile a.out.prof # it will compile the fortran modules indicated by SRCS into the object # modules indicated by OBJS and produce an executable which profiles # named a.out.prof. # # To remove all the objects but leave the executables use the command line # make -f makefile clean # # To remove everything but the source files use the command line # make -f makefile clobber # # To remove the source files created by /usr/bin/fmgen and this makefile # use the command line # make -f makefile void # # The parameters SRCS and OBJS should not need to be changed. If, however, # you need to add a new module add the name of the source module to the # SRCS parameter and add the name of the resulting object file to the OBJS # parameter. The new modules are not limited to fortran, but may be C, YACC, # LEX, or CAL. An explicit rule will need to be added for PASCAL modules. # # add LU routines ludcmp.f if not running on Cray ############################################################################ #*Disregard most of the above. This is a makefile to compile # # Darek Bogucki's DNS code on ferret. (9/25/01: Peter Diamessis) # ############################################################################ SRCS= main.f mpi_setup.f output.f #Add special bridge to C++ routine object file to call SuperLU #This is accessed through a symbolic link to #the EXAMPLES subdirectory of SuperLU OBJS= main.o mpi_setup.o output.o #MPI Home directory #Linux machine in office #MPI_HOME = /home/peted/mpich/v1.2.6 #USC-Linux cluster #-Portland Group Compiler #MPI_HOME = /usr/usc/mpich/default/default #-Absoft Compiler MPI_HOME=/home/peted/mpich/v1.2.6 #MPI_HOME=/tmp/peted/mpich2-1.0 # Tunable parameters # # CF Name of the fortran compiling system to use # LDFLAGS Flags to the loader # LIBS List of libraries # CMD Name of the executable # PROFLIB Library needed for profiling # # On T90: Use CF=f90 # On ferret (USC machine): Use CF=f77 FC = $(MPI_HOME)/bin/mpif90 # -L/usc/usr/lib CF = $(MPI_HOME)/bin/mpif90 LDFLAGS = PROF = LIBS = -L/opt/absoft10.0/lib64 -lV77 # #(PD: 7/25/03)-ABOUT THE LIBRARIES: # 1) Use SuperLU and relevant CBLAS libraries to compile # Super-LU fast linear system solver. See SuperLU directory. # I copied the specific libraries into this directory for now. # 2) The Atlas Lib libraries (may actually need libcblas # eventually) are used for matrix-matrix multiplication # in spectral differentiation & filtering. See ATLAS directory # 3) FFTW libraries are used for implementation of FFTW. See # FFTW directory. # LIBS = # -L/usr/usc/absoft/default/lib -lV77 CMD = f.out PROFLIB = # -lprof # To perform the default compilation, use the first line # To compile with flowtracing turned on, use the second line # To compile giving profile additonal information, use the third line # WARNING: SIMULTANEOUSLY PROFILING AND FLOWTRACING IS NOT RECOMMENDED #All these commands must be commented out when compiling and running #on the T90 #When compiling of ferret use first line # # Listed below are the compilation options for Linux-Absoft Fortran # -f: fold all symbolic names to lower case. # -N15: Appends underscore to names # -N113: Set double precision as default # -03: Advanced optimization level # -C: Check array bounds # -s: Force all program storage to be treated as static and initialized # to zero FFLAGS = -YEXT_NAMES=LCS -YEXT_SFX=_ -N113 -O3 \ -I$(MPI_HOME)/include #FFLAGS = -f -s -N15 -N113 -O3 #-r8 -i4 -fast #FFLAGS = -F #FFLAGS = -Wf"-ez" # Lines from here on down should not need to be changed. They are the # actual rules which make uses to build a.out. # Note (PD: 7/03/03) that SuperLU library and Blas are needed to # run Super LU. These were compiled in a separate directory # all: $(CMD) $(CMD): $(OBJS) #$(SUPERLULIB) $(BLASLIB) $(CF) $(LDFLAGS) -o $(@) $(LIBS) $(PROF) $(OBJS) #$(SUPERLULIB) $(BLASLIB) # Make the profiled version of the command and call it a.out.prof # $(CMD).prof: $(OBJS) $(CF) $(LDFLAGS) -o $(@) $(OBJS) $(PROFLIB) $(LIBS) clean: -rm -f $(OBJS) clobber: clean -rm -f $(CMD) $(CMD).prof void: clobber -rm -f $(SRCS) makefile