#
#    Makefile for
#    Nethack-Player/Recorder Version 1.0
#    Copyright (C) 2000 by Helge Dennhardt
#    <Helge.Dennhardt@gmx.de>
#
#    This program is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program; if not, write to the Free Software
#    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
#

CC=gcc#   Insert your favourite compiler here.
CCFLAGS=# Insert your favourite compiler options here.

# These are the main executables. Type "make" or "make all" to start building it.
all: nh_recorder nh_player

# This is a list of all needed object files.
RECORDER_OBJECT_FILES = nh_recorder.o clock.o 
PLAYER_OBJECT_FILES   = nh_player.o   clock.o

# The object files are all built here.
nh_recorder.o: nh_recorder.c clock.h
	$(CC) $(CCFLAGS) -c nh_recorder.c
nh_player.o: nh_player.c clock.h
	$(CC) $(CCFLAGS) -c nh_player.c
clock.o: clock.h
	$(CC) $(CCFLAGS) -c clock.c

# After the object files are built, they are all linked here.
nh_recorder: $(RECORDER_OBJECT_FILES)
	$(CC) $(CCFLAGS) $(RECORDER_OBJECT_FILES) -o nh_recorder
	@echo "Finished. Type \"nh_recorder\" to get a short help."
nh_player: $(PLAYER_OBJECT_FILES)
	$(CC) $(CCFLAGS) $(PLAYER_OBJECT_FILES) -o nh_player
	@echo "Finished. Type \"nh_player\" to get a short help."

# If you want to delete all intermediate files except the main executables, type "make clean".
clean: 
	@rm -f *~ *.o 2>/dev/null

# If you want to delete all files that were built, type "make spotless".
spotless: clean
	@rm -f nh_recorder nh_player 2>/dev/null










 














