From f8e8994a0e62a0c548d7fda3dc17091eb218d50a Mon Sep 17 00:00:00 2001 From: Kai Germaschewski Date: Tue, 30 Apr 2002 00:10:32 -0500 Subject: [PATCH] ALSA Makefile cleanup: use $(mod-subdirs) Some places were doing: subdir-$(CONFIG_FOO) += foo ifeq ($(CONFIG_FOO),y) subdir-m += foo fi That can be expressed more easily as mod-subdirs := foo subdir-$(CONFIG_FOO) += foo --- sound/Makefile | 10 +++------- sound/core/Makefile | 4 ++-- sound/core/seq/Makefile | 4 +++- sound/drivers/Makefile | 3 ++- sound/isa/Makefile | 3 ++- sound/pci/Makefile | 3 ++- sound/synth/Makefile | 3 ++- 7 files changed, 16 insertions(+), 14 deletions(-) diff --git a/sound/Makefile b/sound/Makefile index 4dfb0bd378d3..6693fb33f245 100644 --- a/sound/Makefile +++ b/sound/Makefile @@ -5,21 +5,17 @@ O_TARGET := sound.o export-objs := sound_core.o +mod-subdirs := oss core i2c drivers isa pci ppc synth + obj-$(CONFIG_SOUND) += soundcore.o subdir-$(CONFIG_SOUND_PRIME) += oss - ifeq ($(CONFIG_SOUND_PRIME),y) - subdir-m += oss obj-y += oss/sounddrivers.o endif -_subdirs := core i2c drivers isa pci ppc arm synth - -subdir-$(CONFIG_SND) += $(_subdirs) - +subdir-$(CONFIG_SND) += core i2c drivers isa pci ppc arm synth ifeq ($(CONFIG_SND),y) - subdir-m += $(_subdirs) obj-y += core/core.o i2c/_i2c.o obj-y += drivers/drivers.o \ drivers/mpu401/_mpu401.o \ diff --git a/sound/core/Makefile b/sound/core/Makefile index 1622c5955ff8..9cee522fe2f3 100644 --- a/sound/core/Makefile +++ b/sound/core/Makefile @@ -7,6 +7,8 @@ O_TARGET := core.o export-objs := sound.o pcm.o pcm_lib.o rawmidi.o timer.o rtctimer.o hwdep.o +mod-subdirs := oss seq + snd-objs := sound.o init.o isadma.o memory.o info.o control.o misc.o \ device.o wrappers.o ifeq ($(CONFIG_SND_OSSEMUL),y) @@ -31,7 +33,6 @@ obj-$(CONFIG_SND_HWDEP) += snd-hwdep.o subdir-$(CONFIG_SND_MIXER_OSS) += oss subdir-$(CONFIG_SND_PCM_OSS) += oss ifeq ($(filter $(subdir-y),oss),oss) - subdir-m += oss obj-y += oss/oss.o endif @@ -39,7 +40,6 @@ obj-$(CONFIG_SND_PCM_OSS) += snd-pcm.o subdir-$(CONFIG_SND_SEQUENCER) += seq ifeq ($(CONFIG_SND_SEQUENCER),y) - subdir-m += seq obj-y += seq/sq.o endif diff --git a/sound/core/seq/Makefile b/sound/core/seq/Makefile index 4cdc54d63be3..cf07cd7b2658 100644 --- a/sound/core/seq/Makefile +++ b/sound/core/seq/Makefile @@ -5,9 +5,11 @@ O_TARGET := sq.o +mod-subdirs := instr + subdir-y := instr -subdir-m := $(subdir-y) obj-y += instr/instr.o + subdir-$(CONFIG_SND_SEQUENCER_OSS) += oss ifeq ($(CONFIG_SND_SEQUENCER_OSS),y) obj-y += oss/oss.o diff --git a/sound/drivers/Makefile b/sound/drivers/Makefile index dfc12fd98f3b..580f59f7b61f 100644 --- a/sound/drivers/Makefile +++ b/sound/drivers/Makefile @@ -5,8 +5,9 @@ O_TARGET := drivers.o +mod-subdirs := opl3 mpu401 + subdir-y := opl3 mpu401 -subdir-m := $(subdir-y) snd-dummy-objs := dummy.o snd-mtpav-objs := mtpav.o diff --git a/sound/isa/Makefile b/sound/isa/Makefile index 6b6dcf6b6c91..761e094da4d0 100644 --- a/sound/isa/Makefile +++ b/sound/isa/Makefile @@ -5,8 +5,9 @@ O_TARGET := isa.o +mod-subdirs := ad1816a ad1848 cs423x es1688 gus opti9xx sb wavefront + subdir-y := ad1816a ad1848 cs423x es1688 gus opti9xx sb wavefront -subdir-m := $(subdir-y) snd-als100-objs := als100.o snd-azt2320-objs := azt2320.o diff --git a/sound/pci/Makefile b/sound/pci/Makefile index dc5d225fe8a4..3571eb891dcb 100644 --- a/sound/pci/Makefile +++ b/sound/pci/Makefile @@ -5,8 +5,9 @@ O_TARGET := pci.o +mod-subdirs := ac97 ali5451 cs46xx emu10k1 korg1212 nm256 rme9652 trident ymfpci + subdir-y := ac97 ali5451 cs46xx emu10k1 korg1212 nm256 rme9652 trident ymfpci -subdir-m := $(subdir-y) snd-als4000-objs := als4000.o snd-cmipci-objs := cmipci.o diff --git a/sound/synth/Makefile b/sound/synth/Makefile index 63242d3d1511..22818d53912a 100644 --- a/sound/synth/Makefile +++ b/sound/synth/Makefile @@ -5,8 +5,9 @@ O_TARGET := synth.o +mod-subdirs := emux + subdir-y := emux -subdir-m := $(subdir-y) export-objs := util_mem.o -- 2.39.5