AFS-PAG

 view release on metacpan or  search on metacpan

Build.PL  view on Meta::CPAN

#
# $build - The module build object, used to add additional libraries
#
# Returns: List of extra directories to add to the module build
#  Throws: Text exception if the module cannot be built in this environment
sub config_kafs {
    my ($build) = @_;
    my $config = Config::AutoConf->new;

    # Checks needed for the generic portability layer.
    $config->check_default_headers;
    if (!$config->check_header('stdbool.h')) {
        $config->check_type('_Bool');
    }
    $config->check_type('sig_atomic_t', undef, undef,
        include(qw(sys/types.h signal.h)));
    $config->check_type('ssize_t', undef, undef, include('sys/types.h'));

    # Checks needed by all libkafs code.
    $config->check_header('sys/ioccom.h');

README  view on Meta::CPAN


  AFS::PAG uses Module::Build and can be installed using the same process
  as any other Module::Build module:

      perl Build.PL
      ./Build
      ./Build test
      ./Build install

  If your libkafs or libkopenafs libraries are in a path that's not
  searched by your linker by default, pass them to Build.PL using the
  --extra-linker-flags option, as in:

      perl Build.PL --extra-linker-flags '-L/opt/openafs/lib'

  You will have to run the last command as root unless you're installing
  into a local Perl module tree in your home directory.

SUPPORT

  The AFS::PAG web page at:

lib/AFS/PAG.pm  view on Meta::CPAN

tokens.  Programs that need AFS tokens should normally obtain Kerberos
tickets (via whatever means) and then run the program B<aklog>, which
comes with most AFS distributions.  This program will create AFS tokens
from the current Kerberos ticket cache and store them in the current PAG.
To isolate those credentials from the rest of the system, call setpag()
before running B<aklog>.

=head1 FUNCTIONS

This module provides the following functions, none of which are exported
by default:

=over 4

=item hasafs()

Returns true if the local host is running an AFS client and false
otherwise.

=item haspag()

portable/kafs.h  view on Meta::CPAN


/* Default to a hidden visibility for all portability functions. */
#pragma GCC visibility push(hidden)

int k_hasafs(void);
int k_haspag(void);
int k_pioctl(char *, int, struct ViceIoctl *, int);
int k_setpag(void);
int k_unlog(void);

/* Undo default visibility change. */
#pragma GCC visibility pop

/* We have no kafs implementation available. */
#else
# undef HAVE_KAFS
# define k_hasafs()           (0)
# define k_haspag()           (0)
# define k_pioctl(p, c, a, f) (errno = ENOSYS, -1)
# define k_setpag()           (errno = ENOSYS, -1)
# define k_unlog()            (errno = ENOSYS, -1)

t/data/perlcriticrc  view on Meta::CPAN

[-Documentation::RequirePodLinksIncludeText]

# The POD sections Perl::Critic wants are incompatible with the POD template
# from perlpodstyle, which is what I use for my POD documentation.
[-Documentation::RequirePodSections]

# This problem was fixed in Perl 5.14, which now properly preserves the value
# of $@ even if destructors run at exit from the eval block.
[-ErrorHandling::RequireCheckingReturnValueOfEval]

# The default of 9 is too small and forces weird code contortions.
[InputOutput::RequireBriefOpen]
lines = 25

# This is correct 80% of the time, but it isn't correct for a lot of scripts
# inside packages, where maintaining $VERSION isn't worth the effort.
# Unfortunately, there's no way to override it, so it gets turned off
# globally.
[-Modules::RequireVersionVar]

# This sounds interesting but is actually useless.  Any large blocks of

t/docs/synopsis.t  view on Meta::CPAN

use Test::More;
use Test::RRA qw(skip_unless_automated use_prereq);

# Skip for normal user installs since this doesn't affect functionality.
skip_unless_automated('Synopsis syntax tests');

# Load prerequisite modules.
use_prereq('Perl::Critic::Utils');
use_prereq('Test::Synopsis');

# The default Test::Synopsis all_synopsis_ok() function requires that the
# module be in a lib directory.  Use Perl::Critic::Utils to find the modules
# in blib, or lib if it doesn't exist.  However, strip out anything in
# blib/script, since scripts use a different SYNOPSIS syntax.
my @files = Perl::Critic::Utils::all_perl_files('blib');
@files = grep { !m{blib/script/}xms } @files;
if (!@files) {
    @files = Perl::Critic::Utils::all_perl_files('lib');
}
plan tests => scalar @files;

t/lib/Test/RRA.pm  view on Meta::CPAN


=head1 DESCRIPTION

This module collects utility functions that are useful for Perl test
scripts.  It assumes Russ Allbery's Perl module layout and test
conventions and will only be useful for other people if they use the
same conventions.

=head1 FUNCTIONS

None of these functions are imported by default.  The ones used by a
script should be explicitly imported.

=over 4

=item skip_unless_author(DESC)

Checks whether AUTHOR_TESTING is set in the environment and skips the
whole test (by calling C<plan skip_all> from Test::More) if it is not.
DESC is a description of the tests being skipped.  A space and C<only run
for author> will be appended to it and used as the skip reason.

t/lib/Test/RRA/Config.pm  view on Meta::CPAN

    my $path = "$base/data/perl.conf";
    if (-r $path) {
        $PATH = $path;
        last;
    }
}
if (!defined($PATH)) {
    BAIL_OUT('cannot find data/perl.conf');
}

