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 2014/04/27 01:12:03 UTC
[lucy-commits] [33/54] [abbrv] git commit: refs/heads/sortex_ptr_only - Remove
dependency of Clownfish::CFC::Perl::Build on Charmonizer
Remove dependency of Clownfish::CFC::Perl::Build on Charmonizer
Add a new field 'cflags' to the 'clownfish_params' Module::Build
property to pass additional compiler flags.
Project: http://git-wip-us.apache.org/repos/asf/lucy/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy/commit/f24561ff
Tree: http://git-wip-us.apache.org/repos/asf/lucy/tree/f24561ff
Diff: http://git-wip-us.apache.org/repos/asf/lucy/diff/f24561ff
Branch: refs/heads/sortex_ptr_only
Commit: f24561ff4624c5563add8fb77a3e5206392bd293
Parents: 340d691
Author: Nick Wellnhofer <we...@aevum.de>
Authored: Sun Jul 21 00:00:30 2013 +0200
Committer: Nick Wellnhofer <we...@aevum.de>
Committed: Tue Apr 22 23:05:37 2014 +0200
----------------------------------------------------------------------
perl/buildlib/Lucy/Build.pm | 22 ++++++++++++++++++----
1 file changed, 18 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucy/blob/f24561ff/perl/buildlib/Lucy/Build.pm
----------------------------------------------------------------------
diff --git a/perl/buildlib/Lucy/Build.pm b/perl/buildlib/Lucy/Build.pm
index 1118474..ebfabb5 100644
--- a/perl/buildlib/Lucy/Build.pm
+++ b/perl/buildlib/Lucy/Build.pm
@@ -17,7 +17,10 @@ use strict;
use warnings;
package Lucy::Build;
-use base qw( Clownfish::CFC::Perl::Build );
+use base qw(
+ Clownfish::CFC::Perl::Build
+ Clownfish::CFC::Perl::Build::Charmonic
+);
our $VERSION = '0.003000';
$VERSION = eval $VERSION;
@@ -85,8 +88,6 @@ sub ACTION_lemon {
sub ACTION_copy_clownfish_includes {
my $self = shift;
- $self->depends_on('charmony');
-
$self->SUPER::ACTION_copy_clownfish_includes;
$self->cf_copy_include_file( qw( Lucy Util ToolSet.h ) );
@@ -233,7 +234,20 @@ sub ACTION_parsers {
sub ACTION_compile_custom_xs {
my $self = shift;
- $self->depends_on('parsers');
+ $self->depends_on(qw( parsers charmony ));
+
+ # Add extra compiler flags from Charmonizer.
+ my $charm_cflags = $self->charmony('EXTRA_CFLAGS');
+ if ($charm_cflags) {
+ my $cf_cflags = $self->clownfish_params('cflags');
+ if ($cf_cflags) {
+ $cf_cflags .= " $charm_cflags";
+ }
+ else {
+ $cf_cflags = $charm_cflags;
+ }
+ $self->clownfish_params( cflags => $cf_cflags );
+ }
$self->SUPER::ACTION_compile_custom_xs;
}