From 8cc506634a111542bd86b65a8485303cedf54766 Mon Sep 17 00:00:00 2001 From: Charles Gagnon Date: Wed, 8 Feb 2023 08:37:49 -0500 Subject: [PATCH] Adjust makefile for UI translations --- .gitignore | 2 +- Makefile | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 521746a..4260d07 100644 --- a/.gitignore +++ b/.gitignore @@ -4,4 +4,4 @@ gschemas.compiled dash-to-panel@jderose9.github.com*.zip *.mo po/dash-to-panel.pot -Settings.ui.h +*.ui.h diff --git a/Makefile b/Makefile index e1c23e1..934aedb 100644 --- a/Makefile +++ b/Makefile @@ -50,11 +50,15 @@ mergepo: potfile msgmerge -U $$l ./po/dash-to-panel.pot; \ done; -./po/dash-to-panel.pot: $(TOLOCALIZE) Settings.ui +./po/dash-to-panel.pot: $(TOLOCALIZE) mkdir -p po xgettext -k_ -kN_ -o po/dash-to-panel.pot --package-name "Dash To Panel" $(TOLOCALIZE) --from-code=UTF-8 - intltool-extract --type=gettext/glade Settings.ui - xgettext -k_ -kN_ --join-existing -o po/dash-to-panel.pot Settings.ui.h + + for l in $(UI_MODULES) ; do \ + intltool-extract --type=gettext/glade $$l; \ + xgettext -k_ -kN_ -o po/dash-to-panel.pot $$l.h --join-existing --from-code=UTF-8; \ + done; + sed -i -e 's/&\#10;/\\n/g' po/dash-to-panel.pot ./po/%.mo: ./po/%.po