Skip Menu |

This queue is for tickets about the XML-LibXML CPAN distribution.

Report information
The Basics
Id: 80167
Status: resolved
Priority: 0/
Queue: XML-LibXML

People
Owner: Nobody in particular
Requestors: VOVKASM [...] cpan.org
Cc: vovkasm [...] gmail.com
AdminCc:

Bug Information
Severity: Critical
Broken in: 2.0005
Fixed in: (no value)



CC: vovkasm [...] gmail.com
Subject: [patch] fix configure error
When xml2-config returns many paths (ex. "-I/usr/local/include/libxml2 - I/usr/local/include" on FreeBSD), configure fails. Because: $incpath = "-I/usr/local/include/libxml2 -I/usr/local/include"; $incpath =~ s#(\b|\A)-I##g; now $incpath is "/usr/local/include/libxml2 -I/usr/local/include" correct regexp would be s#(\A|\s)-I#$1#g; Plus in that case we need pass array to check_lib_or_exit (according to Devel::CheckLib docs...) Attached patch fixes that.
Subject: xml-libxml-2.0005-fix-multi-incpaths.patch
diff --git a/Makefile.PL b/Makefile.PL index 764e80e..3106bbc 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -357,12 +357,12 @@ if ($ldflags) { } my $incpath = $config{INC}; -$incpath =~ s#(\b|\A)-I##g; +$incpath =~ s#(\A|\s)\s*-I#$1#g; check_lib_or_exit( # fill in what you prompted the user for here lib => [qw(xml2)], - incpath => $incpath, + incpath => [split(/\s/,$incpath)], header => [ 'libxml/c14n.h',
Thanks for the report and the patch. I applied it and released XML-LibXML-2.0006.tar.gz . Regards, -- Shlomi Fish