[OE-core] [PATCH] cryptodev kernel module recipe

Andreas Oberritter obi at opendreambox.org
Fri Oct 19 09:43:01 UTC 2012


On 19.10.2012 03:47, McClintock Matthew-B29882 wrote:
> On Thu, Oct 18, 2012 at 3:38 PM, Darren Hart <dvhart at linux.intel.com> wrote:
>>>>> +EXTRA_OEMAKE='KERNEL_DIR="${STAGING_KERNEL_DIR}" PREFIX="${D}"'
>>>>
>>>> modules.bbclass already sets KERNEL_PATH and KERNEL_SRC, perhaps you
>>>> could use one of those?
>>>
>>> cryptodev Makefile does not use these it uses KERNEL_DIR in it's
>>> Makefile for whatever reason. Getting an upstream project to change is
>>> more difficult.
>>
>> I think this is the second reference to KERNEL_DIR in an external module,
>> perhaps module.bbclass should add that to it's list of predefined names for
>> the STAGING_KERNEL_DIR.
> 
> Fine with me, but not sure how its worth it quite yet...

I don't think we should add more privately defined variables to
module.bbclass.

I'd rather use something like the following as the default, which should
work for all recipes where ${S} points to the directory containing the
top-level Kbuild file and is independent of those variables:

do_compile() {
        unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
        oe_runmake -C "${STAGING_KERNEL_DIR}" SUBDIRS="${S}" modules
}
do_install() {
        unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
        oe_runmake -C "${STAGING_KERNEL_DIR}" SUBDIRS="${S}"
DEPMOD="echo" INSTALL_MOD_PATH="${D}" modules_install
}

That's not an option for cryptodev, though, because unlike most recipes
inheriting module.bbclass, cryptodev not only installs modules, but also
header files.

Regards,
Andreas




More information about the Openembedded-core mailing list