Suppose that the driver snd-xyz have several source files. They are located in the new subdirectory, pci/xyz.
Add a new directory (xyz
) in
alsa-driver/pci/Makefile
as below
obj-$(CONFIG_SND) += xyz/
Under the directory xyz
, create a Makefile
Example 15.1. Sample Makefile for a driver xyz
ifndef SND_TOPDIR SND_TOPDIR=../.. endif include $(SND_TOPDIR)/toplevel.config include $(SND_TOPDIR)/Makefile.conf snd-xyz-objs := xyz.o abc.o def.o obj-$(CONFIG_SND_XYZ) += snd-xyz.o include $(SND_TOPDIR)/Rules.make
Create the Kconfig entry
This procedure is as same as in the last section.
Run cvscompile script to re-generate the configure script and build the whole stuff again.