Newer
Older
# Define our compilers.................................
#
# MVAPICH2
MPI_HOME=/appl/opt/mvapich2/2.0rc2/intel/13.1.1/
F90 = $(MPI_HOME)/bin/mpif90
F77 = $(MPI_HOME)/bin/mpif90
CC = $(MPI_HOME)/bin/mpicc
AR=xiar
BITS=-intel_13.1.0-mvapich2_2.0rc2-wsmp_14.06.05
#IMKL = /v/linux26_x86_64/opt/intel/Compiler/11.1/064/mkl/include
#INCLUDE=-I$(IMKL)
# Define FORTRAN compiler flags.......................
#
# For the PGI compiler
F90FLAGS = -O2 -fp-model precise -fp-model source -heap-arrays 10
F77FLAGS = -O2 -fp-model precise -fp-model source -heap-arrays 10
#F90FLAGS = -O3 -xHost -opt-prefetch -unroll-aggressive -no-prec-div -fp-model fast=2 -heap-arrays 10
#F77FLAGS = -O3 -xHost -opt-prefetch -unroll-aggressive -no-prec-div -fp-model fast=2 -heap-arrays 10
#F90FLAGS = -O0 -fp-model strict -g -debug all -traceback -heap-arrays 10
#F77FLAGS = -O0 -fp-model strict -g -debug all -traceback -heap-arrays 10
#F90FLAGS = -O0 -check all -warn all,nodec,interfaces -gen_interfaces -traceback -fpe0
#F77FLAGS = -O0 -check all -warn all,nodec,interfaces -gen_interfaces -traceback -fpe0
# Define C compiler flags.............................
#
CFLAGS = -O2 -fp-model precise -fp-model source -I.
#CFLAGS = -O3 -xHost -opt-prefetch -unroll-aggressive -no-prec-div -fp-model fast=2 -I.
#CFLAGS = -O0 -I. -fp-model strict -g -debug all -traceback
#CFLAGS = -O0 -check all -warn all,nodec,interfaces -gen_interfaces -traceback -fpe0
# Libraries.............................
# Intel MKL libs
#LMKL = /v/linux26_x86_64/opt/intel/Compiler/11.1/064/mkl/lib/em64t
LMKL =
# MPI
MPI = -L$(MPI_HOME)/lib -lmpich
#WSMP = $(HOME)/software/wsmp/11.05.20/wsmp-Linux64-Intel/lib/intelmpi
WSMP = $(HOME)/software/wsmp/14.06.05/wsmp-Linux64-Intel/lib/mvapich2
LIBS = \
-LOCTREE -lOctree$(BITS) \
-LNN -lnn_f$(BITS) \
-LNN -lnn_c$(BITS) \
-LCASCADE -lcascade$(BITS) \
-LRESAMPLE -lresample$(BITS) \
-L$(WSMP) -lpwsmp64Intelmpi2 \
-L$(LMKL) -lmkl_scalapack_lp64 -lmkl_intel_lp64 -lmkl_sequential \
-lmkl_core -lmkl_blacs_intelmpi_lp64 -lm \
$(MPI) -lpthread
#-L$(LMKL) -lmkl_scalapack_lp64 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lmkl_blacs_intelmpi_lp64 -lpthread -lm
# ORIGINAL BELOW
#-L$(LMKL) -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -liomp5 \
#-L$(LMKL) -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lpthread \
# The Makefiles look at compile output with this
PAGER=more
# compile rules.......................................
#
COMPILE_OUT=$(NAME)$(BITS).compile
.SUFFIXES:
.SUFFIXES: .o .c .f .f90
.f90.o:
@echo "--" >>$(COMPILE_OUT) 2>&1
@echo "$(F90) $(F90FLAGS) $(INCLUDES) -c $<" >>$(COMPILE_OUT) 2>&1
$(F90) $(F90FLAGS) $(INCLUDES) -c $< >>$(COMPILE_OUT) 2>&1
.f.o:
@echo "--" >>$(COMPILE_OUT) 2>&1
@echo "$(F77) $(F77FLAGS) $(INCLUDES) -c $<" >>$(COMPILE_OUT) 2>&1
$(F77) $(F77FLAGS) $(INCLUDES) -c $< >>$(COMPILE_OUT) 2>&1
.c.o:
@echo "--" >>$(COMPILE_OUT) 2>&1
@echo "$(CC) $(CFLAGS) -c $<" >>$(COMPILE_OUT) 2>&1
$(CC) $(CFLAGS) -c $< >>$(COMPILE_OUT) 2>&1