ACK/Cmnt: [pc-snap PATCH] snapcraft.yaml: avoid shell expansion in snapcraft.yaml

Stefan Bader stefan.bader at canonical.com
Thu Jul 22 08:28:13 UTC 2021


On 21.07.21 11:19, Dimitri John Ledkov wrote:
> As per schema, make-paramemters are strings, not interpreted/evaluated
> values. Move efi vs vmlinuz choice to build-environment with
> declarative advanced grammar to select efi on amd64 only.
> 
> Signed-off-by: Dimitri John Ledkov <dimitri.ledkov at canonical.com>
Acked-by: Stefan Bader <stefan.bader at canonical.com>
> ---

I would assume this is for Focal/uc-20 only as I have not that much confidence 
that any "advanced grammer" would be understood in older series. Please clarify 
if that is not true.

-Stefan

> 
>   This is failing to build with stable snapcraft so pushing this to get
>   the current set of snaps to build. Tested with local snapcraft build.
> 
>   snapcraft.yaml | 6 +++++-
>   1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/snapcraft.yaml b/snapcraft.yaml
> index 525d2fa..b402017 100644
> --- a/snapcraft.yaml
> +++ b/snapcraft.yaml
> @@ -12,10 +12,14 @@ parts:
>       source-type: git
>       source-branch: master
>       plugin: make
> +    build-environment:
> +      - on amd64:
> +          - KERNEL_IMAGE_FORMAT: efi
> +      - else:
> +          - KERNEL_IMAGE_FORMAT: vmlinuz
>       make-parameters:
>         - KERNEL_SOURCE=focal:linux-uc20-efi
>         - KERNEL=linux-pc-image
> -      - KERNEL_IMAGE_FORMAT=$(if $(filter x86_64,$(shell uname -a)),efi,vmlinuz)
>         - PROPOSED=true
>       build-packages:
>         - debootstrap
> 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20210722/b40e170f/attachment-0001.sig>


More information about the kernel-team mailing list