Commit 24510811 authored by ulrich_y's avatar ulrich_y
Browse files

Updated makefile

parent f78bfa83
......@@ -4,23 +4,37 @@ SHELL = /bin/sh
UNAME_S := $(shell uname -s)
SHA1=sha1sum
MODE=DEBUG
FC=gfortran
FFLAGS=-fdefault-real-8 -cpp -g -pedantic-errors -Werror -std=f2008 \
-Wall -Wno-maybe-uninitialized -Wno-uninitialized -O3 -fcheck=all
AR= ar rcs
FFLAGS=-fdefault-real-8 -cpp -pedantic-errors -std=f2008
FFLAGS+= -Werror -Wall -Wno-maybe-uninitialized -Wno-uninitialized -Wno-compare-reals
ifeq ($(MODE),RELEASE)
FFLAGS += -O3 -funroll-loops -Wtaps
else
FFLAGS += -O0 -frange-check -g -fcheck=all -Wextra
FFLAGS += -ffpe-trap=invalid,overflow -fdump-core -fbacktrace
endif
LD=gfortran
objects=build/globals.o build/ieps.o build/utils.o build/shuffle.o build/maths_functions.o build/mpl_module.o build/gpl_module.o
libgpl.a:$(objects)
@echo "AR $@"
@$(AR) $@ $^
# rules to make object files into /build
build/%.o: src/%.f90
@echo "F90 $@"
@$(FC) $(FFLAGS) -c $< -J build -o $@
eval: $(objects) build/eval.o
eval: libgpl.a build/eval.o
@echo "LD $@"
@$(LD) -o $@ $^ $(LFLAGS)
@$(LD) -o $@ build/eval.o -L. -lgpl
test: $(objects) build/test.o
@echo "LD $@"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment