mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: anil dahiya <ak_ait@yahoo.com>
Cc: linux-kernel@vger.kernel.org, kernelnewbies@nl.linux.org
Subject: Re: making makefile for 2.6 kernel
Date: Sat, 12 Nov 2005 23:19:04 +0100	[thread overview]
Message-ID: <20051112221904.GA10228@mars.ravnborg.org> (raw)
In-Reply-To: <20051112151652.83848.qmail@web60221.mail.yahoo.com>

On Sat, Nov 12, 2005 at 07:16:52AM -0800, anil dahiya wrote:
> Hi 
> I want to makefile for my kernel module..
> 1.c 2.c 3.c files are places in /home/anil folder but
> these files contain .h (hearder)files from 3 different
> directory 1) /home/include 2) /root/incluent 3)
> /opt/include
> 
> can u suggest me a makefile to generate a common
> module target.ko using these .C and .h files.

Makefile
obj-m := foo.o
foo-y := 1.o 2.o 3.o

EXTRA_CFLGAS := -I/home/include -I/root/incluent -I/opt/include


And then build the module with:
make -C $KERNEL_SRC M=`pwd`

See Documentation/kbuild/makefiles.txt for reference.
Note: Kernel being pointed out must be a fully build kernel

	Sam

  reply	other threads:[~2005-11-12 22:17 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-10 23:47 [PATCH] getrusage sucks Hua Zhong (hzhong)
2005-11-11  0:23 ` Claudio Scordino
2005-11-11  0:32   ` Magnus Naeslund(f)
2005-11-11  1:11     ` Claudio Scordino
2005-11-11 13:30       ` Alan Cox
2005-11-11 22:38         ` Claudio Scordino
2005-11-11 23:23           ` Alan Cox
2005-11-11 23:02             ` Chris Wright
2005-11-11 23:44               ` David Wagner
2005-11-12  0:53                 ` Chris Wright
2005-11-12  6:37                   ` David Wagner
2005-11-11 23:58               ` Alan Cox
2005-11-11 23:43                 ` Claudio Scordino
2005-11-11 23:49                   ` dean gaudet
2005-11-12  1:10                     ` Chris Wright
2005-11-12 15:10                       ` making makefile for 2.6 kernel anil dahiya
2005-11-12 15:16                       ` anil dahiya
2005-11-12 22:19                         ` Sam Ravnborg [this message]
2005-11-13  1:34                       ` [PATCH] getrusage sucks Claudio Scordino
2005-11-15 16:56                       ` Claudio Scordino
2005-11-15 17:00                       ` New getrusage Claudio Scordino
2005-11-11 23:08             ` [PATCH] getrusage sucks Claudio Scordino
2005-11-11 23:41           ` David Wagner
2005-11-15  1:08       ` Peter Chubb

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20051112221904.GA10228@mars.ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=ak_ait@yahoo.com \
    --cc=kernelnewbies@nl.linux.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome