]> git.pld-linux.org Git - packages/perl-File-ShareDir.git/blob - perl-File-ShareDir.spec
- up to 1.104
[packages/perl-File-ShareDir.git] / perl-File-ShareDir.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # do not perform "make test"
4 #
5 %include        /usr/lib/rpm/macros.perl
6 %define pdir    File
7 %define pnam    ShareDir
8 Summary:        File::ShareDir - Locate per-dist and per-module shared files
9 Summary(pl.UTF-8):      File::ShareDir - położenie plików współdzielonych w dystrybucji i module
10 Name:           perl-File-ShareDir
11 Version:        1.104
12 Release:        1
13 # same as perl
14 License:        GPL v1+ or Artistic
15 Group:          Development/Languages/Perl
16 Source0:        http://www.cpan.org/modules/by-module/File/%{pdir}-%{pnam}-%{version}.tar.gz
17 # Source0-md5:  e921ec8d0a373690b5da9e03a548c223
18 URL:            http://search.cpan.org/dist/File-ShareDir/
19 BuildRequires:  perl-devel >= 1:5.8.0
20 BuildRequires:  rpm-perlprov >= 4.1-13
21 %if %{with tests}
22 BuildRequires:  perl-Class-Inspector >= 1.12
23 BuildRequires:  perl-Params-Util >= 0.07
24 %endif
25 BuildArch:      noarch
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 The intent of File::ShareDir is to provide a companion to
30 Class::Inspector and File::HomeDir, modules that take a process that
31 is well-known by advanced Perl developers but gets a little tricky,
32 and make it more available to the larger Perl community.
33
34 Quite often you want or need your Perl module (CPAN or otherwise) to
35 have access to a large amount of read-only data that is stored on the
36 file-system at run-time.
37
38 On a Linux-like system, this would be in a place such as /usr/share,
39 however Perl runs on a wide variety of different systems, and so the
40 use of any one location is unreliable.
41
42 Perl provides a little-known method for doing this, but almost nobody
43 is aware that it exists. As a result, module authors often go through
44 some very strange ways to make the data available to their code.
45
46 %description -l pl.UTF-8
47 Celem File::ShareDir jest zapewnienie modułu towarzyszącego modułom
48 Class::Inspector oraz File::HomeDir (wykonujących zadania dobrze znane
49 zaawansowanym programistom Perla, ale wymagających sztuczek), będącego
50 bardziej przystępnym dla społeczności Perla.
51
52 Często istnieje potrzeba, aby moduł Perla (z CPAN lub innego źródła)
53 miał dostęp do dużych ilości danych tylko do odczytu, przechowywanych
54 w systemie plików.
55
56 Na systemach linuksowych takie dane zwykle znajdują się miejscu typu
57 /usr/share, ale Perla działa na wielu różnych systemach i użycie
58 jednego miejsca nie jest wiarygodne.
59
60 Perl udostępnia w takim celu mało znaną metodę, ale mało kto o niej
61 wie. W efekcie autorzy modułów w różny dziwny sposób sprawiają, by ich
62 dane były dostępne dla kodu.
63
64 %prep
65 %setup -q -n %{pdir}-%{pnam}-%{version}
66
67 %build
68 %{__perl} Makefile.PL \
69         INSTALLDIRS=vendor
70 %{__make}
71
72 %{?with_tests:%{__make} test}
73
74 %install
75 rm -rf $RPM_BUILD_ROOT
76 install -d $RPM_BUILD_ROOT%{perl_vendorlib}/auto/share/{dist,module}
77
78 %{__make} pure_install \
79         DESTDIR=$RPM_BUILD_ROOT
80
81 %clean
82 rm -rf $RPM_BUILD_ROOT
83
84 %files
85 %defattr(644,root,root,755)
86 %doc Changes
87 %{perl_vendorlib}/File/ShareDir.pm
88 %dir %{perl_vendorlib}/auto/share
89 %dir %{perl_vendorlib}/auto/share/dist
90 %dir %{perl_vendorlib}/auto/share/module
91 %{_mandir}/man3/File::ShareDir.3pm*
This page took 0.074801 seconds and 3 git commands to generate.