#
# Makefile for ALSA
# Copyright (c) 1999 by Jaroslav Kysela <perex@suse.cz>
#

EXTRA_CFLAGS := -I../../include

SUB_DIRS     :=
MOD_SUB_DIRS :=
ALL_SUB_DIRS :=

L_TARGET     := snd_gus.a
M_OBJS	     :=
L_OBJS       :=
LX_OBJS      :=
MIX_OBJS     :=

GUSX     = gus.o
GUS1	 = gus_io.o gus_irq.o gus_timer.o \
           gus_mem.o gus_mem_proc.o gus_dram.o gus_dma.o gus_volume.o \
           gus_pcm.o gus_mixer.o \
	   gus_uart.o \
           gus_reset.o
GUSSYNTH = gus_synth.o gus_sample.o gus_simple.o gus_instr.o

ifeq ($(CONFIG_SND_GUS),y)
  LX_OBJS += $(GUSX)
  L_OBJS += $(GUS1)
else
  ifeq ($(CONFIG_SND_GUS),m)
    M_OBJS += snd-gus.o
    MIX_OBJS += $(GUSX)
  endif
endif

ifeq ($(CONFIG_SND_SEQUENCER),y)
  ifeq ($(CONFIG_SND_GUS),y)
    L_OBJS += $(GUSSYNTH)
  else
    ifeq ($(CONFIG_SND_GUS),m)
      M_OBJS += snd-synth-gus.o
    endif
  endif
endif

include $(TOPDIR)/Rules.make

snd-gus.o: $(GUSX) $(GUS1)
	$(LD) $(LD_RFLAG) -r -o $@ $(GUSX) $(GUS1)

snd-synth-gus.o: $(GUSSYNTH)
	$(LD) $(LD_RFLAG) -r -o $@ $(GUSSYNTH)
