#    CDplayer 1.1 - command line Audio CDplayer
#    Copyright (C) 1993,1994 Mark Buckaway (mark@datasoft.com)
# 
#    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., 675 Mass Ave, Cambridge, MA 02139, USA.

# Change this to your liking... -O2 gives full optimization
CFLAGS= -O2
#CFLAGS=-g
CC=gcc

all: config lib cdplayer

cdplayer:	cdplayer.o
	$(CC) $(CFLAGS) $(DEFINES) cdplayer.o -o cdplayer -L . -lnec

lib:	libnec.a

libnec.a:	nec_ioctl.o
	ar -r libnec.a nec_ioctl.o

config:	config.h 

config.h:
	@sh Configure

clean:	
	rm -f *.o *.a core cdplayer

mrproper: clean
	rm -f .install config.h

install: all
	@sh install.sh

tar: mrproper
	rm -f CDplayer-1.1.tar.gz CDplayer.uue
	tar -cvvzf CDplayer-1.1.tar.gz *

uuencode: tar
	uuencode CDplayer-1.1.tar.gz CDplayer-1.1.tar.gz >CDplayer.uue
	@echo "CDplayer.uue created."
