Bug 30084 - Remove dependency of liblocale-codes-perl
Summary: Remove dependency of liblocale-codes-perl
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Packaging (show other bugs)
Version: Main
Hardware: All All
: P5 - low major
Assignee: Mason James
QA Contact: Testopia
URL:
Keywords:
Depends on: 25920
Blocks:
  Show dependency treegraph
 
Reported: 2022-02-11 18:54 UTC by Fridolin Somers
Modified: 2023-12-28 20:43 UTC (History)
7 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
22.05.00,21.11.03,21.05.13,20.11.17
Circulation function:


Attachments
Bug 25920: Remove explicit dependency of liblocale-codes-perl (1.07 KB, patch)
2022-02-11 18:58 UTC, Fridolin Somers
Details | Diff | Splinter Review
Bug 30084: Remove explicit dependency of liblocale-codes-perl (1.18 KB, patch)
2022-02-11 19:01 UTC, Fridolin Somers
Details | Diff | Splinter Review
Bug 30084: Remove explicit dependency of liblocale-codes-perl (1.23 KB, patch)
2022-02-14 21:50 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 30084: Remove explicit dependency of liblocale-codes-perl (1.41 KB, patch)
2022-02-18 11:16 UTC, Mason James
Details | Diff | Splinter Review
Bug 30084: Remove explicit dependency of liblocale-codes-perl (1.28 KB, patch)
2022-02-18 14:43 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 30084 - Remove dependency of liblocale-codes-perl (follow-up) (781 bytes, patch)
2022-03-02 05:55 UTC, Mason James
Details | Diff | Splinter Review
Bug 30084: Remove dependency of liblocale-codes-perl (follow-up) (780 bytes, patch)
2022-03-02 05:56 UTC, Mason James
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Fridolin Somers 2022-02-11 18:54:51 UTC
Bug 25920 follow work on liblocale-codes-perl
Comment 1 Fridolin Somers 2022-02-11 18:58:10 UTC
Created attachment 130520 [details] [review]
Bug 25920: Remove explicit dependency of liblocale-codes-perl
Comment 2 Fridolin Somers 2022-02-11 19:01:28 UTC
Created attachment 130521 [details] [review]
Bug 30084: Remove explicit dependency of liblocale-codes-perl

1/ apply patch

2/ build and install new koha-common package

3/ confirm liblocale-codes-perl pkg is installed
 $ apt-cache policy liblocale-codes-perl | grep Installed
 Installed: 3.62-1
Comment 3 Katrin Fischer 2022-02-14 21:50:18 UTC
Created attachment 130582 [details] [review]
Bug 30084: Remove explicit dependency of liblocale-codes-perl

1/ apply patch

2/ build and install new koha-common package

3/ confirm liblocale-codes-perl pkg is installed
 $ apt-cache policy liblocale-codes-perl | grep Installed
 Installed: 3.62-1

https://bugs.koha-community.org/show_bug.cgi?id=30084

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 4 Katrin Fischer 2022-02-14 21:51:21 UTC
Signing off, seeing why and how this was changed, but couldn't test the package. Leaving this for QA.
Comment 5 Jonathan Druart 2022-02-18 09:51:48 UTC
Hum I am not sure.

From bug 25920 comment 15, Mason wrote:
"""
it seems that 'perl' and 'perl-modules-5.30' packages need it

root@kohadevbox:kohadevbox$ apt-cache rdepends liblocale-codes-perl
liblocale-codes-perl
Reverse Depends:
  perl-modules-5.30
  koha-perldeps
  koha-core
  koha-common
  perl-modules-5.30
  perl
 |w3c-linkchecker
  publican
 |libhtml-microformats-perl
 |libhtml-html5-sanity-perl
 |libdist-zilla-localetextdomain-perl
 |libbusiness-onlinepayment-ippay-perl
 |libbusiness-isin-perl
  ledgersmb
  auto-multiple-choice-common
  perl
"""

But now on D11 I get:
% apt-cache rdepends liblocale-codes-perl
liblocale-codes-perl
Reverse Depends:
  gscan2pdf
  koha-perldeps
  koha-core
  koha-common |w3c-linkchecker
  publican
 |libhtml-html5-sanity-perl
 |libdist-zilla-localetextdomain-perl
 |libbusiness-onlinepayment-ippay-perl
 |libbusiness-isin-perl
  ledgersmb
  auto-multiple-choice-common

