* 2.6.29-rcx triviality - How to have foo.ko module with same name as foo.c source file
@ 2009-03-15 10:05 Boaz Harrosh
2009-03-15 10:12 ` Sam Ravnborg
0 siblings, 1 reply; 4+ messages in thread
From: Boaz Harrosh @ 2009-03-15 10:05 UTC (permalink / raw)
To: Sam Ravnborg, linux-kernel
Since sometime in the 2.6.29-rc I'm no longer able to produce an
out-of-tree module that has the same base-name as a source file.
This is what I had in 2.6.28:
<Kbuild>
obj-m += foo.o
</Kbuild>
Where foo.c is a source file in the same directory.
But since 2.6.29-rcx it will no longer build my foo.ko module. I
had to change it to:
<Kbuild>
foo_mod-y = foo.o
obj-m += foo_mod.o
</Kbuild>
Which changed my module name in scripts and packages.
[Q]
Is it possible to build a module with exact same base-name as it's single
source file?
P.S:
Just asking I realized that I can just add an "mv ..." command to my make file.
But is this expected behaviour?
Thanks in advance
Boaz
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: 2.6.29-rcx triviality - How to have foo.ko module with same name as foo.c source file
2009-03-15 10:05 2.6.29-rcx triviality - How to have foo.ko module with same name as foo.c source file Boaz Harrosh
@ 2009-03-15 10:12 ` Sam Ravnborg
2009-03-15 10:14 ` Boaz Harrosh
0 siblings, 1 reply; 4+ messages in thread
From: Sam Ravnborg @ 2009-03-15 10:12 UTC (permalink / raw)
To: Boaz Harrosh; +Cc: linux-kernel
On Sun, Mar 15, 2009 at 12:05:42PM +0200, Boaz Harrosh wrote:
> Since sometime in the 2.6.29-rc I'm no longer able to produce an
> out-of-tree module that has the same base-name as a source file.
>
> This is what I had in 2.6.28:
> <Kbuild>
> obj-m += foo.o
> </Kbuild>
> Where foo.c is a source file in the same directory.
>
> But since 2.6.29-rcx it will no longer build my foo.ko module. I
> had to change it to:
> <Kbuild>
> foo_mod-y = foo.o
> obj-m += foo_mod.o
> </Kbuild>
> Which changed my module name in scripts and packages.
We use the single .c file for a module with the same name as the
module all over the kernel.
What is more likely is that your module started to include an
additional sourcefile (antoehr .o) in which case you no longer
can have a source file sharing the name of the module.
> P.S:
> Just asking I realized that I can just add an "mv ..." command to my make file.
Using mv is no-no..
Sam
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: 2.6.29-rcx triviality - How to have foo.ko module with same name as foo.c source file
2009-03-15 10:12 ` Sam Ravnborg
@ 2009-03-15 10:14 ` Boaz Harrosh
2009-03-15 10:20 ` Boaz Harrosh
0 siblings, 1 reply; 4+ messages in thread
From: Boaz Harrosh @ 2009-03-15 10:14 UTC (permalink / raw)
To: Sam Ravnborg; +Cc: linux-kernel
Sam Ravnborg wrote:
> On Sun, Mar 15, 2009 at 12:05:42PM +0200, Boaz Harrosh wrote:
>> Since sometime in the 2.6.29-rc I'm no longer able to produce an
>> out-of-tree module that has the same base-name as a source file.
>>
>> This is what I had in 2.6.28:
>> <Kbuild>
>> obj-m += foo.o
>> </Kbuild>
>> Where foo.c is a source file in the same directory.
>>
>> But since 2.6.29-rcx it will no longer build my foo.ko module. I
>> had to change it to:
>> <Kbuild>
>> foo_mod-y = foo.o
>> obj-m += foo_mod.o
>> </Kbuild>
>> Which changed my module name in scripts and packages.
>
> We use the single .c file for a module with the same name as the
> module all over the kernel.
>
> What is more likely is that your module started to include an
> additional sourcefile (antoehr .o) in which case you no longer
> can have a source file sharing the name of the module.
>
>> P.S:
>> Just asking I realized that I can just add an "mv ..." command to my make file.
>
> Using mv is no-no..
>
> Sam
Hey hi, that was really fast ;) Thanks
I realize that in-tree it works for sure. It's when I use the "make -M ..." out-of-tree
and... No, I changed nothing, I had this, one liner, one source, one module and all of a sudden
it does not build. Let me check if it is a dependency problem (not rebuilding when things change)
or does it not build at all. Checking ...
Boaz
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: 2.6.29-rcx triviality - How to have foo.ko module with same name as foo.c source file
2009-03-15 10:14 ` Boaz Harrosh
@ 2009-03-15 10:20 ` Boaz Harrosh
0 siblings, 0 replies; 4+ messages in thread
From: Boaz Harrosh @ 2009-03-15 10:20 UTC (permalink / raw)
To: Sam Ravnborg; +Cc: linux-kernel
Boaz Harrosh wrote:
> Sam Ravnborg wrote:
>> On Sun, Mar 15, 2009 at 12:05:42PM +0200, Boaz Harrosh wrote:
>>> Since sometime in the 2.6.29-rc I'm no longer able to produce an
>>> out-of-tree module that has the same base-name as a source file.
>>>
>>> This is what I had in 2.6.28:
>>> <Kbuild>
>>> obj-m += foo.o
>>> </Kbuild>
>>> Where foo.c is a source file in the same directory.
>>>
>>> But since 2.6.29-rcx it will no longer build my foo.ko module. I
>>> had to change it to:
>>> <Kbuild>
>>> foo_mod-y = foo.o
>>> obj-m += foo_mod.o
>>> </Kbuild>
>>> Which changed my module name in scripts and packages.
>> We use the single .c file for a module with the same name as the
>> module all over the kernel.
>>
>> What is more likely is that your module started to include an
>> additional sourcefile (antoehr .o) in which case you no longer
>> can have a source file sharing the name of the module.
>>
>>> P.S:
>>> Just asking I realized that I can just add an "mv ..." command to my make file.
>> Using mv is no-no..
>>
>> Sam
>
> Hey hi, that was really fast ;) Thanks
>
> I realize that in-tree it works for sure. It's when I use the "make -M ..." out-of-tree
> and... No, I changed nothing, I had this, one liner, one source, one module and all of a sudden
> it does not build. Let me check if it is a dependency problem (not rebuilding when things change)
> or does it not build at all. Checking ...
>
> Boaz
>
Sorry please disregard it works again, I was probably too quick to make assumptions.
I did an hard clean and every thing started to work again. I'm not sure what it was.
Sorry for the noise
Boaz
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-03-15 10:21 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-15 10:05 2.6.29-rcx triviality - How to have foo.ko module with same name as foo.c source file Boaz Harrosh
2009-03-15 10:12 ` Sam Ravnborg
2009-03-15 10:14 ` Boaz Harrosh
2009-03-15 10:20 ` Boaz Harrosh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox