[Libreoffice-commits] .: Branch 'feature/killsdf' - 2 commits - l10ntools/source readlicense_oo/CustomTarget_readme.mk solenv/gbuild

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Mon Nov 19 15:36:48 PST 2012


 l10ntools/source/propmerge.cxx        |    3 ++-
 readlicense_oo/CustomTarget_readme.mk |    2 +-
 solenv/gbuild/ExtensionTarget.mk      |   21 ++++++++++++---------
 3 files changed, 15 insertions(+), 11 deletions(-)

New commits:
commit 073ff5518f2e341dde7d7ce732cfecb029c85ce6
Author: Zolnai Tamás <zolnaitamas2000g at gmail.com>
Date:   Tue Nov 20 00:24:20 2012 +0100

    Generate qtz properties
    
    Qtz has no own po files so use one of
    configured langauge's po files (en-US excludex)
    Plus copy all properties files independently of
    localization
    
    Change-Id: Ica7ccb7d3111f2fc2b3bbde4b839cb564967130a

diff --git a/l10ntools/source/propmerge.cxx b/l10ntools/source/propmerge.cxx
index a858f44..689e931 100644
--- a/l10ntools/source/propmerge.cxx
+++ b/l10ntools/source/propmerge.cxx
@@ -182,7 +182,8 @@ void PropParser::Merge( const OString &rMergeSrc, const OString &rDestinationFil
 
     MergeDataFile aMergeDataFile( rMergeSrc, m_sSource, false );
 
-    if( aMergeDataFile.GetLanguages()[0] != m_sLang )
+    const std::vector<OString> aLanguages = aMergeDataFile.GetLanguages();
+    if( m_sLang != "qtz" && !aLanguages.empty() && aLanguages[0] != m_sLang )
     {
         std::cerr
             << "Propex error: given language conflicts with "
diff --git a/solenv/gbuild/ExtensionTarget.mk b/solenv/gbuild/ExtensionTarget.mk
index 63dbc4d..472b50d 100644
--- a/solenv/gbuild/ExtensionTarget.mk
+++ b/solenv/gbuild/ExtensionTarget.mk
@@ -234,6 +234,9 @@ endef
 # localize .properties file
 # source file is copied to $(WORKDIR)
 define gb_ExtensionTarget_localize_properties
+ifneq ($(filter-out en-US,$(gb_ExtensionTarget_ALL_LANGS)),)
+$(call gb_ExtensionTarget_localize_properties_onelang,$(1),$(subst en_US,qtz,$(2)),$(3),qtz,$(firstword $(filter-out en-US,$(gb_ExtensionTarget_ALL_LANGS))))
+endif
 $(foreach lang,$(gb_ExtensionTarget_ALL_LANGS),\
 	$(call gb_ExtensionTarget_localize_properties_onelang,$(1),$(subst en_US,$(subst -,_,$(lang)),$(2)),$(3),$(lang)))
 endef
@@ -242,9 +245,9 @@ define gb_ExtensionTarget_localize_properties_onelang
 $(call gb_ExtensionTarget_get_target,$(1)) : FILES += $(2)
 ifneq ($(filter-out en-US,$(4)),)
 $(call gb_ExtensionTarget_get_rootdir,$(1))/$(2) : \
-	POFILE := $(gb_POLOCATION)/$(4)/$(patsubst /%/,%,$(subst $(SRCDIR),,$(dir $(3)))).po
+	POFILE := $(gb_POLOCATION)/$(or $(5),$(4))/$(patsubst /%/,%,$(subst $(SRCDIR),,$(dir $(3)))).po
 $(call gb_ExtensionTarget_get_rootdir,$(1))/$(2) : \
-	$(gb_POLOCATION)/$(4)/$(patsubst /%/,%,$(subst $(SRCDIR),,$(dir $(3)))).po
+	$(gb_POLOCATION)/$(or $(5),$(4))/$(patsubst /%/,%,$(subst $(SRCDIR),,$(dir $(3)))).po
 endif
 $(call gb_ExtensionTarget_get_target,$(1)) : $(call gb_ExtensionTarget_get_rootdir,$(1))/$(2)
 $(call gb_ExtensionTarget_get_rootdir,$(1))/$(2) \
@@ -253,13 +256,13 @@ $(call gb_ExtensionTarget_get_rootdir,$(1))/$(2) : $(3) \
 		$(gb_ExtensionTarget_PROPMERGETARGET)
 	$$(call gb_Output_announce,$(2),$(true),PRP,3)
 	$$(call gb_Helper_abbreviate_dirs, \
-		$(if $(filter-out en-US,$(4)), \
-			MERGEINPUT=`$(gb_MKTEMP)` && \
-			echo $$(POFILE) > $$$${MERGEINPUT} && \
-			mkdir -p $$(dir $$@) && \
-			$(gb_ExtensionTarget_PROPMERGECOMMAND) -i $$< -o $$@ -m $$$${MERGEINPUT} -l $(4) && \
-			rm -rf $$$${MERGEINPUT}, \
-			cp $$< $$@))
+		mkdir -p $$(dir $$@) && \
+		cp -f $$< $$@ )
+	$(if $(filter-out en-US,$(4)), \
+		MERGEINPUT=`$(gb_MKTEMP)` && \
+		echo $$(POFILE) > $$$${MERGEINPUT} && \
+		$(gb_ExtensionTarget_PROPMERGECOMMAND) -i $$< -o $$@ -m $$$${MERGEINPUT} -l $(4) && \
+		rm -rf $$$${MERGEINPUT})
 
 endef
 
commit 23ffae787b9b052748f7f3a6f67c4e2f8f2c9cbb
Author: Zolnai Tamás <zolnaitamas2000g at gmail.com>
Date:   Tue Nov 20 00:21:57 2012 +0100

    Reardme.xrm move up one directory
    
    just as the po file belong to it
    
    Change-Id: Ia5deea8816cbb5fc29669d6aa8c3c81472b0ed3f

diff --git a/readlicense_oo/CustomTarget_readme.mk b/readlicense_oo/CustomTarget_readme.mk
index 2871631..248e495 100644
--- a/readlicense_oo/CustomTarget_readme.mk
+++ b/readlicense_oo/CustomTarget_readme.mk
@@ -41,7 +41,7 @@ $(readlicense_oo_DIR)/readme.xrm : \
 	$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),XRM,1)
 	$(call gb_Helper_abbreviate_dirs, \
         MERGEINPUT=`$(gb_MKTEMP)` && \
-        echo $(foreach lang,$(filter-out en-US,$(gb_WITH_LANG)),$(gb_POLOCATION)/$(lang)/readlicense_oo/docs/readme.po) > $${MERGEINPUT} && \
+        echo $(foreach lang,$(filter-out en-US,$(gb_WITH_LANG)),$(gb_POLOCATION)/$(lang)/readlicense_oo/docs.po) > $${MERGEINPUT} && \
 		$(readlicense_XRMEXCOMMAND) \
 			-p readlicense_oo \
 			-i $< \


More information about the Libreoffice-commits mailing list