3 %bcond_with tests # do perform "make test"
6 Summary: Sane - Perl extension for the SANE (Scanner Access Now Easy) Project
12 License: GPL v1+ or Artistic
13 Group: Development/Languages/Perl
14 Source0: http://www.cpan.org/modules/by-authors/id/R/RA/RATCLIFFE/%{pdir}-%{version}.tar.gz
15 # Source0-md5: db83b8b07e1263b78187c4349a183082
16 URL: http://search.cpan.org/dist/Sane/
17 BuildRequires: perl-ExtUtils-Depends
18 BuildRequires: perl-ExtUtils-PkgConfig
19 BuildRequires: perl-devel >= 1:5.8.0
20 BuildRequires: rpm-perlprov >= 4.1-13
21 BuildRequires: sane-backends-devel
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 The Sane module allows a Perl developer to use SANE-compatible
26 scanners. Find out more about SANE at <http://www.sane-project.org>.
28 Most methods set $Sane::STATUS, which is overloaded to give either an
29 integer as dictated by the SANE standard, or the the corresponding
32 Returns an array with the SANE_VERSION_(MAJOR|MINOR|BUILD) versions:
33 - join('.',Sane->get_version)
35 # %description -l pl.UTF-8
39 %setup -q -n %{pdir}-%{version}
42 %{__perl} Makefile.PL \
46 OPTIMIZE="%{rpmcflags}"
48 %{?with_tests:%{__make} test}
51 rm -rf $RPM_BUILD_ROOT
53 %{__make} pure_install \
54 DESTDIR=$RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
57 cp -a examples $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
60 rm -rf $RPM_BUILD_ROOT
63 %defattr(644,root,root,755)
65 %{perl_vendorarch}/Sane.pm
66 %dir %{perl_vendorarch}/auto/Sane/
67 %attr(755,root,root) %{perl_vendorarch}/auto/Sane/*.so
69 %{_examplesdir}/%{name}-%{version}