[OE-core] [PATCH 1/2 v2] image_types: Add elf image type

Raymond Danks ray.danks at se-eng.com
Fri Jun 29 20:01:09 UTC 2012


On 06/29/2012 11:45 AM, Darren Hart wrote:
>
> On 06/29/2012 08:41 AM, Raymond Danks wrote:
>> On x86, an ELF image file may be stored as a coreboot payload.
>> The image file is constructed, using the mkelfimage utility,
>> from a kernel and an initrd.
>>
>> Signed-off-by: Raymond Danks<ray.danks at se-eng.com>
>> ---
>> This was originally submitted to the openembedded project:
>> http://patches.openembedded.org/patch/7689/
>>
>> v2:
>>   Include KERNEL_IMAGETYPE for location of ELF_KERNEL
>>
>>   meta/classes/image_types.bbclass |   18 +++++++++++++++++-
>>   1 files changed, 17 insertions(+), 1 deletions(-)
>>
>> diff --git a/meta/classes/image_types.bbclass b/meta/classes/image_types.bbclass
>> index 55f122e..12419f4 100644
>> --- a/meta/classes/image_types.bbclass
>> +++ b/meta/classes/image_types.bbclass
>> @@ -7,6 +7,12 @@ def get_imagecmds(d):
>>       ctypes = d.getVar('COMPRESSIONTYPES', True).split()
>>       cimages = {}
>>
>> +    if "elf" in alltypes:
>> +        alltypes.remove("elf")
>> +        if "cpio.gz" not in alltypes:
>> +                alltypes.append("cpio.gz")
>> +        alltypes.append("elf")
>> +
>>       # Filter out all the compressed images from types
>>       for type in alltypes:
>>           basetype = None
>> @@ -173,6 +179,14 @@ IMAGE_CMD_cpio () {
>>   	cd ${IMAGE_ROOTFS}&&  (find . | cpio -o -H newc>${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio)
>>   }
>>
>> +ELF_KERNEL ?= ${STAGING_DIR_HOST}/kernel/${KERNEL_IMAGETYPE}
> This should be ${STAGING_KERNEL_DIR} I believe. I have a patch series
> under review currently which would break the above as it is now in
> /usr/src/kernel-headers
>
> Note that you could also collect this from the DEPLOY_DIR_IMAGE, which
> is probably more appropriate for assembling images
>
> Thanks,
>
Yes.  This appears to work:
ELF_KERNEL ?= ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}

I'm regenerating the patch now.





More information about the Openembedded-core mailing list