Name:           perl-CGI-Ajax
Version:        0.707
Release:        3%{?_dist_release}
Summary:        Perl-specific system for writing Asynchronous web applications
License:        GPL or Artistic 
Group:          Development/Libraries
URL:            http://search.cpan.org/dist/CGI-Ajax/
Source0:        http://www.cpan.org/authors/id/B/BC/BCT/CGI-Ajax-%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-root
BuildArch:      noarch
BuildRequires:  perl(ExtUtils::MakeMaker)
BuildRequires:  perl(Class::Accessor)
BuildRequires:  perl(CGI)

# neither are picked up automagically.
Requires:       perl(CGI), perl(Class::Accessor)
Requires:       perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

%description
CGI::Ajax is an object-oriented module that provides a unique mechanism for
using perl code asynchronously from javascript- enhanced HTML pages.
CGI::Ajax unburdens the user from having to write extensive javascript,
except for associating an exported method with a document-defined event
(such as onClick, onKeyUp, etc). CGI::Ajax also mixes well with HTML
containing more complex javascript.

%prep
%setup -q -n CGI-Ajax-%{version}

find scripts/ -type f -exec chmod -c -x {} \;

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

%install
rm -rf %{buildroot}

make pure_install PERL_INSTALL_ROOT=%{buildroot}

find %{buildroot} -type f -name .packlist -exec rm -f {} \;
find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \;

%{_fixperms} %{buildroot}/*

%check
make test

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
%doc Changes LICENSE README Todo scripts/
%{perl_vendorlib}/*
%{_mandir}/man3/*

%changelog
* Sat Oct 25 2014 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 0.707-3
- rebuilt with perl-5.16.3

* Sat Jul 27 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.707-2
- rebuild with perl-5.12.3

* Thu Nov 12 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.707-1
- new upstream release
- applied new versioning policy

* Sat Jul 21 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.701-2vl1
- initial build for Vine Linux

* Mon Apr 16 2007 Chris Weyl <cweyl@alumni.drew.edu> 0.701-2
- bump

* Mon Apr 09 2007 Chris Weyl <cweyl@alumni.drew.edu> 0.701-1
- Specfile autogenerated by cpanspec 1.70.
