On Tue, Feb 20, 2018 at 02:15:32PM +0100, Jan Kiszka wrote:
> On 2018-02-20 11:55, Farhat wrote:
> > From: Farhat-Abbas <[email protected]>
> > 
> > Required artifacts, to be copied, are available in
> > 'DEPLOY_DIR_IMAGE' directory pointed to by 'kernel_dir'. The recipe
> > efibootguard.bb stages efibootguard bootloader to 'DEPLOY_DIR_IMAGE'.
> > So, efibootguard should be copied from 'kernel_dir'. OE-Core's script 
> > 'oe-core/scripts/lib/wic/plugins/source/bootimg-efi.py' is used as 
> > reference.
> > Also, 'HDDDIR' has been removed from 'WICVARS' & won't be accessible in 
> > scripts.
> > 'HDDDIR' was populated ONLY if 'NOHDD=1' but images can be built w/o it, so
> > it was optional but 'DEPLOY_DIR_IMAGE' is always populated with the 
> > required artifacts.
> > 
> > See following commits in 'oe-core' for reference.
> > https://github.com/openembedded/openembedded-core/commit/afc486b6316f1118c8dcc74a5e217bb217dd1f85
> > https://github.com/openembedded/openembedded-core/commit/2457ea5338f7309316b474562b4723e8cb09286d
> > https://github.com/openembedded/openembedded-core/commit/48a5d67d7cafdeac821e6f35bea380521ef017d5
> > 
> > Signed-off-by: Farhat-Abbas <[email protected]>
> > ---
> >  scripts/lib/wic/plugins/source/efibootguard-boot.py |  8 ++++----
> >  scripts/lib/wic/plugins/source/efibootguard-efi.py  | 10 +++++-----
> >  2 files changed, 9 insertions(+), 9 deletions(-)
> > 
> > diff --git a/scripts/lib/wic/plugins/source/efibootguard-boot.py 
> > b/scripts/lib/wic/plugins/source/efibootguard-boot.py
> > index bad7c27..f4326ae 100644
> > --- a/scripts/lib/wic/plugins/source/efibootguard-boot.py
> > +++ b/scripts/lib/wic/plugins/source/efibootguard-boot.py
> > @@ -82,10 +82,10 @@ class EfibootguardBootPlugin(SourcePlugin):
> >          'prepares' the partition to be incorporated into the image.
> >          In this case, prepare content for an EFI (grub) boot partition.
> >          """
> > -        if not bootimg_dir:
> > -            bootimg_dir = get_bitbake_var("HDDDIR")
> > -            if not bootimg_dir:
> > -                msger.error("HDDDIR not set, exiting\n")
> > +        if not kernel_dir:
> > +            kernel_dir = get_bitbake_var("DEPLOY_DIR_IMAGE")
> > +            if not kernel_dir:
> > +                msger.error("DEPLOY_DIR_IMAGE not set, exiting\n")
> >                  os.exit(1)
> >  
> >          staging_kernel_dir = kernel_dir
> > diff --git a/scripts/lib/wic/plugins/source/efibootguard-efi.py 
> > b/scripts/lib/wic/plugins/source/efibootguard-efi.py
> > index 8a33412..62e283a 100644
> > --- a/scripts/lib/wic/plugins/source/efibootguard-efi.py
> > +++ b/scripts/lib/wic/plugins/source/efibootguard-efi.py
> > @@ -55,10 +55,10 @@ class EfibootguardEFIPlugin(SourcePlugin):
> >          'prepares' the partition to be incorporated into the image.
> >          In this case, prepare content for an EFI (grub) boot partition.
> >          """
> > -        if not bootimg_dir:
> > -            bootimg_dir = get_bitbake_var("HDDDIR")
> > -            if not bootimg_dir:
> > -                msger.error("HDDDIR not set, exiting\n")
> > +        if not kernel_dir:
> > +            kernel_dir = get_bitbake_var("DEPLOY_DIR_IMAGE")
> > +            if not kernel_dir:
> > +                msger.error("DEPLOY_DIR_IMAGE not set, exiting\n")
> >  
> >          staging_kernel_dir = kernel_dir
> >  
> > @@ -67,7 +67,7 @@ class EfibootguardEFIPlugin(SourcePlugin):
> >          install_cmd = "install -d %s/EFI/BOOT" % hdddir
> >          exec_cmd(install_cmd)
> >  
> > -        cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (bootimg_dir, hdddir)
> > +        cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (kernel_dir, hdddir)
> >          exec_cmd(cp_cmd, True)
> >  
> >          # Calculate the number of extra blocks to be sure that the
> > 
> 
> Am I right that this commit should go into the pyro and rocko branches,
> but not into morty?
> 
> Andreas, could you do a review?
> 
Yes I can, but I am not sure if I can this week.

Andreas

> Thanks,
> Jan
> 
> -- 
> Siemens AG, Corporate Technology, CT RDA IOT SES-DE
> Corporate Competence Center Embedded Linux

-- 
Andreas Reichel 
Dipl.-Phys. (Univ.) 
Software Consultant

[email protected] 
+49-174-3180074

TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterföhring
Geschäftsführer: Henrik Klagges, Dr. Robert Dahlke, Gerhard Müller
Sitz: Unterföhring * Amtsgericht München * HRB 135082

-- 
You received this message because you are subscribed to the Google Groups "EFI 
Boot Guard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/efibootguard-dev/20180220151922.GA26896%40tng.Speedport_W723_V_Typ_A_1_01_009.
For more options, visit https://groups.google.com/d/optout.

Attachment: signature.asc
Description: PGP signature

Reply via email to