#--------------------------------------------------------------------------
# Unix Makefile written by Laurent Bonnaud <bonnaud@irisa.fr>.
#
# Please report problems to Don Cross <dcross@intersrv.com>.
# Get the latest version of this Makefile at
#   http://www.intersrv.com/~dcross/chenard.html
#   [Download the file called 'chensrc.zip' and unzip with the -a 
#   option.]
#--------------------------------------------------------------------------

obj =  attack.o endgame.o gencaps.o material.o   portable.o ui.o board.o eval.o\ genmove.o  misc.o openbook.o   search.o uistdio.o   canmove.o  fancy.o  human.o\ morder.o opening.o stdtime.o unmove.o crand.o  game.o lrntree.o move.o player.o\ transpos.o

# g++ 2.7.2 on Sun
#c++ = g++
#opt = -O3 -mv8 -fno-for-scope -Wall -W -Wno-unused

# g++ 2.7.2 on other
c++ = g++
opt = -O3 -fno-for-scope -Wall -W -Wno-unused

# CC on Sun
#c++ = CC
#opt = -fast

# CC on other
#c++ = CC
#opt = -O2

.SUFFIXES:.cpp.o

%.o:%.cpp
	$(c++) $(opt) -c $*.cpp

all: chenard

chenard: $(obj)
	$(c++) $(opt) -o chenard $(obj)

clean:
	rm $(obj)
