#
# Make MC2
#

#
#    #########    Define necessary object modules     #########
#

OBJ =			\
	mc2.o 		\
        initial2.o       \
        sort.o          \
        collision2.o     \
        mover2.o         \
	randn.o	        \
        ran2.o          \
        pressure.o      \
        sampler2.o

#
#    #########	Fortran compile directive    #########
#

#Option for compiling
FOPT = -O3

.f.o:	
	f77 $(FOPT) -c $<

#
#    ######### 	Now define the directive for the executable    #########
#

#LOPT = -g -C 
#LOPT = -O -p
#LOPT = -p
#LOPT = -fast -fpe -tune host

#ell2: $(OBJ)
#	f77 $(LOPT) -o ell2 $(OBJ) -L/usr/lib -lfpe
#
sol: $(OBJ)
	f77 $(LOPT) -o mc2 $(OBJ)  

#
#    ######### Define dependencies    #########
#

mc2.o:		mc2.f         	mc.inc       makefile

initial2.o:    initial2.f       mc.inc       makefile

sort.o:         sort.f          mc.inc       makefile

collision2.o:   collision2.f    mc.inc       makefile

mover2.o:	mover2.f	mc.inc	     makefile

randn.o:	randn.f		mc.inc	     makefile

ran2.o:		ran2.f		mc.inc	     makefile

pressure.o:     pressure.f      mc.inc       makefile

sampler2.o:	sampler2.f	mc.inc	     makefile

#
#    #########	Cleanup any unfinished business    #########
#

clean:
	\rm -f *.o ; make
