#
# /* LICENSE:  =========================================================================
#     RoboCup MSL Referee Box Source Code Release
#   -------------------------------------------------------------------------
#     Copyright (C) 2004 RoboCup Federation
#   -------------------------------------------------------------------------
#     This software is distributed under the GNU General Public License,
#     version 2.  If you do not have a copy of this licence, visit
#     www.gnu.org, or write: Free Software Foundation, 59 Temple Place,
#     Suite 330 Boston, MA 02111-1307 USA.  This program is distributed
#     in the hope that it will be useful, but WITHOUT ANY WARRANTY,
#     including MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
#   ------------------------------------------------------------------------- 
# 
#  */
#
CC=g++

CFLAGS = -g `gtk-config --cflags` 
LIBS += -lpthread `gtk-config --libs` -lgdk_pixbuf
LDFLAGS=


SRCS= main.cc gamecontrol.cc serial.cc tcpc_server.cc
OBJS= $(SRCS:.cc=.o) \

%.o: %.cc
	$(CC) -c $(CFLAGS) $(DEFS) -o $@ $<

.%.dep: %.cc
	@echo "Generating dependencies for: " $<
	@$(CC) -M $(CFLAGS) $< > $@.tmp
	@echo -n "$@ " >$@
	@cat $@.tmp >>$@
	@rm $@.tmp

all::referee

clean::
	rm -f *~ *.o
	rm -f referee


referee: $(OBJS)
	$(CC) -o $@ $(CFLAGS) $(LDFLAGS) $^ $(LIBS)

