Skip to content
This repository was archived by the owner on Apr 23, 2020. It is now read-only.

Commit 5a31069

Browse files
committed
Preprocess some kinds of fortran files
git-svn-id: https://llvm.org/svn/llvm-project/test-suite/trunk@26408 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent e5acbc0 commit 5a31069

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Makefile.nagfortran

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,15 +31,21 @@ endif
3131

3232
clean::
3333
rm -f $(patsubst %.f,%.c, $(filter %.f,$(Source))) \
34+
$(patsubst %.F,%.c, $(filter %.F,$(Source))) \
3435
$(patsubst %.f90,%.c, $(filter %.f90,$(Source))) \
3536
$(patsubst %.F90,%.c, $(filter %.F90,$(Source)))
3637

3738
%.c: %.f
3839
$(F95) -w -S -O2 $< -o $@ $(NAGFORTRAN_FLAGS)
3940

41+
%.f: %.F
42+
$(CPP) -x c $< -o - $(CPPFLAGS) -traditional-cpp | $(SED) '/^# /d' > $@
43+
4044
%.c: %.f90
4145
$(F95) -w -S -O2 $< -o $@ $(NAGFORTRAN_FLAGS)
4246

47+
%.f90: %.F90
48+
$(CPP) -x c $< -o - $(CPPFLAGS) -traditional-cpp | $(SED) '/^# /d' > $@
4349

44-
CPPFLAGS = -I$(F95_DIR)/lib/NAGWare
50+
CPPFLAGS += -I$(F95_DIR)/lib/NAGWare
4551
LDFLAGS += $(F95_DIR)/lib/NAGWare/quickfit.o -Xlinker -flat_namespace $(F95_DIR)/lib/NAGWare/libf97.dylib $(F95_DIR)/lib/NAGWare/libf96.a

0 commit comments

Comments
 (0)