From 7fd041264e6fdec8a385c1cb0b915ace05cc10d3 Mon Sep 17 00:00:00 2001 From: John Denker Date: Wed, 20 Nov 2024 12:27:10 -0700 Subject: choose compiler f95 f90 f77 depending on what's available --- Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 57560d2..1a70546 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,11 @@ RM = rm -f CC = CC -FC = f90 +# Find a suitable compiler: +FC := $(shell which f95 || which f90 || which f77) +ifeq ($(FC),) + $(error Fortran compiler not found; please fix 'FC' in Makefile) +endif CFLAGS = -C INCLUDES = -- cgit v1.2.3