From: Sam Ravnborg <sam@ravnborg.org>
To: "linux-os (Dick Johnson)" <linux-os@analogic.com>
Cc: Linux kernel <linux-kernel@vger.kernel.org>
Subject: Re: Getting out-of-kernel modules compiled
Date: Wed, 21 Jan 2009 18:22:48 +0100 [thread overview]
Message-ID: <20090121172248.GA3661@uranus.ravnborg.org> (raw)
In-Reply-To: <Pine.LNX.4.61.0901211052020.16591@chaos.analogic.com>
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
next prev parent reply other threads:[~2009-01-21 17:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-21 15:57 Getting out-of-kernel modules compiled linux-os (Dick Johnson)
2009-01-21 17:22 ` Sam Ravnborg [this message]
2009-01-21 17:56 ` linux-os (Dick Johnson)
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=20090121172248.GA3661@uranus.ravnborg.org \
--to=sam@ravnborg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-os@analogic.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.