summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2015-05-31 11:59:58 -0600
committerLuke Shumaker <lukeshu@sbcglobal.net>2015-05-31 13:37:23 -0600
commit2f0f5979720474ee4e5d7a802cd61c1685be8b38 (patch)
treed99ffafb210da2f61edd02517bc4e3206117b89e
parentbe93a5e25a80b99a00b37334e85d7d815b0b880b (diff)
Enforce .pot files being UTF-8.
-rw-r--r--Makefile2
-rw-r--r--common.mk2
-rwxr-xr-xsrc/lib/librexgettext2
3 files changed, 3 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index db4735f..bba0d46 100644
--- a/Makefile
+++ b/Makefile
@@ -54,7 +54,7 @@ $(addprefix clean-, $(packages)): clean-%: PHONY $$(addsuffix /clean, $$($$*
$(addprefix pot-, $(packages)): pot-%: PHONY po/%.pot
$(addprefix pot-, $(packages)): pot-%: PHONY po/%.pot
$(foreach p,$(packages),po/$p.pot): po/%.pot: $$(addsuffix /everything.pot,$$($$*))
- cat $^ | msguniq -Fi > '$@' || rm -f '$@'
+ cat $^ | msguniq -Fi --to-code=UTF-8 > '$@' || rm -f '$@'
################################################################################
diff --git a/common.mk b/common.mk
index b88ad8d..69bcc06 100644
--- a/common.mk
+++ b/common.mk
@@ -26,7 +26,7 @@ indent = emacs --batch $1 \
# Usage <INPUT $(pofmt) >OUTPUT
# Normalize a .po(t) file
-pofmt = msguniq -Fi
+pofmt = msguniq -Fi --to-code=UTF-8
# Usage: as a variable
# relative path to `/` from $(bindir)
diff --git a/src/lib/librexgettext b/src/lib/librexgettext
index 17345cb..22a6df2 100755
--- a/src/lib/librexgettext
+++ b/src/lib/librexgettext
@@ -157,7 +157,7 @@ main() {
xgettext-sh "${simple[@]}" -- "${files[@]}"
xgettext-sh "${prose[@]}" -- "${files[@]}" | whitespace-collapse
xgettext-flag -- "${files[@]}"
- } | sed '/^\#, sh-format/d' | msguniq -Fi
+ } | sed '/^\#, sh-format/d' | msguniq -Fi --to-code=UTF-8
}
main "$@"