Discussion:
[perl #125411] [PATCH] ExtUtils::ParseXS on "perl in space"
via RT
2015-06-14 23:54:51 UTC
Permalink
# New Ticket Created by
# Please include the string: [perl #125411]
# in the subject line of all future correspondence about this issue.
# <URL: https://rt.perl.org/Ticket/Display.html?id=125411 >


This is a bug report for perl from ***@cpan.org,
generated with the help of perlbug 1.40 running under perl 5.20.1.


-----------------------------------------------------------------

ExtUtils::ParseXS INCLUDE_COMMAND with $^X fails on "Perl in Space"
(ie when perl is installed in a location with a space). This patch fixes.

-----------------------------------------------------------------
---
Flags:
category=library
severity=medium
Type=Patch
PatchStatus=HasPatch
module=ExtUtils::ParseXS
---
Site configuration information for perl 5.20.1:

Configured by user at Mon Jan 19 06:11:50 GMT 2015.

Summary of my perl5 (revision 5 version 20 subversion 1) configuration:
Commit id: 4f732e9acf9b96a6e70ba729c7eae63906b663e5
Platform:
osname=linux, osvers=2.6.32-431.17.1.el6.x86_64, archname=x86_64-linux
uname='linux localhost.localdomain 2.6.32-431.17.1.el6.x86_64 #1 smp wed may 7 23:32:49 utc 2014 x86_64 x86_64 x86_64 gnulinux '
config_args='-de -Dprefix=/usr -Duserelocatableinc -Dinstallsitearch=.../../lib/perl5/site_perl/5.20.1/x86_64-linux -Dinstallsitelib=.../../lib/perl5/site_perl/5.20.1 -Dsitearch=.../../lib/perl5/site_perl/5.20.1/x86_64-linux -Dsitelib=.../../lib/perl5/site_perl/5.20.1'
hint=recommended, useposix=true, d_sigaction=define
useithreads=undef, usemultiplicity=undef
use64bitint=define, use64bitall=define, uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler:
cc='gcc', ccflags ='-fwrapv -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
optimize='-O2',
cppflags='-fwrapv -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
ccversion='', gccversion='4.4.7 20120313 (Red Hat 4.4.7-11)', gccosandvers=''
intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=8, prototype=define
Linker and Libraries:
ld='cc', ldflags =' -fstack-protector -L/usr/local/lib'
libpth=/usr/local/lib /usr/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64
libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc
perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc
libc=libc-2.12.so, so=so, useshrplib=false, libperl=libperl.a
gnulibc_version='2.12'
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
cccdlflags='-fPIC', lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector'


---
@INC for perl 5.20.1:
/usr/lib/perl5/site_perl/5.20.1/x86_64-linux
/usr/lib/perl5/site_perl/5.20.1
/usr/lib/perl5/5.20.1/x86_64-linux
/usr/lib/perl5/5.20.1
.

---
Environment for perl 5.20.1:
HOME=/home/user
LANG=en_US.UTF-8
LANGUAGE (unset)
LC_COLLATE=POSIX
LD_LIBRARY_PATH=/opt/gimp2.8/lib:/opt/gcc482inst/lib64
LOGDIR (unset)
PATH=/home/user/perl5/perlbrew/bin:/opt/bin:/opt/gcc482inst/bin:/opt/gimp2.8/bin:/usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/user/bin
PERLBREW_BASHRC_VERSION=0.72
PERLBREW_HOME=/home/user/.perlbrew
PERLBREW_PATH=/home/user/perl5/perlbrew/bin
PERLBREW_ROOT=/home/user/perl5/perlbrew
PERLBREW_VERSION=0.72
PERL_BADLANG (unset)
SHELL=/bin/bash
Tony Cook via RT
2015-06-16 00:10:34 UTC
Permalink
Post by via RT
ExtUtils::ParseXS INCLUDE_COMMAND with $^X fails on "Perl in Space"
(ie when perl is installed in a location with a space). This patch
fixes.
- s/^\s*\$\^X/$^X/;
+ s/^\s*\$\^X/"$^X"/; # quotes in case has spaces

I suspect this should be more defensive and take platform differences into account, eg. see safe_quote() in CPAN::HandleConfig

Tony


---
via perlbug: queue: perl5 status: new
https://rt.perl.org/Ticket/Display.html?id=125411
etj@cpan.org via RT
2015-08-10 00:03:24 UTC
Permalink
Post by Tony Cook via RT
I suspect this should be more defensive and take platform differences
into account, eg. see safe_quote() in CPAN::HandleConfig
Quite right. Please find attached updated patch.

Best regards,
Ed

---
via perlbug: queue: perl5 status: open
https://rt.perl.org/Ticket/Display.html?id=125411
Tony Cook via RT
2015-08-10 01:44:52 UTC
Permalink
Post by ***@cpan.org via RT
Post by Tony Cook via RT
I suspect this should be more defensive and take platform differences
into account, eg. see safe_quote() in CPAN::HandleConfig
Quite right. Please find attached updated patch.
Thanks, applied as b06b5987d5b311d0ca777873ac239f01d6baf27c.

Tony

---
via perlbug: queue: perl5 status: open
https://rt.perl.org/Ticket/Display.html?id=125411
etj@cpan.org via RT
2015-08-10 07:54:23 UTC
Permalink
Thanks!

Any chance of a new CPAN release of ExtUtils::ParseXS? I see you bumped the $VERSION to 3.29, but the CPAN version is 3.24?

Best regards,
Ed
Steffen Mueller
2015-08-10 08:50:13 UTC
Permalink
Post by ***@cpan.org via RT
Any chance of a new CPAN release of ExtUtils::ParseXS? I see you
bumped the $VERSION to 3.29, but the CPAN version is 3.24?
Just did a dev release (3.29_01) since too much change has accumulated.

--Steffen

Loading...