]> git.pld-linux.org Git - packages/perl-File-FcntlLock.git/blob - perl-File-FcntlLock.spec
- rebuild with perl 5.18.0
[packages/perl-File-FcntlLock.git] / perl-File-FcntlLock.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # do not perform "make test"
4 #
5 %define         pdir    File
6 %define         pnam    FcntlLock
7 %include        /usr/lib/rpm/macros.perl
8 Summary:        File::FcntlLock - File locking with fcntl(2)
9 #Summary(pl.UTF-8):     
10 Name:           perl-File-FcntlLock
11 Version:        0.14
12 Release:        2
13 License:        unknown
14 Group:          Development/Languages/Perl
15 Source0:        http://www.cpan.org/modules/by-module/File/%{pdir}-%{pnam}-%{version}.tar.gz
16 # Source0-md5:  261aa44a9806181ae8fdf49bead7f828
17 # generic URL, check or change before uncommenting
18 #URL:           http://search.cpan.org/dist/File-FcntlLock/
19 BuildRequires:  perl-devel >= 1:5.8.0
20 BuildRequires:  rpm-perlprov >= 4.1-13
21 %if %{with tests}
22 %endif
23 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25 %description
26 File locking in Perl is usually done using the flock() function.
27 Unfortunately, this only allows locks on whole files and is often
28 implemented in terms of flock(2), which has some shortcomings.
29
30 Using this module file locking via fcntl(2) can be done (obviously,
31 this restricts the use of the module to systems that have a fcntl(2)
32 system call). Before a file (or parts of a file) can be locked, an
33 object simulating a flock structure must be created and its properties
34 set. Afterwards, by calling the lock() method a lock can be set or it
35 can be determined if and which process currently holds the lock.
36
37 To create a new object representing a flock structure call new():
38
39   $fs = new File::FcntlLock;
40
41 You also can pass the new() method a set of key-value pairs to
42 initialize the objects properties, e.g. use
43
44 # %description -l pl.UTF-8
45 # TODO
46
47 %prep
48 %setup -q -n %{pdir}-%{pnam}-%{version}
49
50 %build
51 %{__perl} Makefile.PL \
52         INSTALLDIRS=vendor
53 %{__make} \
54         CC="%{__cc}" \
55         OPTIMIZE="%{rpmcflags}"
56
57 %{?with_tests:%{__make} test}
58
59 %install
60 rm -rf $RPM_BUILD_ROOT
61
62 %{__make} pure_install \
63         DESTDIR=$RPM_BUILD_ROOT
64
65 %clean
66 rm -rf $RPM_BUILD_ROOT
67
68 %files
69 %defattr(644,root,root,755)
70 %doc Changes README
71 %{perl_vendorarch}/File/*.pm
72 %dir %{perl_vendorarch}/auto/File/FcntlLock
73 %{perl_vendorarch}/auto/File/FcntlLock/*.bs
74 %attr(755,root,root) %{perl_vendorarch}/auto/File/FcntlLock/*.so
75 %{_mandir}/man3/*
This page took 0.104763 seconds and 4 git commands to generate.