# Pre-declare all of our variables and set any defaults.
our $COVERAGE_LEVEL = 100;
our @COVERAGE_SKIP_TESTS;
our @CRITIC_IGNORE;
our $LIBRARY_PATH;
our $MINIMUM_VERSION = '5.008';
our %MINIMUM_VERSION;
our @POD_COVERAGE_EXCLUDE;
our @STRICT_IGNORE;
our @STRICT_PREREQ;

t/lib/Test/RRA/Config.pm  view on Meta::CPAN

Perl modules.

The following variables are supported:

=over 4

=item $COVERAGE_LEVEL

The coverage level achieved by the test suite for Perl test coverage
testing using Test::Strict, as a percentage.  The test will fail if test
coverage less than this percentage is achieved.  If not given, defaults
to 100.

=item @COVERAGE_SKIP_TESTS

Directories under F<t> whose tests should be skipped when doing coverage
testing.  This can be tests that won't contribute to coverage or tests
that don't run properly under Devel::Cover for some reason (such as ones
that use taint checking).  F<docs> and F<style> will always be skipped
regardless of this setting.

t/lib/Test/RRA/Config.pm  view on Meta::CPAN

=item $LIBRARY_PATH

Add this directory (or a F<.libs> subdirectory) relative to the top of the
source tree to LD_LIBRARY_PATH when checking the syntax of Perl modules.
This may be required to pick up libraries that are used by in-tree Perl
modules so that Perl scripts can pass a syntax check.

=item $MINIMUM_VERSION

Default minimum version requirement for included Perl scripts.  If not
given, defaults to 5.008.

=item %MINIMUM_VERSION

Minimum version exceptions for specific directories.  The keys should be
minimum versions of Perl to enforce.  The value for each key should be a
reference to an array of either top-level directory names or directory
names starting with F<tests/>.  All files in those directories will have
that minimum Perl version constraint imposed instead of $MINIMUM_VERSION.

=item @POD_COVERAGE_EXCLUDE

t/lib/Test/RRA/Config.pm  view on Meta::CPAN


=item @STRICT_PREREQ

A list of Perl modules that have to be available in order to do meaningful
Test::Strict testing.  If any of the modules cannot be loaded via C<use>,
Test::Strict checking will be skipped.  There is currently no way to
require specific versions of the modules.

=back

No variables are exported by default, but the variables can be imported
into the local namespace to avoid long variable names.

=head1 AUTHOR

Russ Allbery <eagle@eyrie.org>

=head1 COPYRIGHT AND LICENSE

Copyright 2013, 2014 The Board of Trustees of the Leland Stanford Junior
University

t/style/critic.t  view on Meta::CPAN

# Load prerequisite modules.
use_prereq('Perl::Critic::Utils');
use_prereq('Test::Perl::Critic');

# Force the embedded Perl::Tidy check to use the correct configuration.
local $ENV{PERLTIDY} = 't/data/perltidyrc';

# Import the configuration file and run Perl::Critic.
Test::Perl::Critic->import(-profile => 't/data/perlcriticrc');

# By default, Test::Perl::Critic only checks blib.  We also want to check t,
# Build.PL, and examples.
my @files = Perl::Critic::Utils::all_perl_files('blib');
if (!@files) {
    @files = Perl::Critic::Utils::all_perl_files('lib');
}
if (-f 'Build.PL') {
    push(@files, 'Build.PL');
}
for my $dir (qw(examples usr t)) {
    if (-d $dir) {



( run in 0.356 second using v1.01-cache-2.11-cpan-0a6323c29d9 )