Mageia Bugzilla – Attachment 10951 Details for
Bug 24671
Upgrading M6.0 official to M7 B3 round 3 does not respect current country
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Patch to cause the installer to preserve the existing locale settings on upgrade
0002-installer-preserve-existing-locale-settings-on-upgra.patch (text/plain), 1.34 KB, created by
Martin Whitaker
on 2019-04-19 01:48:29 CEST
(
hide
)
Description:
Patch to cause the installer to preserve the existing locale settings on upgrade
Filename:
MIME Type:
Creator:
Martin Whitaker
Created:
2019-04-19 01:48:29 CEST
Size:
1.34 KB
patch
obsolete
>From 8667c34907a02e05a5f5d7a9537fb974cd1b8f46 Mon Sep 17 00:00:00 2001 >From: Martin Whitaker <mageia@martin-whitaker.me.uk> >Date: Thu, 18 Apr 2019 21:18:30 +0100 >Subject: [PATCH 2/2] installer: preserve existing locale settings on upgrade > (mga#24671) > > >diff --git a/perl-install/install/NEWS b/perl-install/install/NEWS >index c7151e368..657bf0ab7 100644 >--- a/perl-install/install/NEWS >+++ b/perl-install/install/NEWS >@@ -1,3 +1,4 @@ >+- preserve existing locale settings on upgrade (mga#24671) > - store country code in /etc/locale.conf (mga#24671) > - don't automatically change time zone on upgrade (mga#24670) > - partitioning: fix resize of encrypted partitions (mga#22032) >diff --git a/perl-install/install/steps.pm b/perl-install/install/steps.pm >index 5dd31bf62..285feb8a9 100644 >--- a/perl-install/install/steps.pm >+++ b/perl-install/install/steps.pm >@@ -126,7 +126,13 @@ sub selectLanguage { > $o->charsetChanged; > > addToBeDone { >- lang::write_langs($o->{locale}{langs}); >+ if ($o->{isUpgrade}) { >+ #- preserve existing locale settings (mga#24671) >+ $o->{locale} = lang::read(); >+ $o->{locale}{langs}{$o->{locale}{lang}} = 1; >+ } else { >+ lang::write_langs($o->{locale}{langs}); >+ } > } 'formatPartitions'; > addToBeDone { > lang::write_and_install($o->{locale}, $o->do_pkgs); >-- >2.21.0 >
From 8667c34907a02e05a5f5d7a9537fb974cd1b8f46 Mon Sep 17 00:00:00 2001 From: Martin Whitaker <mageia@martin-whitaker.me.uk> Date: Thu, 18 Apr 2019 21:18:30 +0100 Subject: [PATCH 2/2] installer: preserve existing locale settings on upgrade (mga#24671) diff --git a/perl-install/install/NEWS b/perl-install/install/NEWS index c7151e368..657bf0ab7 100644 --- a/perl-install/install/NEWS +++ b/perl-install/install/NEWS @@ -1,3 +1,4 @@ +- preserve existing locale settings on upgrade (mga#24671) - store country code in /etc/locale.conf (mga#24671) - don't automatically change time zone on upgrade (mga#24670) - partitioning: fix resize of encrypted partitions (mga#22032) diff --git a/perl-install/install/steps.pm b/perl-install/install/steps.pm index 5dd31bf62..285feb8a9 100644 --- a/perl-install/install/steps.pm +++ b/perl-install/install/steps.pm @@ -126,7 +126,13 @@ sub selectLanguage { $o->charsetChanged; addToBeDone { - lang::write_langs($o->{locale}{langs}); + if ($o->{isUpgrade}) { + #- preserve existing locale settings (mga#24671) + $o->{locale} = lang::read(); + $o->{locale}{langs}{$o->{locale}{lang}} = 1; + } else { + lang::write_langs($o->{locale}{langs}); + } } 'formatPartitions'; addToBeDone { lang::write_and_install($o->{locale}, $o->do_pkgs); -- 2.21.0
View Attachment As Raw
Actions:
View
Attachments on
bug 24671
:
10937
|
10938
|
10950
| 10951