You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucy.apache.org by ma...@apache.org on 2009/09/15 19:38:54 UTC
svn commit: r815410 - in /lucene/lucy/trunk/perl: Build.PL
buildlib/Lucy/Build.pm
Author: marvin
Date: Tue Sep 15 17:38:53 2009
New Revision: 815410
URL: http://svn.apache.org/viewvc?rev=815410&view=rev
Log:
LUCY-40 -- Add Devel::PPPort as a build_requires element and generate ppport.h
on the fly.
Modified:
lucene/lucy/trunk/perl/Build.PL
lucene/lucy/trunk/perl/buildlib/Lucy/Build.pm
Modified: lucene/lucy/trunk/perl/Build.PL
URL: http://svn.apache.org/viewvc/lucene/lucy/trunk/perl/Build.PL?rev=815410&r1=815409&r2=815410&view=diff
==============================================================================
--- lucene/lucy/trunk/perl/Build.PL (original)
+++ lucene/lucy/trunk/perl/Build.PL Tue Sep 15 17:38:53 2009
@@ -30,6 +30,7 @@
build_requres => {
'ExtUtils::CBuilder' => 0.18,
'ExtUtils::ParseXS' => 2.16,
+ 'Devel::PPPort' => 3.13,
},
add_to_cleanup => [
'Lucy-*', 'typemap', 'MANIFEST.bak', 'lastmod',
Modified: lucene/lucy/trunk/perl/buildlib/Lucy/Build.pm
URL: http://svn.apache.org/viewvc/lucene/lucy/trunk/perl/buildlib/Lucy/Build.pm?rev=815410&r1=815409&r2=815410&view=diff
==============================================================================
--- lucene/lucy/trunk/perl/buildlib/Lucy/Build.pm (original)
+++ lucene/lucy/trunk/perl/buildlib/Lucy/Build.pm Tue Sep 15 17:38:53 2009
@@ -331,11 +331,27 @@
}
}
+# Write ppport.h, which supplies some XS routines not found in older Perls and
+# allows us to use more up-to-date XS API while still supporting Perls back to
+# 5.8.3.
+#
+# TODO: Devel::PPPort recommends that we distribute ppport.h rather than
+# require Devel::PPPort itself, but at this point further investigation is
+# required as to whether that's possible under the Apache license.
+sub ACTION_ppport {
+ my $self = shift;
+ require Devel::PPPort;
+ $self->add_to_cleanup('ppport.h');
+ Devel::PPPort::WriteFile();
+}
+
sub ACTION_compile_custom_xs {
my $self = shift;
my $project_name = $self->project_name;
my $xs_filepath = $self->xs_filepath;
+ $self->dispatch('ppport');
+
require ExtUtils::ParseXS;
my $cbuilder = Lucy::Build::CBuilder->new;