Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the ExtUtils-ParseXS CPAN distribution.

Report information
The Basics
Id: 61908
Status: open
Priority: 0/
Queue: ExtUtils-ParseXS

People
Owner: Nobody in particular
Requestors: mdootson [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 2.2206
Fixed in: (no value)



Subject: MSWin compilers and back-slashed paths
gcc compilers on windows don't like backslashed paths in directives - e.g. TreeListCtrl.c:1278:11: warning: unknown escape sequence '\T' attached patch against 2.2206 fixes for gcc / MSWin without affecting any other OS
Subject: ExtUtils-ParseXS.patch
diff -ruNw ExtUtils-ParseXS-2.2206/lib/ExtUtils/ParseXS.pm ExtUtils-ParseXS-working/lib/ExtUtils/ParseXS.pm --- lib/ExtUtils/ParseXS.pm 2010-07-04 20:52:38.000000000 +0100 +++ lib/ExtUtils/ParseXS.pm 2010-10-05 16:47:54.286400000 +0100 @@ -1548,3 +1548,3 @@ $filename = $_ ; - $filepathname = File::Spec->catfile($dir, $filename); + $filepathname = ( $^O =~ /^mswin/i ) ? qq($dir/$filename) : File::Spec->catfile($dir, $filename);
I'll be bold and resolve this ticket after applying the patch. It'll be in an upcoming 3.00_04 release. Best regards, Steffen
I am sorry for reopening this ticket but I think that the patch is not fully correct.

The trouble is that the patch hack for MSWin32:
qq($dir/$filename)
assumes that $dir does not contain backslashes which is not always true.

Please consider applying enclosed improved patch.

--
kmx
Subject: improved-patch.diff
--- ParseXS.pm.orig Wed Oct 05 09:15:16 2011 +++ ParseXS.pm Fri Aug 03 23:26:25 2012 @@ -1541,9 +1541,8 @@ EOF $self->{filename} = $_; - $self->{filepathname} = ( $^O =~ /^mswin/i ) - ? qq($self->{dir}/$self->{filename}) # See CPAN RT #61908: gcc doesn't like backslashes on win32? - : File::Spec->catfile($self->{dir}, $self->{filename}); + $self->{filepathname} = File::Spec->catfile($self->{dir}, $self->{filename}); + $self->{filepathname} =~ s/\\/\\\\/g if $^O eq 'MSWin32'; # See CPAN RT #61908 # Prime the pump by reading the first # non-blank line