qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] configure: ignore --make
@ 2022-06-07 10:49 Paolo Bonzini
  2022-06-08 14:21 ` Matheus Kowalczuk Ferst
  0 siblings, 1 reply; 4+ messages in thread
From: Paolo Bonzini @ 2022-06-07 10:49 UTC (permalink / raw)
  To: qemu-devel

Setting the MAKE variable to a GNU Make executable does not really have
any effect: if a non-GNU Make is used, the QEMU Makefile will fail to
parse.  Just remove everything related to --make and $make as dead code.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 configure | 16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)

diff --git a/configure b/configure
index ce81419629..154e041b8e 100755
--- a/configure
+++ b/configure
@@ -493,20 +493,16 @@ gnu/kfreebsd)
 ;;
 freebsd)
   bsd="yes"
-  make="${MAKE-gmake}"
   # needed for kinfo_getvmmap(3) in libutil.h
 ;;
 dragonfly)
   bsd="yes"
-  make="${MAKE-gmake}"
 ;;
 netbsd)
   bsd="yes"
-  make="${MAKE-gmake}"
 ;;
 openbsd)
   bsd="yes"
-  make="${MAKE-gmake}"
 ;;
 darwin)
   bsd="yes"
@@ -517,7 +513,6 @@ darwin)
 ;;
 sunos)
   solaris="yes"
-  make="${MAKE-gmake}"
 # needed for CMSG_ macros in sys/socket.h
   QEMU_CFLAGS="-D_XOPEN_SOURCE=600 $QEMU_CFLAGS"
 # needed for TIOCWIN* defines in termios.h
@@ -628,8 +623,6 @@ case "$cpu" in
     CPU_CFLAGS="-m64 -mcpu=ultrasparc" ;;
 esac
 
-: ${make=${MAKE-make}}
-
 # We prefer python 3.x. A bare 'python' is traditionally
 # python 2.x, but some distros have it as python 3.x, so
 # we check that too
@@ -709,7 +702,7 @@ for opt do
   ;;
   --objcc=*) objcc="$optarg"
   ;;
-  --make=*) make="$optarg"
+  --make=*)
   ;;
   --install=*)
   ;;
@@ -1024,7 +1017,6 @@ Advanced options (experts only):
   --cross-cc-ARCH=CC       use compiler when building ARCH guest test cases
   --cross-cc-cflags-ARCH=  use compiler flags when building ARCH guest tests
   --cross-prefix-ARCH=PREFIX cross compiler prefix when building ARCH guest test cases
-  --make=MAKE              use specified make [$make]
   --python=PYTHON          use specified python [$python]
   --meson=MESON            use specified meson [$meson]
   --ninja=NINJA            use specified ninja [$ninja]
@@ -1079,10 +1071,6 @@ if test -z "$python"
 then
     error_exit "Python not found. Use --python=/path/to/python"
 fi
-if ! has "$make"
-then
-    error_exit "GNU make ($make) not found"
-fi
 
 # Note that if the Python conditional here evaluates True we will exit
 # with status 1 which is a shell 'false' value.
@@ -2409,7 +2397,6 @@ if test "$container" != no; then
     echo "ENGINE=$container" >> $config_host_mak
 fi
 echo "ROMS=$roms" >> $config_host_mak
-echo "MAKE=$make" >> $config_host_mak
 echo "PYTHON=$python" >> $config_host_mak
 echo "GENISOIMAGE=$genisoimage" >> $config_host_mak
 echo "MESON=$meson" >> $config_host_mak
@@ -2740,7 +2727,6 @@ preserve_env CXXFLAGS
 preserve_env LD
 preserve_env LDFLAGS
 preserve_env LD_LIBRARY_PATH
-preserve_env MAKE
 preserve_env NM
 preserve_env OBJCFLAGS
 preserve_env OBJCOPY
-- 
2.36.1



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] configure: ignore --make
  2022-06-07 10:49 [PATCH] configure: ignore --make Paolo Bonzini
@ 2022-06-08 14:21 ` Matheus Kowalczuk Ferst
  2022-06-08 15:54   ` Paolo Bonzini
  0 siblings, 1 reply; 4+ messages in thread
From: Matheus Kowalczuk Ferst @ 2022-06-08 14:21 UTC (permalink / raw)
  To: Paolo Bonzini, qemu-devel@nongnu.org

On 07/06/2022 07:49, Paolo Bonzini wrote:
> Setting the MAKE variable to a GNU Make executable does not really have
> any effect: if a non-GNU Make is used, the QEMU Makefile will fail to
> parse.  Just remove everything related to --make and $make as dead code.
> 
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---

Hi Paolo,

On a clean build on FreeBSD with this patch, I got:

../meson.build:3641:0: ERROR: Key MAKE is not in dict

So it seems that we need to remove the use of MAKE in meson.build too.

>   configure | 16 +---------------
>   1 file changed, 1 insertion(+), 15 deletions(-)
> 
> diff --git a/configure b/configure
> index ce81419629..154e041b8e 100755
> --- a/configure
> +++ b/configure
> @@ -493,20 +493,16 @@ gnu/kfreebsd)
>   ;;
>   freebsd)
>     bsd="yes"
> -  make="${MAKE-gmake}"
>     # needed for kinfo_getvmmap(3) in libutil.h
>   ;;
>   dragonfly)
>     bsd="yes"
> -  make="${MAKE-gmake}"
>   ;;
>   netbsd)
>     bsd="yes"
> -  make="${MAKE-gmake}"
>   ;;
>   openbsd)
>     bsd="yes"
> -  make="${MAKE-gmake}"
>   ;;
>   darwin)
>     bsd="yes"
> @@ -517,7 +513,6 @@ darwin)
>   ;;
>   sunos)
>     solaris="yes"
> -  make="${MAKE-gmake}"
>   # needed for CMSG_ macros in sys/socket.h
>     QEMU_CFLAGS="-D_XOPEN_SOURCE=600 $QEMU_CFLAGS"
>   # needed for TIOCWIN* defines in termios.h
> @@ -628,8 +623,6 @@ case "$cpu" in
>       CPU_CFLAGS="-m64 -mcpu=ultrasparc" ;;
>   esac
> 
> -: ${make=${MAKE-make}}
> -
>   # We prefer python 3.x. A bare 'python' is traditionally
>   # python 2.x, but some distros have it as python 3.x, so
>   # we check that too
> @@ -709,7 +702,7 @@ for opt do
>     ;;
>     --objcc=*) objcc="$optarg"
>     ;;
> -  --make=*) make="$optarg"
> +  --make=*)
>     ;;
>     --install=*)
>     ;;
> @@ -1024,7 +1017,6 @@ Advanced options (experts only):
>     --cross-cc-ARCH=CC       use compiler when building ARCH guest test cases
>     --cross-cc-cflags-ARCH=  use compiler flags when building ARCH guest tests
>     --cross-prefix-ARCH=PREFIX cross compiler prefix when building ARCH guest test cases
> -  --make=MAKE              use specified make [$make]
>     --python=PYTHON          use specified python [$python]
>     --meson=MESON            use specified meson [$meson]
>     --ninja=NINJA            use specified ninja [$ninja]
> @@ -1079,10 +1071,6 @@ if test -z "$python"
>   then
>       error_exit "Python not found. Use --python=/path/to/python"
>   fi
> -if ! has "$make"
> -then
> -    error_exit "GNU make ($make) not found"
> -fi

Also, we will not have this error at configure-time anymore, but I 
suppose that *BSD users will identify the problem if they try to build 
with non-gnu make.

> 
>   # Note that if the Python conditional here evaluates True we will exit
>   # with status 1 which is a shell 'false' value.
> @@ -2409,7 +2397,6 @@ if test "$container" != no; then
>       echo "ENGINE=$container" >> $config_host_mak
>   fi
>   echo "ROMS=$roms" >> $config_host_mak
> -echo "MAKE=$make" >> $config_host_mak
>   echo "PYTHON=$python" >> $config_host_mak
>   echo "GENISOIMAGE=$genisoimage" >> $config_host_mak
>   echo "MESON=$meson" >> $config_host_mak
> @@ -2740,7 +2727,6 @@ preserve_env CXXFLAGS
>   preserve_env LD
>   preserve_env LDFLAGS
>   preserve_env LD_LIBRARY_PATH
> -preserve_env MAKE
>   preserve_env NM
>   preserve_env OBJCFLAGS
>   preserve_env OBJCOPY
> --
> 2.36.1
> 
> 

-- 
Matheus K. Ferst
Instituto de Pesquisas ELDORADO <http://www.eldorado.org.br/>
Analista de Software
Aviso Legal - Disclaimer <https://www.eldorado.org.br/disclaimer.html>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] configure: ignore --make
  2022-06-08 14:21 ` Matheus Kowalczuk Ferst
