perl-Thread-Queue/perl-Thread-Queue.spec

70 lines
1.9 KiB
RPMSpec
Raw Normal View History

2019-09-30 11:13:29 -04:00
Name: perl-Thread-Queue
Version: 3.13
Release: 3
Summary: Thread-safe queues
License: GPL+ or Artistic
URL: https://metacpan.org/release/Thread-Queue
Source0: https://cpan.metacpan.org/authors/id/J/JD/JDHEDDEN/Thread-Queue-%{version}.tar.gz
BuildArch: noarch
BuildRequires: make sed perl-generators perl-interpreter
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76 perl(Test::More) >= 0.50
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
Requires: perl(Carp)
%description
This module provides thread-safe FIFO queues that can be accessed safely by
any number of threads.
Any data types supported by threads::shared can be passed via queues:
-Ordinary scalars
-Array refs
-Hash refs
-Scalar refs
-Objects based on the above
Ordinary scalars are added to queues as they are.
If not already thread-shared, the other complex data types will be cloned
(recursively, if needed, and including any blessings and read-only settings)
into thread-shared structures before being placed onto a queue.
%package help
Summary: Doc files for %{name}
Buildarch: noarch
requires: man
%description help
The %{name}-help package contains doc files for %{name}.
%prep
%autosetup -n Thread-Queue-%{version}
sed -i -e '1 s|^#!/usr/bin/env perl|%(perl -MConfig -e 'print $Config{startperl}')|' examples/queue.pl
%build
perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1
%make_build
%install
make pure_install DESTDIR=%{buildroot}
%{_fixperms} %{buildroot}/*
%check
make test
%files
%doc README
%{perl_vendorlib}/*
%files help
%doc Changes examples
%{_mandir}/man3/*
%changelog
* Tue Sep 27 2019 luhuaxin <luhuaxin@huawei.com> - 3.13-3
- Type: enhancement
- ID: NA
- SUG: NA
- DESC: move README file to main package
* Mon Sep 16 2019 luhuaxin <luhuaxin@huawei.com> - 3.13-2
- Package init