Blob Blame History Raw
Name:           perl-Event
Version:        1.11
Release:        2%{?dist}
Summary:        Event loop processing

Group:          Development/Libraries
License:        GPL+ or Artistic
URL:            http://search.cpan.org/dist/Event/ 
Source0:        http://search.cpan.org/CPAN/authors/id/J/JP/JPRIT/Event-%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires:  perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

# non-perl
BuildRequires:  /usr/bin/iconv
# core
BuildRequires:  perl(ExtUtils::MakeMaker)
BuildRequires:  perl(Time::HiRes)

Requires:       perl(Time::HiRes)

%description
The Event module provide a central facility to watch for various types of
events and invoke a callback when these events occur. The idea is to delay the
handling of events so that they may be dispatched in priority order when it is
safe for callbacks to execute.


%prep
%setup -q -n Event-%{version} 

# generate our two licenses...
perldoc perlgpl      > LICENSE.GPL
perldoc perlartistic > LICENSE.Artistic

# appease rpmlint :) 
find . -type f -exec chmod -c -x {} +
%{_fixperms} demo util
find t/ -type f -exec perl -pi -e 's|^#!\./perl|#!/usr/bin/perl|' {} +

# fix some other interperter issues..
cd demo
perl -pi -e 's|#!./perl|#!/usr/bin/perl|' *.t ../util/bench.pl


%build
%{__perl} Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
make %{?_smp_mflags}

# not implemented yet, so lets avoid deps
cd demo
for i in *.pm ; do
    mv $i $i.unimplemented
done

# make sure the man page is UTF-8...
cd ../blib/man3 
iconv --from=ISO-8859-1 --to=UTF-8 Event.3pm > Event.3pm.new
mv Event.3pm.new Event.3pm

%install
rm -rf %{buildroot}

make pure_install PERL_INSTALL_ROOT=%{buildroot}
find %{buildroot} -type f -name .packlist -exec rm -f {} +
find %{buildroot} -type f -name '*.bs' -a -size 0 -exec rm -f {} +
find %{buildroot} -type d -depth -exec rmdir --ignore-fail-on-non-empty {} +

%{_fixperms} %{buildroot}/*


%check
make test


%clean
rm -rf %{buildroot}


%files
%defattr(-,root,root,-)
%doc ANNOUNCE TODO README Tutorial.pdf ChangeLog demo/ util/ LICENSE* INSTALL
%doc t/
%{perl_vendorarch}/auto/Event
%{perl_vendorarch}/Event*
%{_mandir}/man3/*.3*


%changelog
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.11-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Wed May 21 2008 Chris Weyl <cweyl@alumni.drew.edu> 1.11-1
- update to 1.11

* Wed Feb 27 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 1.09-5
- Rebuild for perl 5.10 (again)

* Mon Feb 18 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.09-4
- Autorebuild for GCC 4.3

* Tue Feb  5 2008 Tom "spot" Callaway <tcallawa@redhat.com> 1.09-3
- rebuild for new perl

* Tue Aug 21 2007 Chris Weyl <cweyl@alumni.drew.edu> 1.09-2
- bump

* Fri Jun 01 2007 Chris Weyl <cweyl@alumni.drew.edu> 1.09-1
- update to 1.09
- add t/ to doc

* Sat Nov 04 2006 Chris Weyl <cweyl@alumni.drew.edu> 1.08-1
- update to 1.08

* Sun Oct 15 2006 Chris Weyl <cweyl@alumni.drew.edu> 1.07-1
- update to 1.07

* Thu Aug 31 2006 Chris Weyl <cweyl@alumni.drew.edu> 1.06-2
- bump for mass rebuild

* Wed Jun 14 2006 Chris Weyl <cweyl@alumni.drew.edu> 1.06-1
- add explicit provides: perl(Event) = version...  wasn't being picked up
  automagically for some reason
- Tweaked summary line
- Bumped release

* Thu Jun 08 2006 Chris Weyl <cweyl@alumni.drew.edu> 1.06-0
- initial spec file for F-E