qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 07/10] roms: build edk2 firmware binaries and va


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH 07/10] roms: build edk2 firmware binaries and variable store templates
Date: Mon, 11 Mar 2019 07:09:57 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1

On 3/10/19 10:10 AM, Philippe Mathieu-Daudé wrote:
> Hi Laszlo,
> 
> On 3/9/19 5:48 PM, Philippe Mathieu-Daudé wrote:
>> On 3/9/19 1:48 AM, Laszlo Ersek wrote:
>>> Add the "efi" target to "Makefile".
>>>

>>> +
>>> +toolchain = $(shell source ./edk2-funcs.sh && qemu_edk2_get_toolchain $(1))
> 
> Well I finally figured out why building on Ubuntu fails. It default
> shell is dash, and 'source' is a bash builtin command. The portable
> equivalent is '.' (dot).
> 
> The fix is:
> 
> -- >8 --
> -toolchain = $(shell source ./edk2-funcs.sh && qemu_edk2_get_toolchain $(1))
> +toolchain = $(shell . ./edk2-funcs.sh && qemu_edk2_get_toolchain $(1))

Ouch - this changes my analysis in 1/10, where I argued that since the
file was only ever sourced by a bash script, its use of 'local' was
okay. Now that you are also sourcing it from /bin/sh via Makefile, you
HAVE to make edk2-funcs.sh portable to POSIX shell, by eliminating use
of 'local'.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]