# Simple Makefile # - Basement Supercomputing (c) Copyright 2007 # # IMPORTANT # If you are using modules, you must set the appropriate # module so the atlas libraries can be found. # # module load atlas-gnu4 # # will load the atlas module for gnu4 compilers # # This step will automatically set $ATLAS_PATH for # the correct libraries for your compiler. # See modules section in the documentation for # more information # # Set Fortran compiler e.g. # G77 or Gfortran for GNU # pgf90 for Portland Group FC=gfortran # Set Fortran Flags FFLAGS= -O2 # Set Path to you library files $ATLAS_PATH is defined by # modules, or you can enter a specific path LIBPATH= -L$(ATLAS_PATH) # Set the libraries you need LIBS= -llapack -lcblas -lf77blas -latlas -lf77blas # Set the source files DEPS = test_la.f # Set the object files OBJ = test_la.o # Make rules follow %.o: %.f $(DEPS) $(FC) $(FFLAGS) -c -o $@ $< test_la_fortran: $(OBJ) $(FC) $(FFLAGS) -o $@ $^ $(LIBPATH) $(LIBS) clean: /bin/rm -f test_la_fortran test_la.o # Command line version # # gfortran -o test_la_f test_la.f -L$ATLAS_PATH -llapack -lcblas -lf77blas -latlas -lf77blas