
TARGETS = stiff.o

TARGETS1 = adapt_time.o


# -fPIC  ... warning: variable is never used
#FFLAGS=  -fPIC -fdefault-real-8  -w

## optimize for computations
#FFLAGS=  -fPIC -fdefault-real-8 -fopenmp -O2 -w -ffpe-trap=invalid,zero,overflow

# for debugging of the code
FFLAGS= -fPIC -fdefault-real-8 -g -fbacktrace -fbounds-check -w -Wall -finit-real=nan -finit-integer=-999999 -fno-align-commons -ffpe-trap=invalid,zero,overflow,denormal

FXX=gfortran


all: stiff adapt_time


stiff: $(TARGETS)
	$(FXX) $(FFLAGS) -o stiff $^ 

adapt_time: $(TARGETS1)
	$(FXX) $(FFLAGS) -o adapt_time $^ 


clean:
	rm -f *.o

%.o:%.f90
	$(FXX) $(FFLAGS) -c $?


