Re: [PATCH] framework for building modules externally

2009-04-13 Thread Robert Millan
On Sat, Apr 11, 2009 at 01:19:14AM +0200, phcoder wrote: Robert Millan wrote: On Wed, Nov 05, 2008 at 07:57:38AM +0100, Christian Franke wrote: Alternative: Export a symbol describing the ABI version in kernel (grub_abi_3_14). That requires more bytes than a 32-bit integer. You export

Re: __FILE__ (Re: [PATCH] framework for building modules externally)

2008-11-06 Thread Christian Franke
Robert Millan wrote: On Wed, Nov 05, 2008 at 10:41:20PM +0100, Christian Franke wrote: PS: The current use of __FILE__ may also add extra unexpected size: For packaging, configure is often run outside of $srcdir with a absolute path name. This may result in long __FILE__ strings, like

Re: [PATCH] framework for building modules externally

2008-11-05 Thread Robert Millan
Hi, Since it looks like the ABI part inspires more need for debate/discussion, I propose merging the rest first. Support for ABI tracking is not essential for building external modules (in Debian, it's barely necessary). Here's a new patch. If nobody objects, I'll commit it in a few days. --

Re: [PATCH] framework for building modules externally

2008-11-05 Thread Robert Millan
On Wed, Nov 05, 2008 at 07:57:38AM +0100, Christian Franke wrote: Alternative: Export a symbol describing the ABI version in kernel (grub_abi_3_14). That requires more bytes than a 32-bit integer. Access this symbol in each module (this can be hidden in GRUB_MOD_INIT). And this adds

Re: [PATCH] framework for building modules externally

2008-11-04 Thread Robert Millan
On Tue, Nov 04, 2008 at 08:55:52PM +0200, Vesa Jääskeläinen wrote: Robert Millan wrote: On Sat, Nov 01, 2008 at 01:32:29PM +0100, Robert Millan wrote: Hi, Attached patch makes it possible to build modules externally, by: - Installing headers in system include dir. - Exporting

Re: [PATCH] framework for building modules externally

2008-11-04 Thread Vesa Jääskeläinen
Robert Millan wrote: On Tue, Nov 04, 2008 at 08:55:52PM +0200, Vesa Jääskeläinen wrote: Robert Millan wrote: On Sat, Nov 01, 2008 at 01:32:29PM +0100, Robert Millan wrote: Hi, Attached patch makes it possible to build modules externally, by: - Installing headers in system include dir.

Re: [PATCH] framework for building modules externally

2008-11-04 Thread Robert Millan
On Tue, Nov 04, 2008 at 09:13:43PM +0200, Vesa Jääskeläinen wrote: Did you have some plan how to automate this ABI versioning :) ? If it is not automated I can almost guarantee that we get it wrong at one point of time :) It's not a big problem, at least not for my intended use of this

Re: [PATCH] framework for building modules externally

2008-11-04 Thread Christian Franke
Robert Millan wrote: ... How do you treat differences in ABI ? Dis-allow loading of module with different value of ABI ? Or were you planning that module itself adapts to different versions of GRUB 2 ABI's? The module itself could: GRUB_MOD_INIT(foo) { if (grub_abi != GRUB_ABI) {