#                           $Id: makefile.OSF1,v 1.1.1.1 2004/06/26 11:21:37 yamasaki Exp $
.SUFFIXES:
.SUFFIXES: .o .F .f .F90 .f90 .mod

F90   = f90
F77   = f77
FFLAG = -O5 -c

CPP       = cpp -P -C

SYSTEM    =  DEC
P_FLAGS   = -D$(SYSTEM) $(P_FLAGS0)

OBJECTSF90 = \
$(LOWER_MODULES) \
$(UPPER_MODULES) \
$(F_SUBROUTINES)\
$(F_OTHERSUBS)

OBJECTS = $(OBJECTSF90) $(OBJECTSF77)

$(TARGET) : $(OBJECTS)
	$(F90) $(OBJECTS) -o $@


$(UPPER_MODULES) $(F_SUBROUTINES):$(@:.o=.f90)

.f90.o:
	$(F90) $(FFLAG) $*.f90

.F90.o:
	$(CPP) $(P_FLAGS) < $*.F90 >$*.f90
	$(F90) $(FFLAG) $*.f90

.f.o:
	$(F77) $(FFLAG) $*.f

.F.o:
	$(F77) $(FFLAG) $(P_FLAGS) $*.F

$(OBJ_WALLCLOCK):$(@:.o=.c)
	cc -c $(@:.o=.c)