@ 2022-06-08 15:54   ` Paolo Bonzini
  2022-06-08 17:19     ` Matheus Kowalczuk Ferst
  0 siblings, 1 reply; 4+ messages in thread
From: Paolo Bonzini @ 2022-06-08 15:54 UTC (permalink / raw)
  To: Matheus Kowalczuk Ferst, qemu-devel@nongnu.org

On 6/8/22 16:21, Matheus Kowalczuk Ferst wrote:
> On a clean build on FreeBSD with this patch, I got:
> 
> ../meson.build:3641:0: ERROR: Key MAKE is not in dict
> 
> So it seems that we need to remove the use of MAKE in meson.build too.

Oops, yes.  That's the typical "forget git commit --amend before sending 
out" mistake for me.

> Also, we will not have this error at configure-time anymore, but I 
> suppose that *BSD users will identify the problem if they try to build 
> with non-gnu make.

Yeah, my guess was that "try ./configure && make" with GNU Make 
installed is the more common failure mode, since QEMU is certainly not 
the only package that requires GNU Make.

Alternatively, I can leave in the check for GNU Make, or move it to 
meson as a "now type "make" to build QEMU" kind of message, and still 
remove the unused --make option.

Paolo



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] configure: ignore --make
  2022-06-08 15:54   ` Paolo Bonzini
@ 2022-06-08 17:19     ` Matheus Kowalczuk Ferst
  0 siblings, 0 replies; 4+ messages in thread
