diff mbox series

[1/4] configure: Do not build libfdt is not required

Message ID 20200109153939.27173-2-philmd@redhat.com
State New
Headers show
Series buildsys: Build quicker (mostly tools and linux-user) | expand

Commit Message

Philippe Mathieu-Daudé Jan. 9, 2020, 3:39 p.m. UTC
We only require libfdt for system emulation, in a small set
of architecture:

4077  # fdt support is mandatory for at least some target architectures,
4078  # so insist on it if we're building those system emulators.
4079  fdt_required=no
4080  for target in $target_list; do
4081    case $target in
4082      aarch64*-softmmu|arm*-softmmu|ppc*-softmmu|microblaze*-softmmu|mips64el-softmmu|riscv*-softmmu)
4083        fdt_required=yes

Do not build libfdt if we did not manually specified --enable-fdt.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 configure | 2 ++
 1 file changed, 2 insertions(+)

Comments

Thomas Huth Jan. 9, 2020, 4:33 p.m. UTC | #1
On 09/01/2020 16.39, Philippe Mathieu-Daudé wrote:
> We only require libfdt for system emulation, in a small set
> of architecture:
> 
> 4077  # fdt support is mandatory for at least some target architectures,
> 4078  # so insist on it if we're building those system emulators.
> 4079  fdt_required=no
> 4080  for target in $target_list; do
> 4081    case $target in
> 4082      aarch64*-softmmu|arm*-softmmu|ppc*-softmmu|microblaze*-softmmu|mips64el-softmmu|riscv*-softmmu)
> 4083        fdt_required=yes
> 
> Do not build libfdt if we did not manually specified --enable-fdt.

I suggest to add:

"... or have one of the platforms that require it in our target list."

> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> ---
>  configure | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/configure b/configure
> index 0ce2c0354a..266a8386d1 100755
> --- a/configure
> +++ b/configure
> @@ -4092,6 +4092,8 @@ if test "$fdt_required" = "yes"; then
>        "targets which need it (by specifying a cut down --target-list)."
>    fi
>    fdt=yes
> +elif test "$fdt" != "yes" ; then
> +  fdt=no
>  fi
>  
>  if test "$fdt" != "no" ; then
> 

Reviewed-by: Thomas Huth <thuth@redhat.com>
Alistair Francis Jan. 10, 2020, 10:04 a.m. UTC | #2
On Thu, Jan 9, 2020 at 11:40 PM Philippe Mathieu-Daudé
<philmd@redhat.com> wrote:
>
> We only require libfdt for system emulation, in a small set
> of architecture:
>
> 4077  # fdt support is mandatory for at least some target architectures,
> 4078  # so insist on it if we're building those system emulators.
> 4079  fdt_required=no
> 4080  for target in $target_list; do
> 4081    case $target in
> 4082      aarch64*-softmmu|arm*-softmmu|ppc*-softmmu|microblaze*-softmmu|mips64el-softmmu|riscv*-softmmu)
> 4083        fdt_required=yes
>
> Do not build libfdt if we did not manually specified --enable-fdt.
>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>

Reviewed-by: Alistair Francis <alistair.francis@wdc.com>

Alistair

> ---
>  configure | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/configure b/configure
> index 0ce2c0354a..266a8386d1 100755
> --- a/configure
> +++ b/configure
> @@ -4092,6 +4092,8 @@ if test "$fdt_required" = "yes"; then
>        "targets which need it (by specifying a cut down --target-list)."
>    fi
>    fdt=yes
> +elif test "$fdt" != "yes" ; then
> +  fdt=no
>  fi
>
>  if test "$fdt" != "no" ; then
> --
> 2.21.1
>
>
diff mbox series

Patch

diff --git a/configure b/configure
index 0ce2c0354a..266a8386d1 100755
--- a/configure
+++ b/configure
@@ -4092,6 +4092,8 @@  if test "$fdt_required" = "yes"; then
       "targets which need it (by specifying a cut down --target-list)."
   fi
   fdt=yes
+elif test "$fdt" != "yes" ; then
+  fdt=no
 fi
 
 if test "$fdt" != "no" ; then