diff mbox

[1/4] configure: Require libfdt for arm, ppc, microblaze softmmu targets

Message ID 1369409217-7553-2-git-send-email-peter.maydell@linaro.org
State New
Headers show

Commit Message

Peter Maydell May 24, 2013, 3:26 p.m. UTC
A number of our softmmu targets (PPC, ARM, Microblaze) now more or
less require flattened device tree support for various board models
to work correctly.  Make libfdt mandatory if the target list includes
these, rather than building unhelpful half-functional binaries.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
 configure |   20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

Comments

Peter Crosthwaite May 28, 2013, 4:07 a.m. UTC | #1
On Sat, May 25, 2013 at 1:26 AM, Peter Maydell <peter.maydell@linaro.org> wrote:
> A number of our softmmu targets (PPC, ARM, Microblaze) now more or
> less require flattened device tree support for various board models
> to work correctly.  Make libfdt mandatory if the target list includes
> these, rather than building unhelpful half-functional binaries.
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

Reviewed-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>

> ---
>  configure |   20 ++++++++++++++++++++
>  1 file changed, 20 insertions(+)
>
> diff --git a/configure b/configure
> index 5ae7e4a..708c010 100755
> --- a/configure
> +++ b/configure
> @@ -2518,6 +2518,26 @@ fi
>
>  ##########################################
>  # fdt probe
> +# fdt support is mandatory for at least some target architectures,
> +# so insist on it if we're building those system emulators.
> +fdt_required=no
> +for target in $target_list; do
> +  case $target in
> +    arm*softmmu|ppc*softmmu|microblaze*softmmu)
> +      fdt_required=yes
> +    ;;
> +  esac
> +done
> +
> +if test "$fdt_required" = "yes"; then
> +  if test "$fdt" = "no"; then
> +    error_exit "fdt disabled but some requested targets require it." \
> +      "You can turn off fdt only if you also disable all the system emulation" \
> +      "targets which need it (by specifying a cut down --target-list)."
> +  fi
> +  fdt=yes
> +fi
> +
>  if test "$fdt" != "no" ; then
>    fdt_libs="-lfdt"
>    cat > $TMPC << EOF
> --
> 1.7.9.5
>
>
Andreas Färber May 28, 2013, 9:03 a.m. UTC | #2
Am 24.05.2013 17:26, schrieb Peter Maydell:
> A number of our softmmu targets (PPC, ARM, Microblaze) now more or
> less require flattened device tree support for various board models
> to work correctly.  Make libfdt mandatory if the target list includes
> these, rather than building unhelpful half-functional binaries.
> 
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
>  configure |   20 ++++++++++++++++++++
>  1 file changed, 20 insertions(+)
> 
> diff --git a/configure b/configure
> index 5ae7e4a..708c010 100755
> --- a/configure
> +++ b/configure
> @@ -2518,6 +2518,26 @@ fi
>  
>  ##########################################
>  # fdt probe
> +# fdt support is mandatory for at least some target architectures,
> +# so insist on it if we're building those system emulators.
> +fdt_required=no
> +for target in $target_list; do
> +  case $target in
> +    arm*softmmu|ppc*softmmu|microblaze*softmmu)

Assuming you'll apply this through your tree, it would be more
self-explanatory to use foo*-softmmu despite no practical difference.

I'm guessing arm* is in preparation for a future armeb-softmmu?

Otherwise looks good; still have testing pseries on my TODO list.

Andreas

> +      fdt_required=yes
> +    ;;
> +  esac
> +done
> +
> +if test "$fdt_required" = "yes"; then
> +  if test "$fdt" = "no"; then
> +    error_exit "fdt disabled but some requested targets require it." \
> +      "You can turn off fdt only if you also disable all the system emulation" \
> +      "targets which need it (by specifying a cut down --target-list)."
> +  fi
> +  fdt=yes
> +fi
> +
>  if test "$fdt" != "no" ; then
>    fdt_libs="-lfdt"
>    cat > $TMPC << EOF
Peter Maydell May 28, 2013, 9:39 a.m. UTC | #3
On 28 May 2013 10:03, Andreas Färber <afaerber@suse.de> wrote:
> Am 24.05.2013 17:26, schrieb Peter Maydell:
>> +# fdt support is mandatory for at least some target architectures,
>> +# so insist on it if we're building those system emulators.
>> +fdt_required=no
>> +for target in $target_list; do
>> +  case $target in
>> +    arm*softmmu|ppc*softmmu|microblaze*softmmu)
>
> Assuming you'll apply this through your tree, it would be more
> self-explanatory to use foo*-softmmu despite no practical difference.

Agreed.

> I'm guessing arm* is in preparation for a future armeb-softmmu?

Yes, also for consistency with ppc.

-- PMM
diff mbox

Patch

diff --git a/configure b/configure
index 5ae7e4a..708c010 100755
--- a/configure
+++ b/configure
@@ -2518,6 +2518,26 @@  fi
 
 ##########################################
 # fdt probe
+# fdt support is mandatory for at least some target architectures,
+# so insist on it if we're building those system emulators.
+fdt_required=no
+for target in $target_list; do
+  case $target in
+    arm*softmmu|ppc*softmmu|microblaze*softmmu)
+      fdt_required=yes
+    ;;
+  esac
+done
+
+if test "$fdt_required" = "yes"; then
+  if test "$fdt" = "no"; then
+    error_exit "fdt disabled but some requested targets require it." \
+      "You can turn off fdt only if you also disable all the system emulation" \
+      "targets which need it (by specifying a cut down --target-list)."
+  fi
+  fdt=yes
+fi
+
 if test "$fdt" != "no" ; then
   fdt_libs="-lfdt"
   cat > $TMPC << EOF