Announcement

Collapse
No announcement yet.

Loadable Kernel Module - Cannot find header file module.h

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Loadable Kernel Module - Cannot find header file module.h

    Hullo All,

    I am a newbie to Linux, and getting enormously interested ever since I have been introduced to Linux through a school course.

    Coming to my problem, I am trying to create a loadable kernel module, a simple dummy module, just to get a hang of building modules.

    When I try to compile my module C file, I get an error:

    Code:
    Cannot find file or directory: linux\module.h
    It is not present in the include directory, but when I searched for it, I found it in another path: /usr/src/linux-heders-2.6.22-14/include/linux/

    What should I do to compile my module? How do I make the header file available to the module code?
    I am using Kubuntu, and Linux 2.6 by the way.

    Thanks in advance.


    #2
    Re: Loadable Kernel Module - Cannot find header file module.h

    Do you have kernel-package installed?
    From what I remember module.h is included (with kernel-source) as a dependency.

    Comment


      #3
      Re: Loadable Kernel Module - Cannot find header file module.h

      What is meant by kernel-package installing?
      The only installation I did was installing Kubuntu through Wubi installer. Could you please tell me what this kernel package is and how I install it? Thanks.

      Comment


        #4
        Re: Loadable Kernel Module - Cannot find header file module.h

        Perhaps this will help:
        http://www.cyberciti.biz/tips/build-...urce-tree.html

        There is also "full" documentation available:
        http://tldp.org/LDP/lkmpg/2.6/html/index.html
        (warning: not what you could call "entry level" stuff)

        Comment

        Working...
        X