Subject: | Inline/CPP/Config.pm installed into noarch specific path |
Inline/CPP/Config.pm file contains compiler flags that are specific to a platform where Makefile.PL was executed. E.g. on my x86_64 machine it contains:
# DO NOT MANUALLY ALTER THE FOLLOWING TWO LINES: Makefile.PL locates them by
# matching their syntax and identifier names.
our $compiler = 'g++ -D_REENTRANT -D_GNU_SOURCE -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fwrapv -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xc++';
That means the file is not portable across platforms and should be installed into architecture specific path (INST_ARCHLIB, not INST_LIB in ExtUtils::MakeMaker terminology). Again on machine it's installed into:
/usr/share/perl5/vendor_perl/Inline/CPP/Config.pm
But it should be installed into:
/usr/lib64/perl5/vendor_perl/Inline/CPP/Config.pm
This does not a big issue if a user installs Inline-CPP manually on his host. But when it comes to prebuilding software once and distributing it to many machines multiple times (like Linux distributions do or when sharing them via NFS in a large company), it reveals that the compiler command does not match the target host.