Bug 227444 - textproc/intltool: intltool-update is broken by Perl 5.26
Summary: textproc/intltool: intltool-update is broken by Perl 5.26
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-gnome mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-04-11 09:32 UTC by dan-freebsd
Modified: 2018-08-29 04:15 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dan-freebsd 2018-04-11 09:32:31 UTC
Since Perl 5.22, intltool-update has been triggering warnings

$ intltool-update 
Unescaped left brace in regex is deprecated, passed through in regex; marked by <-- HERE in m/\${ <-- HERE ?PACKAGE_NAME}?/ at /usr/local/bin/intltool-update line 1071, <CONF> line 295.

Since FreeBSD updated Perl to version 5.26 this has become a fatal error

$ intltool-update 
Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/\${ <-- HERE ?PACKAGE_NAME}?/ at /usr/local/bin/intltool-update line 1071, <CONF> line 295.

Essentially intltool is completely broken & unusable right now.

The bug is reported upstream here & a patch is available there:

  https://bugs.launchpad.net/intltool/+bug/1490906

Please include this patch available in the intltool port for FreeBSD 10 and 11.

Current package versions showing the error:

intltool-0.51.0_1
perl5-5.26.1
Comment 1 dan-freebsd 2018-04-11 12:31:10 UTC
I notice FreeBSD already carries a patch to intltool to addresses these problems, unfortunately the patch in question is incomplete, missing one key chunk. eg compare

https://github.com/freebsd/freebsd-ports/blob/master/textproc/intltool/files/patch-intltool-update.in

To the current patch Fedora carries

https://src.fedoraproject.org/rpms/intltool/blob/master/f/intltool-perl5.26-regex-fixes.patch

There's one key difference missing in the FreeBSD patch

-        $sub = $varhash{$2} if defined $varhash{$2} and $varhash{$2} !~ /\${?$2}?/;

+        $sub = $varhash{$2} if defined $varhash{$2} and $varhash{$2} !~ /\$\{?$2}?/;
Comment 2 Nathan 2018-08-29 04:15:20 UTC
Using Perl5 v.26 and I get:
intltool-update 
intltool-update: Unable to proceed.
Make sure to run this script inside the po directory.

So I am not getting this error