Alien-uPB-Core
view release on metacpan or search on metacpan
inc/AU/Build.pm view on Meta::CPAN
my $commit = '3e4cd724ea7ac538723a2044878e7af40481fa4b';
sub new {
my $class = shift;
my $protobuf_flags = Alien::ProtoBuf->cflags;
my $protobuf_cxxflags = Alien::ProtoBuf->cxxflags;
my $make_args = '';
if ($^O eq 'freebsd') {
$make_args = 'CXX=c++';
}
my $self = $class->SUPER::new(
@_,
alien_name => 'uPB::Core', # to stop Alien::Base warnings
alien_bin_requires => {
'Alien::gmake' => 0.11, # needed for %{gmake} helper
},
alien_build_commands => [
"CFLAGS='$protobuf_flags -fPIC' cmake .",
"%{gmake} $make_args",
],
alien_install_commands => [
inc/AU/Build.pm view on Meta::CPAN
);
die "It seems something went wrong while building uPB"
unless $version;
return $version;
}
sub alien_generate_manual_pkgconfig {
my $self = shift;
my $config = $self->SUPER::alien_generate_manual_pkgconfig(@_);
# -DNDEBUG works around https://github.com/google/upb/issues/63
$config->{keywords}{Cflags} = '-I${pcfiledir}/include -DNDEBUG';
$config->{keywords}{Libs} =
'-L${pcfiledir}/lib ' .
join " ", map "-l$_", qw(
upb_descriptor upb_json upb_pb upb
);
return $config;
( run in 1.822 second using v1.01-cache-2.11-cpan-49f99fa48dc )