3 %bcond_without tests # do not perform "make test"
7 Summary: FFI::Raw - Perl bindings to the portable FFI library (libffi)
12 License: GPL v1+ or Artistic
13 Group: Development/Languages/Perl
14 Source0: http://www.cpan.org/modules/by-module/FFI/%{pdir}-%{pnam}-%{version}.tar.gz
15 # Source0-md5: a2fa68728f71f17fc869f7d56592de87
16 Patch0: %{name}-makefile.patch
17 Patch1: %{name}-manifest.patch
18 URL: http://search.cpan.org/dist/FFI-Raw/
20 BuildRequires: perl-devel >= 1:5.8.0
21 BuildRequires: rpm-perlprov >= 4.1-13
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 FFI::Raw provides a low-level foreign function interface (FFI) for
26 Perl based on libffi. In essence, it can access and call functions
27 exported by shared libraries without the need to write C/XS code.
29 Dynamic symbols can be automatically resolved at runtime so that the
30 only information needed to use FFI::Raw is the name (or path) of the
31 target library, the name of the function to call and its signature
32 (though it is also possible to pass a function pointer obtained, for
33 example, using DynaLoader).
36 %setup -q -n %{pdir}-%{pnam}-%{version}
40 %{__rm} -r deps/libffi
43 %{__perl} Makefile.PL \
47 OPTIMIZE="%{rpmcflags}"
49 %{?with_tests:%{__make} test}
52 rm -rf $RPM_BUILD_ROOT
55 DESTDIR=$RPM_BUILD_ROOT
58 rm -rf $RPM_BUILD_ROOT
61 %defattr(644,root,root,755)
63 %{perl_vendorarch}/FFI/Raw.pm
64 %{perl_vendorarch}/FFI/Raw
65 %dir %{perl_vendorarch}/auto/FFI/Raw
66 %attr(755,root,root) %{perl_vendorarch}/auto/FFI/Raw/Raw.so