[Libreoffice-commits] .: 2 commits - nlpsolver/Extension_nlpsolver.mk solenv/gbuild
Andras Timar
timar at kemper.freedesktop.org
Wed Jan 4 13:23:46 PST 2012
nlpsolver/Extension_nlpsolver.mk | 8 ++++++--
solenv/gbuild/Extension.mk | 25 ++++++++++++++++++++++++-
2 files changed, 30 insertions(+), 3 deletions(-)
New commits:
commit d3c3f41881b1b5a48ace0d91a4ba375dc068ea99
Author: Andras Timar <atimar at suse.com>
Date: Wed Jan 4 22:22:50 2012 +0100
build and pack NLPSolver help localizations
diff --git a/nlpsolver/Extension_nlpsolver.mk b/nlpsolver/Extension_nlpsolver.mk
index cfe27f6..b7de4b0 100644
--- a/nlpsolver/Extension_nlpsolver.mk
+++ b/nlpsolver/Extension_nlpsolver.mk
@@ -39,7 +39,11 @@ $(eval $(call gb_Extension_add_file,nlpsolver,locale/NLPSolverStatusDialog_en_US
$(eval $(call gb_Extension_localize_properties,nlpsolver,locale/NLPSolverCommon_en_US.properties,$(SRCDIR)/nlpsolver/src/locale/NLPSolverCommon_en_US.properties))
$(eval $(call gb_Extension_localize_properties,nlpsolver,locale/NLPSolverStatusDialog_en_US.properties,$(SRCDIR)/nlpsolver/src/locale/NLPSolverStatusDialog_en_US.properties))
-$(eval $(call gb_Extension_add_file,nlpsolver,help/en/com.sun.star.comp.Calc.NLPSolver/Options.xhp, \
+$(eval $(call gb_Extension_add_file,nlpsolver,help/en-US/com.sun.star.comp.Calc.NLPSolver/Options.xhp, \
$(SRCDIR)/nlpsolver/help/en/com.sun.star.comp.Calc.NLPSolver/Options.xhp))
-$(eval $(call gb_Extension_add_file,nlpsolver,help/en/com.sun.star.comp.Calc.NLPSolver/Usage.xhp, \
+$(eval $(call gb_Extension_add_file,nlpsolver,help/en-US/com.sun.star.comp.Calc.NLPSolver/Usage.xhp, \
+ $(SRCDIR)/nlpsolver/help/en/com.sun.star.comp.Calc.NLPSolver/Usage.xhp))
+$(eval $(call gb_Extension_localize_help,nlpsolver,help/lang/com.sun.star.comp.Calc.NLPSolver/Options.xhp, \
+ $(SRCDIR)/nlpsolver/help/en/com.sun.star.comp.Calc.NLPSolver/Options.xhp))
+$(eval $(call gb_Extension_localize_help,nlpsolver,help/lang/com.sun.star.comp.Calc.NLPSolver/Usage.xhp, \
$(SRCDIR)/nlpsolver/help/en/com.sun.star.comp.Calc.NLPSolver/Usage.xhp))
commit eaa58fe31ce5a7f337b56314fee9484347bfc67d
Author: Andras Timar <atimar at suse.com>
Date: Wed Jan 4 22:20:00 2012 +0100
extension help localizer help functions
diff --git a/solenv/gbuild/Extension.mk b/solenv/gbuild/Extension.mk
index 7d4bb34..6044f4f 100644
--- a/solenv/gbuild/Extension.mk
+++ b/solenv/gbuild/Extension.mk
@@ -39,6 +39,9 @@ gb_Extension_XRMEXCOMMAND := \
gb_Extension_PROPMERGETARGET := $(call gb_Executable_get_target,propmerge)
gb_Extension_PROPMERGECOMMAND := \
$(PERL) $(gb_Extension_PROPMERGETARGET)
+gb_Extension_HELPEXTARGET := $(call gb_Executable_get_target,helpex)
+gb_Extension_HELPEXCOMMAND := \
+ $(gb_Helper_set_ld_path) $(gb_Extension_HELPEXTARGET)
gb_Extension_SDFLOCATION := $(SRCDIR)/translations/$(INPATH)/misc/sdf/
# does not contain en-US because it is special cased in gb_Extension_Extension
gb_Extension_LANGS := $(filter-out en-US,$(gb_WITH_LANG))
@@ -130,7 +133,7 @@ $(call gb_Extension_get_target,$(1)) : SDF2 := $(gb_Extension_SDFLOCATION)$(subs
$(call gb_Extension_get_target,$(1)) : $$(SDF2)
$(call gb_Extension_get_target,$(1)) : $(call gb_Extension_get_workdir,$(1))/$(2)
$(call gb_Extension_get_workdir,$(1))/$(2) : $(3)
- $$(call gb_Output_announce,$(2),$(true),PRP,3)
+ $(call gb_Output_announce,$(2),$(true),PRP,3)
mkdir -p $$(dir $$@)
cp -f $$< $$@
$(gb_Extension_PROPMERGECOMMAND) -i $$@ -m $$(SDF2)
@@ -138,4 +141,24 @@ endif
endef
+# localize extension help
+define gb_Extension_localize_help
+ifneq ($(strip $(gb_WITH_LANG)),)
+$(call gb_Extension_get_target,$(1)) : FILES += $(foreach lang,$(gb_Extension_LANGS),$(subst lang,$(lang),$(2)))
+$(call gb_Extension_get_target,$(1)) : SDF3 := $(realpath $(gb_Extension_SDFLOCATION)$(subst $(SRCDIR),,$(dir $(3)))localize.sdf)
+$(call gb_Extension_get_target,$(1)) : $$(SDF3)
+$(foreach lang,$(gb_Extension_LANGS),$(call gb_Extension_localize_help_onelang,$(1),$(subst lang,$(lang),$(2)),$(3),$(lang)))
+endif
+
+endef
+
+define gb_Extension_localize_help_onelang
+$(call gb_Extension_get_target,$(1)) : $(call gb_Extension_get_workdir,$(1))/$(2)
+$(call gb_Extension_get_workdir,$(1))/$(2) : $(3)
+ $(call gb_Output_announce,$(2),$(true),XHP,3)
+ mkdir -p $$(dir $$@)
+ $(gb_Extension_HELPEXCOMMAND) -i $$< -o $$@ -l $(4) -m $$(SDF3)
+
+endef
+
# vim: set noet sw=4 ts=4:
More information about the Libreoffice-commits
mailing list