[PATCH 10/10] Move the RPC generator scripts into src/rpc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Move the daemon/remote_generator.pl to src/rpc/gendispatch.pl
and move the src/remote/rpcgen_fix.pl to src/rpc/genprotocol.pl

* daemon/Makefile.am: Update for new name/location of generator
* src/Makefile.am: Update for new name/location of generator
---
 daemon/Makefile.am                                 |   41 ++++++++++----------
 src/Makefile.am                                    |   32 +++++++++-------
 .../remote_generator.pl => src/rpc/gendispatch.pl  |    0
 src/{remote/rpcgen_fix.pl => rpc/genprotocol.pl}   |    0
 4 files changed, 38 insertions(+), 35 deletions(-)
 rename daemon/remote_generator.pl => src/rpc/gendispatch.pl (100%)
 rename src/{remote/rpcgen_fix.pl => rpc/genprotocol.pl} (100%)

diff --git a/daemon/Makefile.am b/daemon/Makefile.am
index 114adf3..1cbe0ab 100644
--- a/daemon/Makefile.am
+++ b/daemon/Makefile.am
@@ -28,7 +28,6 @@ AVAHI_SOURCES =						\
 
 DISTCLEANFILES =
 EXTRA_DIST =						\
-	remote_generator.pl				\
 	remote_dispatch_bodies.h			\
 	qemu_dispatch_bodies.h				\
 	libvirtd.conf					\
@@ -213,35 +212,35 @@ remote.h: $(DAEMON_GENERATED)
 REMOTE_PROTOCOL = $(top_srcdir)/src/remote/remote_protocol.x
 QEMU_PROTOCOL = $(top_srcdir)/src/remote/qemu_protocol.x
 
