Alien-CSFML
view release on metacpan or search on metacpan
# Methods
After creating a new [Alien::CSFML](https://metacpan.org/pod/Alien%3A%3ACSFML) object, use the following
methods to gather information:
## `include_dirs`
my @include_dirs = $AS->include_dirs( );
Returns a list of the locations of the headers installed during the build
process and those required for compilation.
## `library_path`
my $lib_path = $AS->library_path( );
Returns the location of the private libraries we made and installed during the
build process.
## `cflags`
my $cflags = $AS->cflags( );
Returns additional C compiler flags to be used.
## `cxxflags`
my $cxxflags = $AS->cxxflags( );
inc/MBCSFML.pm view on Meta::CPAN
my ( $input_file, $output_file, $section, $opts ) = @_;
return if -e $output_file && -M $input_file <= -M $output_file;
my $dirname = dirname($output_file);
mkpath( $dirname, $opts->{verbose} ) if not -d $dirname;
require Pod::Man;
Pod::Man->new( section => $section )->parse_from_file( $input_file, $output_file );
print "Manifying $output_file\n" if $opts->{verbose} && $opts->{verbose} > 0;
return;
}
sub process_xs {
my ( $source, $options ) = @_;
die "Can't build xs files under --pureperl-only\n" if $options->{'pureperl-only'};
my ( undef, @dirnames ) = splitdir( dirname($source) );
my $file_base = basename( $source, '.xs' );
my $archdir = catdir( qw/blib arch auto/, @dirnames, $file_base );
my $c_file = catfile( 'lib', @dirnames, "$file_base.c" );
require ExtUtils::ParseXS;
ExtUtils::ParseXS::process_file( filename => $source, prototypes => 0, output => $c_file );
my $version = $options->{meta}->version;
require ExtUtils::CBuilder;
my $builder = ExtUtils::CBuilder->new( config => $options->{config}->values_set );
my $ob_file = $builder->compile(
source => $c_file,
defines => { VERSION => qq/"$version"/, XS_VERSION => qq/"$version"/ }
);
mkpath( $archdir, $options->{verbose}, oct '755' ) unless -d $archdir;
return $builder->link(
objects => $ob_file,
inc/MBCSFML.pm view on Meta::CPAN
system $^X, $_ and die "$_ returned $?\n" for find( qr/\.PL$/, 'lib' );
my %modules = map { $_ => catfile( 'blib', $_ ) } find( qr/\.p(?:m|od)$/, 'lib' );
my %scripts = map { $_ => catfile( 'blib', $_ ) } find( qr//, 'script' );
build_libs( \%opt );
my %shared = map {
$_ => catfile( qw/blib lib auto share dist/, $opt{meta}->name, abs2rel( $_, 'share' ) )
} find( qr//, 'share' );
pm_to_blib( { %modules, %scripts, %shared }, catdir(qw/blib lib auto/) );
make_executable($_) for values %scripts;
mkpath( catdir(qw/blib arch/), $opt{verbose} );
process_xs( $_, \%opt ) for find( qr/.xs$/, 'lib' );
if ( $opt{install_paths}->install_destination('libdoc') &&
$opt{install_paths}->is_default_installable('libdoc') ) {
manify(
$_,
catfile( 'blib', 'bindoc', man1_pagename($_) ),
$opt{config}->get('man1ext'), \%opt
) for keys %scripts;
manify(
$_,
catfile( 'blib', 'libdoc', man3_pagename($_) ),
lib/Alien/CSFML.pm view on Meta::CPAN
=head1 Methods
After creating a new L<Alien::CSFML|Alien::CSFML> object, use the following
methods to gather information:
=head2 C<include_dirs>
my @include_dirs = $AS->include_dirs( );
Returns a list of the locations of the headers installed during the build
process and those required for compilation.
=head2 C<library_path>
my $lib_path = $AS->library_path( );
Returns the location of the private libraries we made and installed during the
build process.
=head2 C<cflags>
my $cflags = $AS->cflags( );
Returns additional C compiler flags to be used.
=head2 C<cxxflags>
my $cxxflags = $AS->cxxflags( );
( run in 0.292 second using v1.01-cache-2.11-cpan-8d75d55dd25 )