]> git.pld-linux.org Git - SPECS.git/blob - perl-FFI-Raw.spec
SPECS updated Sun 1 Aug 20:28:02 CEST 2021
[SPECS.git] / perl-FFI-Raw.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4
5 %define         pdir    FFI
6 %define         pnam    Raw
7 Summary:        FFI::Raw - Perl bindings to the portable FFI library (libffi)
8 Name:           perl-FFI-Raw
9 Version:        0.32
10 Release:        1
11 # same as perl
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/
19 BuildRequires:  libffi
20 BuildRequires:  perl-devel >= 1:5.8.0
21 BuildRequires:  rpm-perlprov >= 4.1-13
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %description
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.
28
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).
34
35 %prep
36 %setup -q -n %{pdir}-%{pnam}-%{version}
37 %patch0 -p1
38 %patch1 -p1
39
40 %{__rm} -r deps/libffi
41
42 %build
43 %{__perl} Makefile.PL \
44         INSTALLDIRS=vendor
45 %{__make} \
46         CC="%{__cc}" \
47         OPTIMIZE="%{rpmcflags}"
48
49 %{?with_tests:%{__make} test}
50
51 %install
52 rm -rf $RPM_BUILD_ROOT
53
54 %{__make} install \
55         DESTDIR=$RPM_BUILD_ROOT
56
57 %clean
58 rm -rf $RPM_BUILD_ROOT
59
60 %files
61 %defattr(644,root,root,755)
62 %doc Change* README
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
67 %{_mandir}/man3/*
This page took 0.114909 seconds and 3 git commands to generate.