-
Notifications
You must be signed in to change notification settings - Fork 16
/
makefile
49 lines (34 loc) · 915 Bytes
/
makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# EXE OPTIONS:
#
# make
# make all (same as make)
# make clean
# make veryclean
# Edit to adjust for Fortran compiler and flags. Keep '-assume byterecl' !!!
FC = ifort
FLFLAGS = # none
FCFLAGS = -free -assume byterecl # performance
#FCFLAGS = -free -assume byterecl -g -traceback -check all -debug all # debug
# gfortran compiler
#FC = gfortran
#FLFLAGS = # none
#FCFLAGS = -ffree-form # performance
#FCFLAGS = -ffree-form -g -fbacktrace -Wconversion -fcheck=all # debug
# ~~~ Do not edit after that line ~~~
PROGRAM = fold2Bloch
# source files and objects
SRCS = $(patsubst %.f90, %.o, $(wildcard *.f90)) \
$(patsubst %.h, %.mod, $(wildcard *.h))
all: $(PROGRAM)
$(PROGRAM): $(SRCS)
$(FC) $(FLFLAGS) -o $@ $^
%.o: %.f90
$(FC) $(FCFLAGS) -c $<
#%.mod: %.h
# $(FC) $(FCFLAGS) -o $@ $<
# Utility targets
.PHONY: clean veryclean
clean:
rm -f *.o *.mod *.MOD
veryclean: clean
rm -f *~ $(PROGRAM)