Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build fail with perl 5.14 #201

Closed
amba opened this issue Nov 23, 2016 · 10 comments
Closed

build fail with perl 5.14 #201

amba opened this issue Nov 23, 2016 · 10 comments

Comments

@amba
Copy link
Contributor

amba commented Nov 23, 2016

Hi,
on a pristine 5.14 environment I get this build failure:

$ cpanm -v -n PDL

Running Mkbootstrap for Core () chmod 644 "Core.bs" "/home/simon/.plenv/versions/5.14.4/bin/perl5.14.4" -MExtUtils::Command::MM -e 'cp_nonempty' -- Core.bs ../../blib/arch/auto/PDL/Core/Core.bs 644 "/home/simon/.plenv/versions/5.14.4/bin/perl5.14.4" "/home/simon/.plenv/versions/5.14.4/lib/perl5/5.14.4/ExtUtils/xsubpp" -typemap '/home/simon/.plenv/versions/5.14.4/lib/perl5/5.14.4/ExtUtils/typemap' -typemap '/home/simon/.cpanm/work/1479896084.7128/PDL-2.017/Basic/Core/typemap' Core.xs > Core.xsc Undefined subroutine &ExtUtils::ParseXS::errors called at /home/simon/.plenv/versions/5.14.4/lib/perl5/5.14.4/ExtUtils/xsubpp line 41. Makefile:380: recipe for target 'Core.c' failed make[2]: *** [Core.c] Error 255 make[2]: Leaving directory '/home/simon/.cpanm/work/1479896084.7128/PDL-2.017/Basic/Core' Makefile:515: recipe for target 'subdirs' failed make[1]: *** [subdirs] Error 2 make[1]: Leaving directory '/home/simon/.cpanm/work/1479896084.7128/PDL-2.017/Basic' Makefile:538: recipe for target 'subdirs' failed make: *** [subdirs] Error 2 ! Installing PDL failed. See /home/simon/.cpanm/work/1479896084.7128/build.log for details. Retry with --force to force install it. FAIL 1 distribution installed
The whole build log is here: http://pastebin.ca/3741536

When repeating the cpanm command, it succeeds. When I then uninstall PDL and ExtUtils::ParseXS and repeat the install it fails again.

OS is Linux.

Cheers, Simon

@devel-chm
Copy link
Member

Looks like ExtUtils::ParseXS needs to be added to prereqs configure requires (at least).

@devel-chm
Copy link
Member

Could you please attach output from perl -V and determine what version of ExtUtils::MakeMaker you have. This seems to be a prerequisites build problem but it may not be the specification in the PDL distribution but possibly in the tool chain versions. Thanks.

@amba
Copy link
Contributor Author

amba commented Nov 26, 2016

Perl -V output: http://pastebin.ca/3742397
ExtUtils::MakeMaker version is 6.57_05.
ExtUtils::ParseXS version before trying to install PDL is '2.2210'.

I ran into this when the travis-ci test for Lab::Measurement failed after adding PDL as a prerequisite: travis-ci.org/lab-measurement/lab-measurement/builds/178234540

The problem seems to be, that the required version of ExtUtils::ParseXS is installed after creating the Makefiles.

One can workaround, of course, by installing a recent ExtUtils::ParseXS before PDL.

@devel-chm
Copy link
Member

I think the problem may be version skew or something between the core xsubpp install and the one from ExtUtils::ParseXS. I'm puzzled that you have a developers release of ExtUtils::MakeMaker 6.57_05 while the checks during the build seem to indicate 6.58 is present. Does the problem persist if you use a higher version of ExtUtils::MakeMaker? Maybe we need to bump the required version for PDL to avoid bitrot.

@amba
Copy link
Contributor Author

amba commented Nov 26, 2016

No, even with the most recent version of ExtUtils::MakeMaker installed, the 'cpanm PDL' command still fails.
It seems to be all about the ExtUtils::ParseXS version that is present before the PDL install is started.

@mohawk2
Copy link
Member

mohawk2 commented Nov 26, 2016

ExtUtils::ParseXS needs to be specified, at the right version, as a build (not configure) requirement. It is so specified, at line 459 of my local copy of PDL. Is an up-to-date version of cpanm running on that perl?

@amba
Copy link
Contributor Author

amba commented Nov 26, 2016

The version of cpanm in the initial failure was:

cpanm (App::cpanminus) version 1.7024 (/home/travis/perl5/perlbrew/bin/cpanm)

Which is provided by the perlbrew environment used by travis-ci.

I then reproduced locally in a 5.14 environment installed with plenv, which uses the most recent version of cpanm:

cpanm (App::cpanminus) version 1.7042 (/home/simon/.plenv/versions/5.14.4/bin/cpanm)

@devel-chm
Copy link
Member

If you put the ExtUtils::ParseXS into CONFIGURE_REQUIRES, does that fix it for you?

@amba
Copy link
Contributor Author

amba commented Nov 26, 2016

If you put the ExtUtils::ParseXS into CONFIGURE_REQUIRES, does that fix it for you?

Yeah, E::P then gets installed before PDL's Makefile.PL is run and everything builds fine.

@mohawk2
Copy link
Member

mohawk2 commented Jan 2, 2017

@amba I've had a look through the build log, thanks for that. On further pondering, the reason why the correct EU::PXS is needed at configure-time is because the configured build files, ie the Makefiles, hardcodes the path to the xsubpp found during configure. If the updated PXS isn't there yet, it won't hardcode in the correct one.

Therefore, this needs to be a CONFIGURE_REQUIRES. It is however still also a BUILD_REQUIRES, so let's not delete it from there. Configure and build can sometimes happen on separate machines, rather than straight after each other on the same machine.

@mohawk2 mohawk2 mentioned this issue Jan 2, 2017
amba added a commit to amba/pdl that referenced this issue Jan 3, 2017
Also, the line in .travis.yml which installes a recent E::P is no longer
needed.
@amba amba closed this as completed Jan 14, 2017
d-lamb pushed a commit that referenced this issue Jan 19, 2019
Also, the line in .travis.yml which installes a recent E::P is no longer
needed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants