From nobody Sun Feb 8 17:37:36 2026 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; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1567500206; cv=none; d=zoho.com; s=zohoarc; b=YbH49mV56LzIC8tm0JRjy62ft3WdvVvI//mwmvAL5e9Nu0Pn5x+OvcpVr6jnGmYW/sMaUUxeGiclK/N2OAI6uH+zyqik/6OKeqZbobWNZQFhxDcvq2Oa+/vDVw1zHiRaKI6udAIb4lzJZ9sUikmLc/ptHmg/1SedMihhet+/6yk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1567500206; 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:ARC-Authentication-Results; bh=JDAPJq37aLJNinBNvK7hHNRuxE8F8pQIYJ4sBhbrPqM=; b=OFGPkgx6XcdLXPfAIHPA2Q2xROWREGDwsWihhuKoabKd5JYUS/8mvjBp6hXts2ezP5TLfgw94CiKHvxYH2Xdp6Aic+8XlBSVv/Ydr2gh/piE3yT+rmQ45KSV/PpxakKWl1TfUMd0zKAx0XfFaJq0L7GglpubddNHO8QH1wDGwCE= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1567500206738541.121694837475; Tue, 3 Sep 2019 01:43:26 -0700 (PDT) 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 mx1.redhat.com (Postfix) with ESMTPS id 7CFB8307D868; Tue, 3 Sep 2019 08:43:25 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4E8C346; Tue, 3 Sep 2019 08:43:25 +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 F337B180BA99; Tue, 3 Sep 2019 08:43:24 +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 x838hGlm030049 for ; Tue, 3 Sep 2019 04:43:16 -0400 Received: by smtp.corp.redhat.com (Postfix) id 96C7D5D6D0; Tue, 3 Sep 2019 08:43:16 +0000 (UTC) Received: from lindworm.usersys.redhat.com (unknown [10.43.2.5]) by smtp.corp.redhat.com (Postfix) with ESMTPS id EC0505D6B7; Tue, 3 Sep 2019 08:43:15 +0000 (UTC) From: Pino Toscano To: libvir-list@redhat.com Date: Tue, 3 Sep 2019 10:43:04 +0200 Message-Id: <20190903084306.32520-5-ptoscano@redhat.com> In-Reply-To: <20190903084306.32520-1-ptoscano@redhat.com> References: <20190903084306.32520-1-ptoscano@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [ocaml PATCH 4/6] Rename the generated libvirt_c.c to libvirt_generated.c 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: , Content-Transfer-Encoding: quoted-printable 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-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.48]); Tue, 03 Sep 2019 08:43:25 +0000 (UTC) Content-Type: text/plain; charset="utf-8" Make it clear it is a generated source. Signed-off-by: Pino Toscano --- .gitignore | 2 +- Makefile.in | 2 +- libvirt/Makefile.in | 18 +++++++++--------- libvirt/README | 6 +++--- libvirt/generator.pl | 4 ++-- libvirt/libvirt.mli | 2 +- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index 840c0c4..c52c1b8 100644 --- a/.gitignore +++ b/.gitignore @@ -28,7 +28,7 @@ core.* /examples/list_secrets /examples/node_info /html/ -/libvirt/libvirt_c.c +/libvirt/libvirt_generated.c /libvirt/libvirt_version.ml /ocaml-libvirt-*.exe /ocaml-libvirt-*.tar.gz diff --git a/Makefile.in b/Makefile.in index e50600a..4357ba6 100644 --- a/Makefile.in +++ b/Makefile.in @@ -35,7 +35,7 @@ clean: for d in . $(SUBDIRS); do \ (cd $$d; rm -f *.cmi *.cmo *.cmx *.cma *.cmxa *.o *.a *.so *.opt *~ *.d= ll *.exe core); \ done - rm -f libvirt/libvirt_c.c + rm -f libvirt/libvirt_generated.c rm -f examples/list_domains rm -f examples/node_info rm -f examples/get_cpu_stats diff --git a/libvirt/Makefile.in b/libvirt/Makefile.in index ad56bb5..d78056b 100644 --- a/libvirt/Makefile.in +++ b/libvirt/Makefile.in @@ -64,10 +64,10 @@ OPTOBJS :=3D libvirt.cmx libvirt_version.cmx =20 ifneq ($(OCAMLMKLIB),) # Good, we can just use ocamlmklib -mllibvirt.cma: libvirt_c.o libvirt_c_oneoffs.o libvirt_c_epilogue.o $(COBJ= S) +mllibvirt.cma: libvirt_generated.o libvirt_c_oneoffs.o libvirt_c_epilogue.= o $(COBJS) $(OCAMLMKLIB) -o mllibvirt $^ $(LDFLAGS) =20 -mllibvirt.cmxa: libvirt_c.o libvirt_c_oneoffs.o libvirt_c_epilogue.o $(OPT= OBJS) +mllibvirt.cmxa: libvirt_generated.o libvirt_c_oneoffs.o libvirt_c_epilogue= .o $(OPTOBJS) $(OCAMLMKLIB) -o mllibvirt $^ $(LDFLAGS) =20 else @@ -83,11 +83,11 @@ mllibvirt.cmxa: libmllibvirt.a $(OPTOBJS) $(OCAMLOPT) -a -linkall -o $@ $(OPTOBJS) \ -cclib -lmllibvirt -cclib "$(LDFLAGS)" =20 -dllmllibvirt.dll: libvirt_c.o libvirt_c_oneoffs.o libvirt_c_epilogue.o +dllmllibvirt.dll: libvirt_generated.o libvirt_c_oneoffs.o libvirt_c_epilog= ue.o $(CC) -shared -o $@ $^ \ $(LDFLAGS) "$(shell ocamlc -where)"/ocamlrun.a =20 -libmllibvirt.a: libvirt_c.o libvirt_c_oneoffs.o libvirt_c_epilogue.o +libmllibvirt.a: libvirt_generated.o libvirt_c_oneoffs.o libvirt_c_epilogue= .o ar rc $@ $^ ranlib $@ =20 @@ -100,24 +100,24 @@ endif endif =20 # Automatically generate the C code from a Perl script 'generator.pl'. -libvirt_c.c: generator.pl +libvirt_generated.c: generator.pl $(PERL) -w $< =20 # Extra dependencies. -libvirt_c.o: libvirt_c.h +libvirt_generated.o: libvirt_c.h libvirt_c_oneoffs.o: libvirt_c.h libvirt_c_epilogue.o: libvirt_c.h =20 # Status of automatically generated bindings. -autostatus: libvirt_c.c +autostatus: libvirt_generated.c @echo -n "Functions which have manual bindings: " @grep ^ocaml_libvirt_ libvirt_c_oneoffs.c | wc -l @echo -n "Functions which have automatic bindings: " - @grep ^ocaml_libvirt_ libvirt_c.c | wc -l + @grep ^ocaml_libvirt_ libvirt_generated.c | wc -l @echo -n "LOC in manual bindings: " @wc -l < libvirt_c_oneoffs.c @echo -n "LOC in automatic bindings: " - @wc -l < libvirt_c.c + @wc -l < libvirt_generated.c =20 =20 install-byte: diff --git a/libvirt/README b/libvirt/README index 3fb8f53..197a07a 100644 --- a/libvirt/README +++ b/libvirt/README @@ -19,9 +19,9 @@ one-of-a-kind to be worth generating automatically. Generated code -------------- =20 -The C bindings in 'libvirt_c.c' are now generated automatically by a -Perl script called 'generator.pl'. You do not normally need to run -this script, but you may need to if you want to extend libvirt +The C bindings in 'libvirt_generated.c' are now generated automatically +by a Perl script called 'generator.pl'. You do not normally need to +run this script, but you may need to if you want to extend libvirt coverage. =20 The majority of the functions are now generated automatically, but diff --git a/libvirt/generator.pl b/libvirt/generator.pl index eb329a0..cb2b845 100755 --- a/libvirt/generator.pl +++ b/libvirt/generator.pl @@ -19,7 +19,7 @@ # License along with this library; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301= USA =20 -# This generates libvirt_c.c (the core of the bindings). You don't +# This generates libvirt_generated.c (the core of the bindings). You don't # need to run this program unless you are extending the bindings # themselves (eg. because libvirt has been extended). # @@ -199,7 +199,7 @@ my @unimplemented =3D ( =20 # Open the output file. =20 -my $filename =3D "libvirt_c.c"; +my $filename =3D "libvirt_generated.c"; open F, ">$filename" or die "$filename: $!"; =20 # Write the prologue. diff --git a/libvirt/libvirt.mli b/libvirt/libvirt.mli index 72e83f9..0739702 100644 --- a/libvirt/libvirt.mli +++ b/libvirt/libvirt.mli @@ -1574,7 +1574,7 @@ sig | VIR_ERR_NONE | VIR_ERR_WARNING | VIR_ERR_ERROR - (* ^^ NB: If you add a variant you MUST edit libvirt_c.c: MAX_VIR_* *) + (* ^^ NB: If you add a variant you MUST edit libvirt_generated.c: MAX_VIR= _* *) | VIR_ERR_UNKNOWN_LEVEL of int (** Other level, not handled with exist= ing values. *) (** No error, a warning or an error. *) =20 --=20 2.21.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list