summaryrefslogtreecommitdiffhomepage
path: root/build
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2023-06-25 18:54:22 +0200
committerThomas Voss <mail@thomasvoss.com> 2023-06-25 18:54:22 +0200
commita4ce08bde0bcef664706b78146077ad7053a468b (patch)
tree6671037e22591b98def5e99a7e2fbf3a5a0c7ff0 /build
parent529114f2c769c359f2c0353631a183670d3dbebe (diff)
Make sorting stuff much faster
Diffstat (limited to 'build')
-rwxr-xr-xbuild22
1 files changed, 14 insertions, 8 deletions
diff --git a/build b/build
index 66cf511..1a4d07e 100755
--- a/build
+++ b/build
@@ -221,10 +221,13 @@ compile_for_lang() {
}
END {
- if (lang == "en")
- asort(col)
- else
- asort(col, col, "bilingual_sort")
+ locale = lang == "pt" \
+ ? "pt_BR.UTF-8" \
+ : lang "_" toupper(lang) ".UTF-8"
+
+ CMD = "LC_ALL=" locale " ./bilingual_sort"
+ asort(col, col, "bilingual_sort")
+ close(CMD)
for (i = 1; i <= 3; i++) {
if (i == 3 && denom == 5) {
@@ -289,10 +292,13 @@ compile_for_lang() {
}
END {
- if (lang == "en")
- asort(col)
- else
- asort(col, col, "bilingual_sort")
+ locale = lang == "pt" \
+ ? "pt_BR.UTF-8" \
+ : lang "_" toupper(lang) ".UTF-8"
+
+ CMD = "LC_ALL=" locale " ./bilingual_sort"
+ asort(col, col, "bilingual_sort")
+ close(CMD)
for (i = 1; i <= 2; i++) {
if (i == 1)