From: Matheus Kowalczuk Ferst @ 2022-06-08 17:19 UTC (permalink / raw)
  To: Paolo Bonzini, qemu-devel@nongnu.org

On 08/06/2022 12:54, Paolo Bonzini wrote:
> On 6/8/22 16:21, Matheus Kowalczuk Ferst wrote:
>> Also, we will not have this error at configure-time anymore, but I
>> suppose that *BSD users will identify the problem if they try to build
>> with non-gnu make.
> 
> Yeah, my guess was that "try ./configure && make" with GNU Make
> installed is the more common failure mode, since QEMU is certainly not
> the only package that requires GNU Make.
> 
> Alternatively, I can leave in the check for GNU Make, or move it to
> meson as a "now type "make" to build QEMU" kind of message, and still
> remove the unused --make option.

Both options seem fine. It might be better if we can keep the configure 
script returning an error when gmake is not available, but I guess it's 
not a big deal.

-- 
Matheus K. Ferst
Instituto de Pesquisas ELDORADO <http://www.eldorado.org.br/>
Analista de Software
Aviso Legal - Disclaimer <https://www.eldorado.org.br/disclaimer.html>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-06-08 17:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-07 10:49 [PATCH] configure: ignore --make Paolo Bonzini
2022-06-08 14:21 ` Matheus Kowalczuk Ferst
2022-06-08 15:54   ` Paolo Bonzini
2022-06-08 17:19     ` Matheus Kowalczuk Ferst

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).