#
# makefile - simple makefile for the Lexmark 2050 color driver
#
# Copyright 1999, Christian Kornblum
#
#

# Important compiler and linker options
CC=gcc
LD=gcc
CFLAGS=-g -O2
LDFLAGS=-g -O2

# Required libraries
LDLIBS=

# Source files and modules
SRC=c2050.c
SHAREDHEADER=
MOD=$(SRC:.c=.o)

# Standard production rule
.c.o: 
	$(CC) $(CFLAGS) -c $<

# make all
all: c2050

# linking the modules
c2050: $(MOD)
	$(LD) $(LDFLAGS) $(LDLIBS) -o $@ $(MOD) 

# dependencies, here a shared header
$(SRC): $(SHAREDHEADER) 

# clear up the mess to start over
clean: 
	rm -f *.o *~ core c2050

#install the driver
install: all
	cp c2050 /usr/bin
	chmod a+x /usr/bin/c2050
	cp ps2lexmark /usr/bin
	chmod a+x /usr/bin/ps2lexmark
