Skip Menu |

This queue is for tickets about the Gnome2-Canvas CPAN distribution.

Report information
The Basics
Id: 127878
Status: resolved
Priority: 0/
Queue: Gnome2-Canvas

People
Owner: XAOC [...] cpan.org
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 1.002
Fixed in: 1.004



Subject: PREREQ_FATAL=>1 should not be used
PREREQ_FATAL=>1 prevents installers like CPAN.pm from doing their job i.e. automatically installing the required dependencies, and probably should be removed nowadays: ... Output from '/usr/bin/perl Makefile.PL': Can't locate Gtk2.pm in @INC (you may need to install the Gtk2 module) (@INC contains: ... .) at (eval 17) line 1. BEGIN failed--compilation aborted at (eval 17) line 1. Checking if your kit is complete... Looks good MakeMaker FATAL: prerequisites not found. Gtk2 not installed Please install these modules first and rerun 'perl Makefile.PL'. ...
On Sat Dec 01 14:22:20 2018, SREZIC wrote: Show quoted text
> PREREQ_FATAL=>1 prevents installers like CPAN.pm from doing their job > i.e. automatically installing the required dependencies, and probably > should be removed nowadays:
That's not the problem. If a Gtk-Perl module has a Makefile.PL with 'PREREQ_FATAL => 1', it's usually wrapped inside of an 'eval {}' block, which catches any fatal errors. For this specific module, there were two problems, both in META.yml: 1) Gtk2 is referenced in the 'requires:' block instead of being in the 'configure_requires:' block. 2) The version of the module was set to 'unknown' I've hacked up the META.yml file on my testing machine (Debian Wheezy 7 with Perl 5.18.4), I moved the dependency on 'Gtk2' to 'configure_requires:', and I also set the version, so that now I'm able to run 'cpanm .' in the git repo for Gnome2::Canvas with no issues, all dependencies auto-install. Note that the C libraries still need to be installed prior to installing the Perl module, because AFAIK there's still no way to auto-install the C libraries along with header files required to build the corresponding Perl module prior to attempting to build that module. The change to META.yml will be pushed out in the next release, do you want to keep this issue open until then, or can we close it?
On 2020-08-21 02:21:45, XAOC wrote: Show quoted text
> On Sat Dec 01 14:22:20 2018, SREZIC wrote:
> > PREREQ_FATAL=>1 prevents installers like CPAN.pm from doing their job > > i.e. automatically installing the required dependencies, and probably > > should be removed nowadays:
> > That's not the problem. If a Gtk-Perl module has a Makefile.PL with > 'PREREQ_FATAL => 1', it's usually wrapped inside of an 'eval {}' > block, which catches any fatal errors. > > For this specific module, there were two problems, both in META.yml: > > 1) Gtk2 is referenced in the 'requires:' block instead of being in the > 'configure_requires:' block. > > 2) The version of the module was set to 'unknown' > > I've hacked up the META.yml file on my testing machine (Debian Wheezy > 7 with Perl 5.18.4), I moved the dependency on 'Gtk2' to > 'configure_requires:', and I also set the version, so that now I'm > able to run 'cpanm .' in the git repo for Gnome2::Canvas with no > issues, all dependencies auto-install. > > Note that the C libraries still need to be installed prior to > installing the Perl module, because AFAIK there's still no way to > auto-install the C libraries along with header files required to build > the corresponding Perl module prior to attempting to build that > module.
To my knowledge, the only system dealing with non-perl dependencies is the CPAN.pm plugin CPAN::Plugin::Sysdeps. The Gnome2::Canvas definitions look like this: https://github.com/eserte/cpan-plugin-sysdeps/blob/1ec83eeb34cf7333cd919bcf3d768fd820077bc0/lib/CPAN/Plugin/Sysdeps/Mapping.pm#L1327-L1334 The other possibility would be to create Alien::* modules for the external deps, but this may easily get quite tedious. Show quoted text
> > The change to META.yml will be pushed out in the next release, do you > want to keep this issue open until then, or can we close it?
Best is to close after release.
Stalling ticket until next release
Installation via cpanm should be working in 1.004. Can you please test and update this ticket? Thanks!
On 2020-10-03 00:06:45, XAOC wrote: Show quoted text
> Installation via cpanm should be working in 1.004. > > Can you please test and update this ticket?
The configure_requires specification looks fine.