diff options
author | kan <kan@FreeBSD.org> | 2015-08-27 14:00:16 +0000 |
---|---|---|
committer | kan <kan@FreeBSD.org> | 2015-08-27 14:00:16 +0000 |
commit | 956823f74dbb8aeab18ab05c177891148a958f92 (patch) | |
tree | f371bdd01575d2378157ef7e8b70d6f43a24702e /usr.bin | |
parent | 6bd79f6a5ac18d90ce49a0e60e3ad037f490b6a2 (diff) | |
download | FreeBSD-src-956823f74dbb8aeab18ab05c177891148a958f92.zip FreeBSD-src-956823f74dbb8aeab18ab05c177891148a958f92.tar.gz |
Unbreak nvi message catalog generation for 8 bit locales.
Feeding any file encoded in 8 bit locales such as KOI8-RU
to sort utility running under UTF-8 locale produces astonishing
result of recoding the output to UTF-8. To counter that, just
run sort under 'C' locale for now.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/vi/catalog/Makefile | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/vi/catalog/Makefile b/usr.bin/vi/catalog/Makefile index 4e21298..b85eaa8 100644 --- a/usr.bin/vi/catalog/Makefile +++ b/usr.bin/vi/catalog/Makefile @@ -32,9 +32,9 @@ CAT+= $c.UTF-8 .for c in ${CAT} ${c}: ${c}.base - @echo "... $c"; \ + echo "... $c"; \ rm -f $c; \ - sort -u ${.ALLSRC} | \ + env LANG=C sort -u ${.ALLSRC} | \ awk '{ \ if ($$1 == 1) { \ print "\nMESSAGE NUMBER 1 IS NOT LEGAL"; \ @@ -44,7 +44,7 @@ ${c}: ${c}.base print "DUPLICATE MESSAGE NUMBER " $$1; \ exit 1; \ } \ - print $0; \ + print $$0; \ }' | \ sed -e '1s/^/$$set 1~$$quote "~/; 1y/~/\n/' | \ gencat $c /dev/stdin; \ |