#
# Makefile for ALSA low level driver (Linux version)
# Copyright (c) 1994-98 by Jaroslav Kysela <perex@jcu.cz>
#

TOPDIR   = ../..

include  $(TOPDIR)/Makefile.conf

TARGETS  = $(SNDVERSIONS) \
	   $(TOPDIR)/modules/snd-s3-86c617.o \
	   $(TOPDIR)/modules/snd-es1370.o \
	   $(TOPDIR)/modules/snd-es1938.o

SYMFILES = s3_86c617_export.c es1370_export.c ess_solo1_export.c
SONICVIBES = s3_86c617.o s3_86c617_export.o
AUDIOPCI = es1370.o es1370_export.o
ESSSOLO1 = ess_solo1.o ess_solo1_export.o

include  $(TOPDIR)/Rules.make

all: $(TARGETS)
	@echo
	@echo "ALSA lowlevel modules were sucessfully compiled."
	@echo

include  $(TOPDIR)/Rules1.make

$(TOPDIR)/modules/snd-s3-86c617.o: .depend $(SNDVERSIONS) $(SONICVIBES)
	$(LINKER) -o $@ $(SONICVIBES)

$(TOPDIR)/modules/snd-es1370.o: .depend $(SNDVERSIONS) $(AUDIOPCI)
	$(LINKER) -o $@ $(AUDIOPCI)

$(TOPDIR)/modules/snd-es1938.o: .depend $(SNDVERSIONS) $(ESSSOLO1)
	$(LINKER) -o $@ $(ESSSOLO1)

gcompile: $(TARGETS)

clean:
	rm -f .depend *.o *.orig snd.map snd.map? *~
	rm -f core $(SNDVERSIONS) $(SYMFILES)

.depend: $(SYMFILES)
	$(CPP) $(COPTS) $(INCLUDE) *.c > .depend

dep:	.depend

dummy:

#
# include a dependency file if one exists
#
ifeq (.depend,$(wildcard .depend))
include .depend
endif
