FS#63018 - [auto-multiple-choice] Incompatible with Perl 5.30

Attached to Project: Community Packages
Opened by David Haller (davidhaller) - Thursday, 27 June 2019, 08:14 GMT
Last edited by Baptiste (zorun) - Friday, 06 December 2019, 21:32 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Baptiste (zorun)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Auto Multiple Choice (AMC LaTeX) in version 1.4.0-3 fails to start with the current Perl version (5.30).

Steps to reproduce:

$ LANG=C auto-multiple-choice

Can't locate Locale/Language.pm in @INC (you may need to install the Locale::Language module) (@INC contains: /usr/lib/perl5/5.30/site_perl /usr/share/perl5/site_perl /usr/lib/perl5/5.30/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5/5.30/core_perl /usr/share/perl5/core_perl) at /usr/lib/AMC/perl/AMC-gui.pl line 43.
BEGIN failed--compilation aborted at /usr/lib/AMC/perl/AMC-gui.pl line 43.

I tried to locate the Language.pm file with pacman -Fs Language.pm, in case the file has been moved to another package, but this doesn't seem to be the case.

Workaround:

Remove the "use Locale::Language;"-Line at 43 in file /usr/lib/AMC/perl/AMC-gui.pl, then AMC runs. Surprisingly with a German GUI (if I omit LANG=C and use my default German locale), so the Locale::Language seems to not be responsible for GUI i18n, but surely for something else that will crash the application at some point.

I don't know anything about Perl, but the documentation shows that the Locale::Language module is present at 5.28 but not at 5.30. See: https://perldoc.perl.org/5.28.0/Locale/Language.html.

Upstream should port the application to the new Perl version. Other Linux distributions will be affected too when they upgrade Perl. The next Debian Stable (Buster) will come with Perl 5.28, so running AMC in a Debian container might be a workaround for users too.
This task depends upon

Closed by  Baptiste (zorun)
Friday, 06 December 2019, 21:32 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in 1.4.0-5
Comment by David Haller (davidhaller) - Thursday, 05 December 2019, 10:35 GMT
I got AMC to work with Perl 3.0 by installing the missing Locale::Language module locally using CPAN.

First, you need to run the "cpan" command, which will set up a local directory for Perl modules in your home. It will also modify your .bashrc to change the required environment variables so that Perl can find the installed modules.

After this setup step, I ran (inside the cpan shell) the command "install Locale::Language". AMC is working again!

So, to fix this bug, the Locale:Language module must be packaged for Arch Linux and included as an dependency.
Comment by Baptiste (zorun) - Friday, 06 December 2019, 21:32 GMT
Thanks for figuring it out! I just packaged Locale::Language and added a dependency to it.

Loading...