2 Replies Latest reply on Aug 7, 2014 2:11 PM by Rushang.Karia

    How to install or copy the driver i.e .ko file to a particular location via makefile?


      This is my makefile..

      ifneq ($(KERNELRELEASE),)

      obj-m := dmcdus_dd.o


      KDIR := /usr/src/linux-headers-3.13.0-24-generic/


          $(MAKE) INSTALL_MOD_DIR=kernel/drivers/input/touchscreen -C $(KDIR) M=$$PWD modules_install




          rm -rf *.o *~ core .depend .*.cmd *.ko *.mod.c .tmp_versions sample Module.symvers



      i have specified my required path where i have to move my dmcdus_dd.ko file using INSTALL_MOD_DIR & install it by modules_install. when i type make in the console i get the following results in the console..


      make INSTALL_MOD_DIR=kernel/drivers/input/touchscreen -C /usr/src/linux-headers-3.5.0-49-generic/ M=$PWD modules_install

      make[1]: Entering directory `/usr/src/linux-headers-3.5.0-49-generic'

        DEPMOD  3.5.0-49-generic

      make[1]: Leaving directory `/usr/src/linux-headers-3.5.0-49-generic'


      but when i go to the location "/lib/modules/3.5.0-49-generic/kernel/drivers/input/touchscreen" i dont see dmcdus.ko file in that directory... How can i copy my driver to that location?