-remote_dispatch_prototypes.h: $(srcdir)/remote_generator.pl $(REMOTE_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -c -p remote $(REMOTE_PROTOCOL) > $@
+remote_dispatch_prototypes.h: $(srcdir)/../src/rpc/gendispatch.pl $(REMOTE_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -c -p remote $(REMOTE_PROTOCOL) > $@
 
-remote_dispatch_table.h: $(srcdir)/remote_generator.pl $(REMOTE_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -c -t remote $(REMOTE_PROTOCOL) > $@
+remote_dispatch_table.h: $(srcdir)/../src/rpc/gendispatch.pl $(REMOTE_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -c -t remote $(REMOTE_PROTOCOL) > $@
 
-remote_dispatch_args.h: $(srcdir)/remote_generator.pl $(REMOTE_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -c -a remote $(REMOTE_PROTOCOL) > $@
+remote_dispatch_args.h: $(srcdir)/../src/rpc/gendispatch.pl $(REMOTE_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -c -a remote $(REMOTE_PROTOCOL) > $@
 
-remote_dispatch_ret.h: $(srcdir)/remote_generator.pl $(REMOTE_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -c -r remote $(REMOTE_PROTOCOL) > $@
+remote_dispatch_ret.h: $(srcdir)/../src/rpc/gendispatch.pl $(REMOTE_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -c -r remote $(REMOTE_PROTOCOL) > $@
 
-remote_dispatch_bodies.h: $(srcdir)/remote_generator.pl $(REMOTE_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -c -b remote $(REMOTE_PROTOCOL) > $@
+remote_dispatch_bodies.h: $(srcdir)/../src/rpc/gendispatch.pl $(REMOTE_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -c -b remote $(REMOTE_PROTOCOL) > $@
 
-qemu_dispatch_prototypes.h: $(srcdir)/remote_generator.pl $(QEMU_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -p qemu $(QEMU_PROTOCOL) > $@
+qemu_dispatch_prototypes.h: $(srcdir)/../src/rpc/gendispatch.pl $(QEMU_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -p qemu $(QEMU_PROTOCOL) > $@
 
-qemu_dispatch_table.h: $(srcdir)/remote_generator.pl $(QEMU_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -t qemu $(QEMU_PROTOCOL) > $@
+qemu_dispatch_table.h: $(srcdir)/../src/rpc/gendispatch.pl $(QEMU_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -t qemu $(QEMU_PROTOCOL) > $@
 
-qemu_dispatch_args.h: $(srcdir)/remote_generator.pl $(QEMU_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -a qemu $(QEMU_PROTOCOL) > $@
+qemu_dispatch_args.h: $(srcdir)/../src/rpc/gendispatch.pl $(QEMU_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -a qemu $(QEMU_PROTOCOL) > $@
 
-qemu_dispatch_ret.h: $(srcdir)/remote_generator.pl $(QEMU_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -r qemu $(QEMU_PROTOCOL) > $@
+qemu_dispatch_ret.h: $(srcdir)/../src/rpc/gendispatch.pl $(QEMU_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -r qemu $(QEMU_PROTOCOL) > $@
 
-qemu_dispatch_bodies.h: $(srcdir)/remote_generator.pl $(QEMU_PROTOCOL)
-	$(AM_V_GEN)perl -w $(srcdir)/remote_generator.pl -b qemu $(QEMU_PROTOCOL) > $@
+qemu_dispatch_bodies.h: $(srcdir)/../src/rpc/gendispatch.pl $(QEMU_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/../src/rpc/gendispatch.pl -b qemu $(QEMU_PROTOCOL) > $@
 
 LOGROTATE_CONFS = libvirtd.qemu.logrotate libvirtd.lxc.logrotate \
                   libvirtd.uml.logrotate libvirtd.logrotate
diff --git a/src/Makefile.am b/src/Makefile.am
index 61faa5a..6d6c839 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -166,14 +166,14 @@ REMOTE_PROTOCOL = $(srcdir)/remote/remote_protocol.x
 QEMU_PROTOCOL = $(srcdir)/remote/qemu_protocol.x
 REMOTE_DRIVER_PROTOCOL = $(REMOTE_PROTOCOL) $(QEMU_PROTOCOL)
 
-$(srcdir)/remote/remote_client_bodies.h: $(REMOTE_PROTOCOL) \
-		$(top_srcdir)/daemon/remote_generator.pl
-	$(AM_V_GEN)perl -w $(top_srcdir)/daemon/remote_generator.pl \
+remote/remote_client_bodies.h: $(srcdir)/rpc/gendispatch.pl \
+		$(REMOTE_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/rpc/gendispatch.pl \
 	  -c -k remote $(REMOTE_PROTOCOL) > $@
 
-$(srcdir)/remote/qemu_client_bodies.h: $(QEMU_PROTOCOL) \
-		$(top_srcdir)/daemon/remote_generator.pl
-	$(AM_V_GEN)perl -w $(top_srcdir)/daemon/remote_generator.pl \
+remote/qemu_client_bodies.h: $(srcdir)/rpc/gendispatch.pl \
+		$(QEMU_PROTOCOL)
+	$(AM_V_GEN)perl -w $(srcdir)/rpc/gendispatch.pl \
 	  -k qemu $(QEMU_PROTOCOL) > $@
 
 REMOTE_DRIVER_SOURCES =						\
@@ -182,8 +182,7 @@ REMOTE_DRIVER_SOURCES =						\
 		$(REMOTE_DRIVER_GENERATED)
 
 EXTRA_DIST +=  $(REMOTE_DRIVER_PROTOCOL) \
-		$(REMOTE_DRIVER_GENERATED) \
-		remote/rpcgen_fix.pl
+		$(REMOTE_DRIVER_GENERATED)
 
 # Ensure that we don't change the struct or member names or member ordering
 # in remote_protocol.x  The embedded perl below needs a few comments, and
@@ -551,13 +550,13 @@ libvirt_driver_remote_la_SOURCES = $(REMOTE_DRIVER_SOURCES)
 
 $(srcdir)/remote/remote_driver.c: $(REMOTE_DRIVER_GENERATED)
 
-%protocol.c: %protocol.x %protocol.h $(srcdir)/remote/rpcgen_fix.pl
-	$(AM_V_GEN)perl -w $(srcdir)/remote/rpcgen_fix.pl $(RPCGEN) -c \
-	       $< $@
+%protocol.c: %protocol.x %protocol.h $(srcdir)/rpc/genprotocol.pl
+	$(AM_V_GEN)perl -w $(srcdir)/rpc/genprotocol.pl $(RPCGEN) -c \
+               $< $@
 
-%protocol.h: %protocol.x $(srcdir)/remote/rpcgen_fix.pl
-	$(AM_V_GEN)perl -w $(srcdir)/remote/rpcgen_fix.pl $(RPCGEN) -h \
-	       $< $@
+%protocol.h: %protocol.x $(srcdir)/rpc/genprotocol.pl
+	$(AM_V_GEN)perl -w $(srcdir)/rpc/genprotocol.pl $(RPCGEN) -h \
+               $< $@
 
 endif
 
@@ -1155,6 +1154,11 @@ EXTRA_DIST += $(LIBVIRT_QEMU_SYMBOL_FILE)
 
 noinst_LTLIBRARIES += libvirt-net-rpc.la libvirt-net-rpc-server.la libvirt-net-rpc-client.la
 
+EXTRA_DIST += \
+       rpc/virnetprotocol.x \
+       rpc/gendispatch.pl \
+       rpc/genprotocol.pl
+
 libvirt_net_rpc_la_SOURCES = \
 	rpc/virnetmessage.h rpc/virnetmessage.c \
 	rpc/virnetprotocol.h rpc/virnetprotocol.c \
diff --git a/daemon/remote_generator.pl b/src/rpc/gendispatch.pl
similarity index 100%
rename from daemon/remote_generator.pl
rename to src/rpc/gendispatch.pl
diff --git a/src/remote/rpcgen_fix.pl b/src/rpc/genprotocol.pl
similarity index 100%
rename from src/remote/rpcgen_fix.pl
rename to src/rpc/genprotocol.pl
-- 
1.7.4.4

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]