diff mbox series

[2/2] vim: Improve locale handling

Message ID 20231114233220.2567795-2-richard.purdie@linuxfoundation.org
State Accepted, archived
Commit 042c1a501b1dae5ddb31307b461be02c3591c589
Headers show
Series [1/2] oeqa/selftest/reproducible: Add OEQA_REPRODUCIBLE_EXCLUDED_PACKAGES support | expand

Commit Message

Richard Purdie Nov. 14, 2023, 11:32 p.m. UTC
When making checkouts from git, the timestamps can vary and occasionally two files
can end up with the same stamp. This triggers make to regenerate ru.cp1251.po from
ru.po for example. If it isn't regenerated, the output isn't quite the same leading
to reproducibility issues (CP1251 vs cp1251).

Since we added all locales to buildtools tarball now, we can drop the locale
restrictions too. We need to generate a native binary for the sjis conversion
tool so also tweak that.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-support/vim/vim.inc | 14 ++++----------
 1 file changed, 4 insertions(+), 10 deletions(-)

Comments

Polampalli, Archana Nov. 15, 2023, 12:11 p.m. UTC | #1
Hi Richard,

I am planning to send Vim upgrade patch for all branches.

Could you please confirm Is it applicable to other branches as well, if yes please confirm are you planning to send other branches also It will avoid patch conflicts to further vim patches.

Regards,
Archana
Richard Purdie Nov. 15, 2023, 12:37 p.m. UTC | #2
On Wed, 2023-11-15 at 12:11 +0000, Polampalli, Archana wrote:
> 
> Hi Richard,
> 
> 
> I am planning to send Vim upgrade patch for all branches.
> 
> 
> Could you please confirm Is it applicable to other branches as well,
> if yes please confirm are you planning to send other branches also It
> will avoid patch conflicts to further vim patches.

It is applicable to all branches and I believe our LTS maintainer has
it queued for them already.

Cheers,

Richard
Polampalli, Archana Nov. 15, 2023, 1:21 p.m. UTC | #3
Thank you for the confirmation.

Regards,
Archana
diff mbox series

Patch

diff --git a/meta/recipes-support/vim/vim.inc b/meta/recipes-support/vim/vim.inc
index 58025828f2b..38212a1fa60 100644
--- a/meta/recipes-support/vim/vim.inc
+++ b/meta/recipes-support/vim/vim.inc
@@ -40,22 +40,16 @@  do_configure () {
     cd src
     rm -f auto/*
     touch auto/config.mk
+    # git timestamps aren't reliable and we want to consistently regenerate these generated files
+    rm -f po/cs.cp1250.po po/ja.euc-jp.po po/ja.sjis.po po/ko.po po/pl.UTF-8.po po/pl.cp1250.po po/ru.cp1251.po po/sk.cp1250.po po/uk.cp1251.po po/zh_CN.po po/zh_CN.cp936.po po/zh_TW.po
     aclocal
     autoconf
     cd ..
     oe_runconf
     touch src/auto/configure
     touch src/auto/config.mk src/auto/config.h
-}
-
-do_compile() {
-    # We do not support fully / correctly the following locales.  Attempting
-    # to use these with msgfmt in order to update the ".desktop" files exposes
-    # this problem and leads to the compile failing.
-    for LOCALE in cs fr ko pl sk zh_CN zh_TW;do
-        echo -n > src/po/${LOCALE}.po
-    done
-    autotools_do_compile
+    # need a native tool, not a target one
+    ${BUILD_CC} src/po/sjiscorr.c -o src/po/sjiscorr
 }
 
 PACKAGECONFIG ??= "\