ports/textproc/p5-XML-LibXML/patches/patch-Makefile_PL

44 lines
1.2 KiB
Text

Alien::Build has been designed to build dependencies on the fly
when installing from CPAN. That does not make sense for our ports
tree. Remove Alien::Libxml2 references, instead link against the
library from our libxml-2 package.
Index: Makefile.PL
--- Makefile.PL.orig
+++ Makefile.PL
@@ -17,15 +17,12 @@ use warnings;
require 5.008001;
-use Alien::Base::Wrapper qw( Alien::Libxml2 );
use ExtUtils::MakeMaker;
use Config;
my $SKIP_SAX_INSTALL = $ENV{SKIP_SAX_INSTALL};
my %ConfigReqs = (
- "Alien::Libxml2" => '0.14',
- "Alien::Base::Wrapper" => 0,
"Config" => 0,
"ExtUtils::MakeMaker" => 0,
);
@@ -68,15 +65,13 @@ my %prereqs = (
"warnings" => 0,
);
-my %xsbuild_concat = (
+my %xsbuild = (
DEFINE => '-DHAVE_UTF8',
OBJECT => '$(O_FILES)',
+ CCFLAGS => $Config{ccflags} .
+ ' -I${LOCALBASE}/include -I${LOCALBASE}/include/libxml2',
+ LIBS => '-L${LOCALBASE}/lib -lxml2',
);
-my %xsbuild = Alien::Base::Wrapper->mm_args; # Might contain a definition of DEFINE, must thus concatenate.
-while (my ($k, $v) = each %xsbuild_concat) {
- my $base_val = $xsbuild{$k};
- $xsbuild{$k} = (defined($base_val) ? ($base_val . ' ' . $v) : $v);
-}
my %WriteMakefileArgs = (
"NAME" => "XML::LibXML",