[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Installation directory for modules

When I run the Makefile below it installs the module in :


As far as I can find out, this is the expected behaviour from the kbuild Makefiles.

However, modprobe looks for modules in

/lib/modules/`uname -r`.

How can I get the modules to install in this directory?

John Talbut


ifeq ($(KDIR),)
	KDIR :=/lib/modules/`uname -r`/source
EXTRA_CFLAGS := -DNDIS_MINIPORT_DRIVER -DOS_LINUX -I${obj} -nostdinc -Wno-multichar -DPIM_DEBUG -fno-builtin -DMODULE -D__KERNEL__ -O2

	echo "MODLIB = ${MODLIB}"
	make CnxADSL.ko

obj-m := CnxADSL.o
CnxADSL-objs := ARMAbstract.o BufMgmt.o CardAL.o CardALADSLDiag.o CardALBdDp.o CardALBd.o CardALTigris.o \
		CardALTigrisDiag.o CardALTigrisLC.o CardMgmt.o \
CardMgmtLink.o CardMgmtVc.o CellDataTest.o CellDataTestMgmt.o ChipALBusCtlP46.o \
		ChipALCdsl.o ChipALDMAChanP46.o ChipALIoP46.o CardALTigrisDp.o \
		CardALTigrisHal.o ChipALSEmw.o CnxTTY.o FrameAl.o FrameALAAL.o \
		FrameALATM.o FrameALATMOAM.o FrameALATMShaper.o FrameALHec.o KThread.o \
		LnxTools.o SmLnxIf.o SmSysIf.o UtilStr.o UtilTmr.o dpcontroller.o.new

	make -C $(KDIR) M=`pwd` modules

install: CnxADSL.ko
	make -C ${KDIR} M=`pwd` modules_install

	rm -f *.o *~ core .depend dep *.ko CnxADSL.mod.c .*.cmd
	rm -rf .tmp_versions/

Reply to: