# CHARMM makefile for HP Apollo 9000 Series 700  machines
ROOT = rootdir
SRC = $(ROOT)/source
FLX = $(ROOT)/tool/preflx
LIB = $(ROOT)/lib/hpux
EXEC = $(ROOT)/exec/hpux
FC = f77 +E4 +T +U77
CC = cc -Dhpux -Dmachine_hp700
LD = f77 +U77
GLIB = grflib
RANLIB = touch
GMS = $(ROOT)/tool/gmscomp_hpux
QLIB =
#################################################################
# compiler options: always use +E4 +T
#    +E4 = print leading zero; 0.5 not .5
#    +T  = trap errors and traceback
# during testing and development add   -V +R -u -a
#    -V  = source listing to .l file
#    +R  = add cross reference listing to .l file
#    -u  = undeclared variable error (IMPLICIT NONE)
#    -a  = non-ANSI warning (LOTS of warnings for REAL*8, etc.)
#    -w  = suppress warning messages
#    +Qf = read directives from file f
#
#F77 = f77 +E4 +U77 +T -V +R -u +Qf77.opts
#################################################################
# MBOND option for HP
MBONDFLG =  +mr -K -DCHARMM -I../../source/moldyn
.SUFFIXES: .fcm .src .o
VPATH = fcm
FC0 = $(FC) -c -g -w -K
FC1 = $(FC) -c +O1 -w
FC2 = $(FC) -c +O2 -w
FC3 = $(FC) -c +O2 -w
FCR = $(FC) -c +O2 -w
FCD = $(FC) -c -g
FCRD = $(FC) -c -g
LIBS = \
	$(LIB)/adumb.a \
	$(LIB)/cadint.a \
	$(LIB)/cff.a \
	$(LIB)/correl.a \
	$(LIB)/dimb.a \
	$(LIB)/dynamc.a \
	$(LIB)/energy.a \
	$(LIB)/gamint.a \
	$(LIB)/gener.a \
	$(LIB)/graphics.a \
	$(LIB)/gukint.a \
	$(LIB)/image.a \
	$(LIB)/io.a \
	$(LIB)/machdep.a \
	$(LIB)/manip.a \
	$(LIB)/mbond.a \
	$(LIB)/mc.a \
	$(LIB)/minmiz.a \
	$(LIB)/misc.a \
	$(LIB)/mmff.a \
	$(LIB)/moldyn.a \
	$(LIB)/molvib.a \
	$(LIB)/nbonds.a \
	$(LIB)/pert.a \
	$(LIB)/quantum.a \
	$(LIB)/rxncor.a \
	$(LIB)/shapes.a \
	$(LIB)/solvation.a \
	$(LIB)/util.a \
	$(LIB)/vibran.a

$(EXEC)/charmm : $(LIB)/stamp $(LIBS)
	$(LD) -o charmm.exe $(LIB)/*.o $(LIBS) $(LIBS) $(GLIB) $(QLIB)