Is this patch still correct, Mason?
Comment 6 Mason James 2022-02-18 10:03:16 UTC
(In reply to Jonathan Druart from comment #5)
> Hum I am not sure.
> 
> Is this patch still correct, Mason?

the patch looks correct,  the 'perl' package should install liblocale-codes-perl without us needing to declare it
Comment 7 Mason James 2022-02-18 11:05:26 UTC
[23:02:31] <@Joubu> mtj: from where will it get pulled?
[23:03:02] <@Joubu> we were assuming it was part of perl deps, but it looks like it's not true on (at least) D11
[23:04:31] <mtj> aah, yes - you are correct
[23:05:19] <mtj> ..we will need to explicitly declare it for deb11 (and others?)
[23:06:54] <mtj> well spotted Joubu++
[23:06:56] <@Joubu> mtj: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25920#c14
[23:06:57] <huginn> Bug 25920: blocker, P1 - high, ---, mtj, Pushed to oldstable , Add liblocale-codes-perl package to fix ubuntu-stable (focal)
[23:07:00] <@Joubu> this is the original question
[23:07:07] <@Joubu> "why do we need it?" :D
[23:07:38] <@Joubu> I have to admit I've lost track
[23:08:48] <mtj> looking now
[23:10:51] <@Joubu> mtj: we are using several Locale::* perl packages, but I don't think they are coming from this package
[23:14:09] <mtj> hmmm, it looks likely the package is not needed at all ﷐[U+1F914]﷑
[23:17:35] <mtj> aaah, liblocale-codes-perl package provides 'Locale::Language' module - which we do need
[23:20:54] <@Joubu> liblocale-po-perl: /usr/share/perl5/Locale/PO.pm
[23:20:55] <@Joubu> libintl-perl: /usr/share/perl5/Locale/Messages.pm
[23:21:13] <@Joubu> libtemplate-plugin-gettext-perl: /usr/share/perl5/Locale/XGettext/TT2.pm
[23:22:19] <@Joubu> liblocale-currency-format-perl: /usr/share/perl5/Locale/Currency/Format.pm
[23:22:28] <@Joubu> that's all what I see for Locale::
[23:23:45] <@Joubu> @later tell davidnind Hi David, could you add a SO stamp on 29940?
[23:23:46] <huginn> Joubu: The operation succeeded.
[23:28:54] <@Joubu> mtj: are you on it?
[23:30:39] <mtj> Joubu: yep
[23:33:33] <mtj> git blame says 'Locale::Language' has been a dep since 2010
[23:46:53] <mtj> ping Joubu, can you run 'apt-cache policy liblocale-codes-perl'
[23:47:23] <mtj> ..if you dont have liblocale-codes-perl installed - dont install it yet :)
[23:52:57] <pastebot> Someone at 127.0.0.1 pasted "liblocale-codes-perl: Installe" (7 lines) at https://paste.koha-community.org/7845
[23:53:01] <@Joubu> mtj: ^^
[23:56:30] <mtj> Joubu: looks like locale::lang was included in the fisrt version of the Makefile   d0cc4b29c7d
[23:56:56] <mtj> from 2007
[00:00:00] - {Day changed to 19 February 2022}
[00:00:58] <mtj> Joubu: it was used by ./misc/translator/po/stats.pl - which is now deleted :)
[00:02:00] <mtj> ..so we confirm that liblocale-codes-perl aka Locale::Language, is not required
[00:03:33] <mtj> git reset --hard b695a10e
[00:03:49] <mtj> $ grep -ir   'Locale::Lang' ./*
[00:03:49] <mtj> ./misc/translator/po/stats.pl:use Locale::Language;
Comment 8 Mason James 2022-02-18 11:13:17 UTC
(In reply to Mason James from comment #6)
> (In reply to Jonathan Druart from comment #5)
> > Hum I am not sure.
> > 
> > Is this patch still correct, Mason?
> 
> the patch looks correct,  the 'perl' package should install
> liblocale-codes-perl without us needing to declare it

fyi, patch is still correct

some versions of perl may require liblocale-codes-perl, but koha itself does not
 :)
Comment 9 Mason James 2022-02-18 11:16:59 UTC
Created attachment 130818 [details] [review]
Bug 30084: Remove explicit dependency of liblocale-codes-perl

1/ apply patch

2/ build and install new koha-common package

3/ confirm liblocale-codes-perl pkg is installed
 $ apt-cache policy liblocale-codes-perl | grep Installed
 Installed: 3.62-1

https://bugs.koha-community.org/show_bug.cgi?id=30084

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Mason James <mtj@kohaaloha.com>
Comment 10 Jonathan Druart 2022-02-18 11:37:41 UTC
Yes, patch is correct but not complete, why don't we then remove

debian/control: liblocale-codes-perl,
debian/control: liblocale-codes-perl,

?
Comment 11 Jonathan Druart 2022-02-18 14:41:04 UTC
Applying: Bug 30084: Remove explicit dependency of liblocale-codes-perl
error: sha1 information is lacking or useless (debian/list-deps).
error: could not build fake ancestor
Patch failed at 0001 Bug 30084: Remove explicit dependency of liblocale-codes-perl


Commit message need to be updated as well.
Comment 12 Jonathan Druart 2022-02-18 14:41:29 UTC
(In reply to Jonathan Druart from comment #10)
> Yes, patch is correct but not complete, why don't we then remove
> 
> debian/control: liblocale-codes-perl,
> debian/control: liblocale-codes-perl,
> 
> ?

This file is autogenerated, no need to modify it actually.
Comment 13 Jonathan Druart 2022-02-18 14:43:26 UTC
Created attachment 130861 [details] [review]
Bug 30084: Remove explicit dependency of liblocale-codes-perl

1/ apply patch

2/ build and install new koha-common package

=> Package liblocale-codes-perl is not installed, Koha does not need it

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Mason James <mtj@kohaaloha.com>

JD amended patch: fix commit message
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 14 Fridolin Somers 2022-02-22 01:14:55 UTC
Pushed to master for 22.05, thanks to everybody involved ﷐[U+1F984]﷑
Comment 15 Kyle M Hall (khall) 2022-02-25 12:43:52 UTC
Should this be backported to 21.11.x? If so, it seems incoomplete as it doesn't reference list-deps
Comment 16 Mason James 2022-02-27 01:45:30 UTC
(In reply to Kyle M Hall from comment #15)
> Should this be backported to 21.11.x? If so, it seems incoomplete as it
> doesn't reference list-deps

the patch can be backported to 19.11.x

it does modify list-deps, and looks complete to me :)
Comment 17 Kyle M Hall (khall) 2022-02-28 13:19:28 UTC
(In reply to Mason James from comment #16)
> (In reply to Kyle M Hall from comment #15)
> > Should this be backported to 21.11.x? If so, it seems incoomplete as it
> > doesn't reference list-deps
> 
> the patch can be backported to 19.11.x
> 
> it does modify list-deps, and looks complete to me :)

Apologies, I should have wrote debian/control
Comment 18 Kyle M Hall (khall) 2022-02-28 13:20:53 UTC
Pushed to 21.11.x for 21.11.03
Comment 20 Mason James 2022-03-02 05:56:39 UTC
Created attachment 131231 [details] [review]
Bug 30084: Remove dependency of liblocale-codes-perl (follow-up)

trival patch, no test plan
Comment 21 Mason James 2022-03-02 06:00:59 UTC
(In reply to Mason James from comment #20)
> Created attachment 131231 [details] [review] [review]
> Bug 30084: Remove dependency of liblocale-codes-perl (follow-up)
> 
> trival patch, no test plan

hi Frido, Kyle, here is a small follow-up patch
Comment 22 Fridolin Somers 2022-03-02 06:24:10 UTC
(In reply to Mason James from comment #21)
> (In reply to Mason James from comment #20)
> > Created attachment 131231 [details] [review] [review] [review]
> > Bug 30084: Remove dependency of liblocale-codes-perl (follow-up)
> > 
> > trival patch, no test plan
> 
> hi Frido, Kyle, here is a small follow-up patch

Follow-up pushed to master for 22.05
Comment 23 Andrew Fuerste-Henry 2022-03-20 14:50:10 UTC
Pushed to 21.05.x for 21.05.13
Comment 24 Victor Grousset/tuxayo 2022-03-21 00:13:20 UTC
Backported: Pushed to 20.11.x branch for 20.11.17
Comment 25 Wainui Witika-Park 2022-03-21 00:40:42 UTC
Does this need to be backported to 19.11.x?