From nobody Sun Feb 8 20:23:15 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 207.211.31.120 as permitted sender) client-ip=207.211.31.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1573228087; cv=none; d=zoho.com; s=zohoarc; b=k5vPGeV3dZOvSmIztQvZIAgeGZyqzW/+VG+fkLwwpriusP0wVLXgmQh3QvSfJ8hI8dqHNOBZfB05LB5sR9pi+2CRUuRm9BYUrAmLRD1UxLsLBGMGaioVBZuulgOekc/83lA/eDfs6qRhbGTX7Yxqxd9a27exjOPNJ6do5lgKqxk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1573228087; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=bTSNOkQ1NlZGpXLh6+nZi0ywV94THR3CT9jKlGIzPnA=; b=Xrb2wLmB8PI2h9p7VSfvYN0GNoz7FAMdJNYUEyt9iSnPNwJdH+U5OJxp8z1KCIhfV9slRcubcJ0HwXnws5pHllJdd+m6a+xuSCR7IBbGpTKXdBXLTAQeRgUWomIT8jjItKRAIaPgsE672oCpGsrwBLUG0GsDWCHdnVkC8ILgML8= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by mx.zohomail.com with SMTPS id 157322808725154.64192777494429; Fri, 8 Nov 2019 07:48:07 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-310-lqBry6g0Ppe-i_gYfEpQ-g-1; Fri, 08 Nov 2019 10:46:58 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 96231103; Fri, 8 Nov 2019 15:46:53 +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 741311A8D8; Fri, 8 Nov 2019 15:46:53 +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 3557C4E562; Fri, 8 Nov 2019 15:46:53 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id xA8FgeQB014142 for ; Fri, 8 Nov 2019 10:42:40 -0500 Received: by smtp.corp.redhat.com (Postfix) id 846785D6AE; Fri, 8 Nov 2019 15:42:40 +0000 (UTC) Received: from antique-laptop.redhat.com (ovpn-200-52.brq.redhat.com [10.40.200.52]) by smtp.corp.redhat.com (Postfix) with ESMTP id E7E7A5D6BB for ; Fri, 8 Nov 2019 15:42:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1573228086; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=bTSNOkQ1NlZGpXLh6+nZi0ywV94THR3CT9jKlGIzPnA=; b=T1SaHcCmqhglkqjxUl+GbiQeFdwSz5fVcwAh2VOlUrJiFQjuyEti1wKvYKJNhD5vxZHnYy sou0UqIgAFaIl76/JFrj7qllAd24FFgQpuevqbscG1i3D558KK7AccSUwHqLYkuHn/ioaX dwBGzUm0zHIgCdPCSDINHShGFlTZXrk= From: Pavel Hrdina To: libvir-list@redhat.com Date: Fri, 8 Nov 2019 16:42:14 +0100 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH v4 13/20] [ACKED] src: esx: generate source files into build directory 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: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-MC-Unique: lqBry6g0Ppe-i_gYfEpQ-g-1 X-Mimecast-Spam-Score: 0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Pavel Hrdina Reviewed-by: J=C3=A1n Tomko Reviewed-by: Daniel P. Berrang=C3=A9 --- Notes: Changes in v2: - remove entries from .gitignore .gitignore | 1 - src/esx/Makefile.inc.am | 5 +++-- src/esx/esx_vi_generator.py | 11 ++++------- tests/Makefile.am | 3 +++ 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.gitignore b/.gitignore index 8989b3e3e3..46f6f98045 100644 --- a/.gitignore +++ b/.gitignore @@ -41,7 +41,6 @@ Makefile.in # libvirt related ignores /build/ /ci/scratch/ -/src/esx/*.generated.* /src/hyperv/*.generated.* /src/locking/lock_daemon_dispatch_stubs.h /src/logging/log_daemon_dispatch_stubs.h diff --git a/src/esx/Makefile.inc.am b/src/esx/Makefile.inc.am index 3dab05d71c..7ba9fd1758 100644 --- a/src/esx/Makefile.inc.am +++ b/src/esx/Makefile.inc.am @@ -63,8 +63,8 @@ $(ESX_DRIVER_GENERATED): $(ESX_GENERATED_STAMP) =20 $(ESX_GENERATED_STAMP): $(srcdir)/esx/esx_vi_generator.input \ $(srcdir)/esx/esx_vi_generator.py - $(AM_V_GEN)srcdir=3D$(srcdir) $(RUNUTF8) $(PYTHON) \ - $(srcdir)/esx/esx_vi_generator.py && touch $@ + $(AM_V_GEN) $(RUNUTF8) $(PYTHON) \ + $(srcdir)/esx/esx_vi_generator.py $(srcdir) $(builddir) && touch $@ =20 MAINTAINERCLEANFILES +=3D $(ESX_DRIVER_GENERATED) $(ESX_GENERATED_STAMP) =20 @@ -81,6 +81,7 @@ libvirt_la_BUILT_LIBADD +=3D libvirt_driver_esx.la libvirt_driver_esx_la_CFLAGS =3D \ $(CURL_CFLAGS) \ -I$(srcdir)/conf \ + -I$(builddir)/esx \ -I$(srcdir)/vmx \ $(AM_CFLAGS) \ $(NULL) diff --git a/src/esx/esx_vi_generator.py b/src/esx/esx_vi_generator.py index 28d440a6df..c77de6e60c 100755 --- a/src/esx/esx_vi_generator.py +++ b/src/esx/esx_vi_generator.py @@ -1379,14 +1379,11 @@ additional_object_features =3D { =20 removed_object_features =3D {} =20 +if len(sys.argv) !=3D 3: + report_error("usage: %s srcdir builddir" % sys.argv[0]) =20 - -if "srcdir" in os.environ: - input_filename =3D os.path.join(os.environ["srcdir"], "esx/esx_vi_gene= rator.input") - output_dirname =3D os.path.join(os.environ["srcdir"], "esx") -else: - input_filename =3D os.path.join(os.getcwd(), "esx_vi_generator.input") - output_dirname =3D os.getcwd() +input_filename =3D os.path.join(sys.argv[1], "esx/esx_vi_generator.input") +output_dirname =3D os.path.join(sys.argv[2], "esx") =20 =20 =20 diff --git a/tests/Makefile.am b/tests/Makefile.am index 014d0ddd39..9d9c582e42 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -756,6 +756,9 @@ esxutilstest_SOURCES =3D \ esxutilstest.c \ testutils.c testutils.h esxutilstest_LDADD =3D $(LDADDS) +esxutilstest_CFLAGS =3D \ + -I$(top_builddir)/src/esx \ + $(AM_CFLAGS) else ! WITH_ESX EXTRA_DIST +=3D esxutilstest.c endif ! WITH_ESX --=20 2.23.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list