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