-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
Closed
Labels
6.topic: cross-compilationBuilding packages on a different platform than they will be used onBuilding packages on a different platform than they will be used on
Description
Issue description
Cross-compiling perlPackages.XMLParser on nixpkgs' staging branch (e.g. with @shlevy's perl cross-compilation patch, 306d5cd) fails.
Steps to reproduce
$ git -C nixpkgs show
commit 306d5cdf03ad6375861a20b8885ef38699ca3c23
...
$ cat test.nix
let
nixpkgs = import ./nixpkgs {};
crossPkgs = import ./nixpkgs { crossSystem = nixpkgs.lib.systems.examples.armv7l-hf-multiplatform; };
in crossPkgs.perlPackages.XMLParser
$ nix-build ./test.nix
...
patching sources
configuring
patching ./samples/xmlfilter...
patching ./samples/canonical...
patching ./samples/xmlstats...
patching ./samples/xmlcomments...
Expat must be installed prior to building XML::Parser and I can't find
it in the standard library directories. Install 'expat-devel' package with your
OS package manager. See 'README'.
Or you can download expat from:
http://sourceforge.net/projects/expat/
If expat is installed, but in a non-standard directory, then use the
following options to Makefile.PL:
EXPATLIBPATH=... To set the directory in which to find libexpat
EXPATINCPATH=... To set the directory in which to find expat.h
For example:
perl Makefile.PL EXPATLIBPATH=/home/me/lib EXPATINCPATH=/home/me/include
Note that if you build against a shareable library in a non-standard location
you may (on some platforms) also have to set your LD_LIBRARY_PATH environment
variable at run time for perl to find the library.
Checking if your kit is complete...
Warning: prerequisite LWP 0 not found.
Looks good
ERROR from evaluation of /tmp/nix-build-perl-XML-Parser-2.41-arm-unknown-linux-gnueabihf.drv-0/XML-Parser-2.41/Expat/Makefile.PL: Can't load module Tie::Hash::NamedCapture, dynamic loading not available in this perl.
(You may need to build a new perl executable which either supports
dynamic loading or has the Tie::Hash::NamedCapture module statically linked into it.)
at /nix/store/1v96mbpfg5g9n58b74q5yafdfbhl1kj9-perl-5.24.3-arm-unknown-linux-gnueabihf/lib/perl5/5.24.3/English.pm line 155.
Compilation failed in require at /nix/store/1v96mbpfg5g9n58b74q5yafdfbhl1kj9-perl-5.24.3-arm-unknown-linux-gnueabihf/lib/perl5/5.24.3/English.pm line 155.
BEGIN failed--compilation aborted at /nix/store/1v96mbpfg5g9n58b74q5yafdfbhl1kj9-perl-5.24.3-arm-unknown-linux-gnueabihf/lib/perl5/5.24.3/English.pm line 155.
Compilation failed in require at ./Makefile.PL line 3.
BEGIN failed--compilation aborted at ./Makefile.PL line 3.
builder for '/nix/store/g4qzia34nq5r4zizhp3vhl712lavqrkd-perl-XML-Parser-2.41-arm-unknown-linux-gnueabihf.drv' failed with exit code 255
error: build of '/nix/store/g4qzia34nq5r4zizhp3vhl712lavqrkd-perl-XML-Parser-2.41-arm-unknown-linux-gnueabihf.drv' failed
Technical details
Hmmm...
$ nix-shell -p nix-info --run "nix-info -m"
error: undefined variable 'nix-info' at (string):1:94
(use '--show-trace' to show detailed location information)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
6.topic: cross-compilationBuilding packages on a different platform than they will be used onBuilding packages on a different platform than they will be used on