public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Makefile problem
@ 2003-12-19 13:25 Michele RECCANELLO
  0 siblings, 0 replies; 3+ messages in thread
From: Michele RECCANELLO @ 2003-12-19 13:25 UTC (permalink / raw)
  To: Chandler, Neville, 'Samuel Flory'; +Cc: linux-kernel

Linux dedalus 2.4.20-8custom #2 lun dic 15 11:17:11 CET 2003 i586 i586
i386 GNU/Linux
 
Gnu C                  3.2.2
Gnu make               3.79.1
util-linux             2.11y
mount                  2.11y
modutils               2.4.22
e2fsprogs              1.32
jfsutils               1.0.17
reiserfsprogs          3.6.4
pcmcia-cs              3.1.31
PPP                    2.4.1
isdn4k-utils           3.1pre4
Linux C Library        2.3.2
Dynamic linker (ldd)   2.3.2
Procps                 2.0.11
Net-tools              1.60
Kbd                    1.08
Sh-utils               4.5.3
Modules Loaded         mga agpgart 8139too mii ext3 jbd keybdev mousedev
input hid usb-ohci usbcore

I 've got RedHat 9 on K6 550 with 192MB, 40GB Hard disk.
Command "make menuconfig" not set correct link in include directory and
show this messagge:

"/bin/sh: line 1: cd: include: No such file or directory."

I modify Makefile at line 278
before: (cd include; ln -sf asm-$(ARCH) asm)
after: (cd ./include; ln -sf asm-$(ARCH) asm)

It work! There is a problem when make run a cd command, but I don't know why
Thera is similar problem in redhat 8, slackware 9.1 end Mandrake 9.2 and 
when I compiling source code and make exec a cd command.


Ciao e grazie per ogni suggerimento. Merry Xmas.



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Makefile problem
@ 2006-03-21 11:21 cranium2003
  2006-03-21 11:42 ` Arjan van de Ven
  0 siblings, 1 reply; 3+ messages in thread
From: cranium2003 @ 2006-03-21 11:21 UTC (permalink / raw)
  To: kernel newbies; +Cc: kernerl mail

Hi,
   I have some Makefile questions
1)Why a kernel module in 2.6 kernel cannot be compiled
with single gcc command? Why it requires Makefile in
current directory so that i can use Makefile?

2) why following command used to compile 2.4 kernel
module fails on 2.6 kernel
gcc  -D__KERNEL__ -DMODULE -DLINUX -O2 -Wall
-Wstrict-prototypes -I/lib/modules/`uname
-r`/build/include -c -o example.ko example.c

3) Is that because of gcc cannot create .ko file??
then what header changes occurred from .o to .ko
module implementaion?

Thanks & Regards,
cranium



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Makefile problem
  2006-03-21 11:21 cranium2003
@ 2006-03-21 11:42 ` Arjan van de Ven
  0 siblings, 0 replies; 3+ messages in thread
From: Arjan van de Ven @ 2006-03-21 11:42 UTC (permalink / raw)
  To: cranium2003; +Cc: kernel newbies, kernerl mail

On Tue, 2006-03-21 at 03:21 -0800, cranium2003 wrote:
> Hi,
>    I have some Makefile questions
> 1)Why a kernel module in 2.6 kernel cannot be compiled
> with single gcc command? Why it requires Makefile in
> current directory so that i can use Makefile?
> 
> 2) why following command used to compile 2.4 kernel
> module fails on 2.6 kernel
> gcc  -D__KERNEL__ -DMODULE -DLINUX -O2 -Wall
> -Wstrict-prototypes -I/lib/modules/`uname
> -r`/build/include -c -o example.ko example.c

because it's broken and isn't using the same CFLAGS as the kernel is.
Read Documentation/kbuild/*

You *HAVE* to use the same CFLAGS as the rest of the kernel.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-03-21 11:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-12-19 13:25 Makefile problem Michele RECCANELLO
  -- strict thread matches above, loose matches on Subject: below --
2006-03-21 11:21 cranium2003
2006-03-21 11:42 ` Arjan van de Ven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox