Alien::Role::Alt - (Deprecated) Alien::Base role that supports alternates
version 0.05
From your alienfile
use alienfile; plugin 'PkgConfig' => ( pkg_name => [ 'libfoo', 'libbar', ], );
Then in your base class:
package Alien::Libfoo; use base qw( Alien::Base ); use Role::Tiny::With qw( with ); with 'Alien::Role::Alt'; 1;
Then you can use it:
use Alien::Libfoo; my $cflags = Alien::Libfoo->alt('foo1')->cflags; my $libs = Alien::Libfoo->alt('foo1')->libs;
NOTE: The capabilities that used to be provided by this role have been moved into Alien::Base's core class. This is an empty role provided for compatibility only. New code should not be using this class.
Some packages come with multiple libraries, and multiple .pc files to use with them. This Role::Tiny role can be used with Alien::Base to access different configurations.
.pc
my $new_alien = $old_alien->alt($alt_name);
Returns an Alien::Base instance with the alternate configuration.
Graham Ollis <plicease@cpan.org>
This software is copyright (c) 2017,2018,2019 by Graham Ollis.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Alien::Role::Alt, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Alien::Role::Alt
CPAN shell
perl -MCPAN -e shell install Alien::Role::Alt
For more information on module installation, please visit the detailed CPAN module installation guide.