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

[libvirt] [PATCH] build: let xgettext see strings in libvirt-guests.init



* tools/libvirt-guests.init.in: Rename...
* tools/libvirt-guests.init.sh: ...so that xgettext's language
detection via suffix will work.
* po/POTFILES.in: Update all references.
* tools/Makefile.am (EXTRA_DIST, libvirt-guests.init): Likewise.
---

> "xgettext -o - tools/libvirt-guests.init.in.sh" works fine so it should be a 
> good idea if we can't specify the -L option to xgettext for this file.

Indeed - this patch, on top of my modifications to your patch made
po/libvirt.pot pick up the translations.

It feels a bit hackish, but it solves the problem (without having to
wait for an upstream gettext solution to my feature request report:
http://lists.gnu.org/archive/html/bug-gnu-utils/2011-01/msg00000.html)

 po/POTFILES.in                                     |    2 +-
 tools/Makefile.am                                  |    4 ++--
 ...bvirt-guests.init.in => libvirt-guests.init.sh} |    0
 3 files changed, 3 insertions(+), 3 deletions(-)
 rename tools/{libvirt-guests.init.in => libvirt-guests.init.sh} (100%)

diff --git a/po/POTFILES.in b/po/POTFILES.in
index 9d9a86f..cb7c772 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -118,5 +118,5 @@ src/xen/xs_internal.c
 src/xenapi/xenapi_driver.c
 src/xenapi/xenapi_utils.c
 tools/console.c
-tools/libvirt-guests.init.in
+tools/libvirt-guests.init.sh
 tools/virsh.c
diff --git a/tools/Makefile.am b/tools/Makefile.am
index 87cf9bd..f008078 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -13,7 +13,7 @@ EXTRA_DIST = \
 	virt-xml-validate.in				\
 	virt-pki-validate.in				\
 	virsh.pod					\
-	libvirt-guests.init.in				\
+	libvirt-guests.init.sh				\
 	libvirt-guests.sysconf

 bin_SCRIPTS = virt-xml-validate virt-pki-validate
@@ -144,7 +144,7 @@ uninstall-init:

 BUILT_SOURCES += libvirt-guests.init

-libvirt-guests.init: libvirt-guests.init.in $(top_builddir)/config.status
+libvirt-guests.init: libvirt-guests.init.sh $(top_builddir)/config.status
 	$(AM_V_GEN)sed					\
 	    -e 's!\ PACKAGE\@!$(PACKAGE)!g'		\
 	    -e 's!\ bindir\@!$(bindir)!g'		\
diff --git a/tools/libvirt-guests.init.in b/tools/libvirt-guests.init.sh
similarity index 100%
rename from tools/libvirt-guests.init.in
rename to tools/libvirt-guests.init.sh
-- 
1.7.3.4


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