lkml.org 
[lkml]   [2009]   [Jan]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Getting out-of-kernel modules compiled
On Wed, Jan 21, 2009 at 10:57:25AM -0500, linux-os (Dick Johnson) wrote:
>
> Back in 2004, we make the following to compile
> out-of-kernel modules. It worked.
>
> Now, the kernel build doesn't "know" how to handle "asm.S"
> files and always thinks a "name.o" file is the result of
> a "name.c" file, so I can't buld them no matter how hard
> I try!
>
> What do I need to do????
>
> #
> # Project Makefile for kernel versions over 6
> # Created 05-OCT-2004 Richard B. Johnson
> #
>
> VER := $(shell uname -r)
> PWD := $(shell pwd)
>
> all: driver
>
> driver:
> make V=1 -C /usr/src/linux-$(VER) SUBDIRS=$(PWD) modules
>
> rtc_hwr.o: rtc_hwr.S
> as -o $@ $<
>
> obj-m = rtc.o
> obj-m += rtc_hwr.o

kbuild has never (at least for a very long time) not
supported to implement a module only in assembler.

So you will have no luck trying to build the
module rtc_hrw.ko

What you can do is to define a module like htis:
obj-m := dick.o
dick-y := rtc.o rtc_hwr.o

This will properly build rtc_hwr.S => rtc_hwr.o

Sam


\
 
 \ /
  Last update: 2009-01-21 18:23    [W:0.060 / U:0.356 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site