[SeaBIOS] iasl-option not working

Michael S. Tsirkin mst at redhat.com
Thu Aug 30 07:38:06 CEST 2012


On Wed, Aug 29, 2012 at 09:38:00PM -0400, Kevin O'Connor wrote:
> Hi Michael,
> 
> I was running through the SeaBIOS release checks when I found that the
> new iasl-option code in the Makefile seems to choke on older versions
> of iasl (for example, version 20120123 as shipped with fc13).  Can you
> verify if the iasl detection still works properly for you with the
> patch below?
> 
> -Kevin
> 
> 
> >From 51755c3b5ed9dcdfdef8cee56631d68642bde416 Mon Sep 17 00:00:00 2001
> From: Kevin O'Connor <kevin at koconnor.net>
> Date: Wed, 29 Aug 2012 21:27:37 -0400
> Subject: [PATCH] Make iasl option check work with older versions of iasl.
> To: seabios at seabios.org
> 
> Signed-off-by: Kevin O'Connor <kevin at koconnor.net>
> ---
>  Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Makefile b/Makefile
> index 72ee152..45ea48a 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -221,7 +221,7 @@ $(OUT)vgabios.bin: $(OUT)vgabios.bin.raw tools/buildrom.py
>  
>  ################ DSDT build rules
>  
> -iasl-option=$(shell if "$(1)" "$(2)" -h > /dev/null 2>&1 \
> +iasl-option=$(shell if test -z "`$(1) $(2) 2>&1 > /dev/null`" \
>      ; then echo "$(2)"; else echo "$(3)"; fi ;)
>  
>  $(OUT)%.hex: src/%.dsl ./tools/acpi_extract_preprocess.py ./tools/acpi_extract.py


Will try. But logic seems fragile here: I am guessing old
iasl versions exit with error if you run them without input,
so this code relies on such to fail silently?
But what if future iasl starts producing
"Warning: no input" or such on stderr?
Seems a sensible thing to do and will break this script.

How about we give it a small dummy input file
instead and check exit status?

> -- 
> 1.7.11.4



More information about the SeaBIOS mailing list