File: MyFilelists.pm

package info (click to toggle)
grid-packaging-tools 3.6.2-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 1,936 kB
  • sloc: perl: 15,766; sh: 3,032; makefile: 225
file content (156 lines) | stat: -rw-r--r-- 3,863 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
package Grid::GPT::MyFilelists;
use strict;
use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);

require Exporter;
require AutoLoader;
use Data::Dumper;
use Grid::GPT::FilelistSort;
use strict;

@ISA = qw(Exporter AutoLoader);
# Items to export into callers namespace by default. Note: do not export
# names by default without a very good reason. Use EXPORT_OK instead.
# Do not simply export all your public functions/methods/constants.
@EXPORT = qw(
);
$VERSION = '0.01';


# Preloaded methods go here.
sub new {
  my ($class, %arg) = @_;
  my $me = {
            filelist => new Grid::GPT::FilelistSort((%arg)),
            mangling => $arg{'mangling'},
          };
  bless $me, $class;
  return $me;
}

sub pgm_files {
  my $me = shift;
  my $result = [];
  $me->{'filelist'}->extract_programs();
  $me->{'filelist'}->add_package_metadata_files('pgm');
  my $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();
  $me->{'filelist'}->extract_setup_files();
  $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();
  return $result;
}

sub pgm_static_files {
  my $me = shift;
  my $result = [];
  $me->{'filelist'}->extract_programs();
  $me->{'filelist'}->add_package_metadata_files('pgm_static');
  my $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();
  $me->{'filelist'}->extract_setup_files();
  $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();
  return $result;
}

sub rtl_files {
  my $me = shift;
  my $result = [];
  $me->{'filelist'}->flavored_files() if defined $me->{'mangling'};
  $me->{'filelist'}->extract_dynamic_libs();
  $me->{'filelist'}->add_package_metadata_files('rtl');
  my $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();

  $me->{'filelist'}->extract_perl_modules();
  $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();
  return $result;
}

sub dev_files {
  my $me = shift;
  my $result = [];

  $me->{'filelist'}->flavored_files() if defined $me->{'mangling'};
  $me->{'filelist'}->extract_static_libs();
  my $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();

  $me->{'filelist'}->flavored_files() if defined $me->{'mangling'};
  $me->{'filelist'}->extract_libtool_libs();
  $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();

  $me->{'filelist'}->flavored_headers();
  $me->{'filelist'}->add_package_metadata_files('dev');
  $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();

  $me->{'filelist'}->noflavor_headers();
  $list = $me->{'filelist'}->get_list();
  push @$result, @$list;
  $me->{'filelist'}->reset();
  return $result;
}

sub data_files {
  my $me = shift;
  $me->{'filelist'}->extract_data();
  $me->{'filelist'}->add_package_metadata_files('data', 'noflavor');
  my $list = $me->{'filelist'}->get_list();
  $me->{'filelist'}->reset();
  return $list;
}

sub doc_files {
  my $me = shift;
  $me->{'filelist'}->extract_docs();
  $me->{'filelist'}->add_package_metadata_files('doc', 'noflavor');
  my $list = $me->{'filelist'}->get_list();
  $me->{'filelist'}->reset();
  return $list;
}

# Autoload methods go after =cut, and are processed by the autosplit program.

1;
__END__
# Below is the stub of documentation for your module. You better edit it!

=head1 NAME

Filelist - Perl extension for blah blah blah

=head1 SYNOPSIS

  use Filelist;
  blah blah blah

=head1 DESCRIPTION

Stub documentation for Filelist was created by h2xs. It looks like the
author of the extension was negligent enough to leave the stub
unedited.

Blah blah blah.

=head1 AUTHOR

A. U. Thor, a.u.thor@a.galaxy.far.far.away

=head1 SEE ALSO

perl(1).

=cut