3 %bcond_without tests # do not perform "make test"
6 Summary: threads - Perl interpreter-based threads
11 License: GPL v1+ or Artistic
12 Group: Development/Languages/Perl
13 Source0: http://www.cpan.org/modules/by-authors/id/J/JD/JDHEDDEN/threads-%{version}.tar.gz
14 # Source0-md5: 45fa009703074f0b0b0d036cb23706e3
15 URL: http://search.cpan.org/dist/threads/
16 BuildRequires: perl-devel >= 1:5.8.0
17 BuildRequires: rpm-perlprov >= 4.1-13
18 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21 Since Perl 5.8, thread programming has been available using a model
22 called interpreter threads which provides a new Perl interpreter for
23 each thread, and, by default, results in no data or state information
24 being shared between threads.
27 %setup -q -n %{pdir}-%{version}
30 %{__perl} Makefile.PL \
34 OPTIMIZE="%{rpmcflags}"
36 %{?with_tests:%{__make} test}
39 rm -rf $RPM_BUILD_ROOT
41 %{__make} pure_install \
42 DESTDIR=$RPM_BUILD_ROOT
44 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
45 cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
48 rm -rf $RPM_BUILD_ROOT
51 %defattr(644,root,root,755)
53 %{perl_vendorarch}/threads.pm
54 %dir %{perl_vendorarch}/auto/threads
55 %attr(755,root,root) %{perl_vendorarch}/auto/threads/threads.so
56 %{_mandir}/man3/threads.3pm*
57 %{_examplesdir}/%{name}-%{version}