From nobody Fri May 3 22:10:35 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 151309426077296.76273377574898; Tue, 12 Dec 2017 07:57:40 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id CD34C80C0E; Tue, 12 Dec 2017 15:57:38 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 43E11614C3; Tue, 12 Dec 2017 15:57:38 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id BAC754BB79; Tue, 12 Dec 2017 15:57:36 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id vBCFvY4O008179 for ; Tue, 12 Dec 2017 10:57:34 -0500 Received: by smtp.corp.redhat.com (Postfix) id 95825614E5; Tue, 12 Dec 2017 15:57:34 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.42.22.189]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6D6F0614E7; Tue, 12 Dec 2017 15:57:26 +0000 (UTC) From: "Daniel P. Berrange" To: libvir-list@redhat.com Date: Tue, 12 Dec 2017 15:57:23 +0000 Message-Id: <20171212155723.890-1-berrange@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: Andrea Bolognani Subject: [libvirt] [PATCH v2] autogen.sh: tell user the correct make command X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Tue, 12 Dec 2017 15:57:39 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" When autogen.sh finishes it helpfully prints "Now type 'make' to compile libvirt." which is fine if on a host with GNU make, but on *BSD running 'make' will end in tears. We should tell users to run 'gmake' on these platforms. If 'gmake' doesn't exist then we should report an error too "GNU make is required to build libvirt" Signed-off-by: Daniel P. Berrange Reviewed-by: Andrea Bolognani --- autogen.sh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/autogen.sh b/autogen.sh index d5d836aa71..ea94528de6 100755 --- a/autogen.sh +++ b/autogen.sh @@ -175,6 +175,18 @@ if test "$OBJ_DIR"; then } fi =20 +# Make sure we can find GNU make and tell the user +# the right command to run +if make -v 2>&1 | grep -q "GNU Make"; then + MAKE=3Dmake +else + if which gmake >/dev/null 2>&1; then + MAKE=3Dgmake + else + die "GNU make is required to build libvirt" + fi +fi + if test -z "$*" && test -z "$extra_args" && test -f config.status; then echo "Running config.status..." ./config.status --recheck || { @@ -193,4 +205,4 @@ else fi =20 echo -echo "Now type 'make' to compile libvirt." +echo "Now type '$MAKE' to compile libvirt." --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list