[packages/perl-FFI] - initial, version 1.09

adwol adwol at pld-linux.org
Sun Oct 2 20:10:14 CEST 2016


commit cb387258dba4a8cc57cfae788a1fbf1aef88625b
Author: Adam Osuchowski <adwol at pld-linux.org>
Date:   Sun Oct 2 20:09:53 2016 +0200

    - initial, version 1.09

 perl-FFI-Makefile.patch | 21 ++++++++++++++++++
 perl-FFI.spec           | 59 +++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 80 insertions(+)
---
diff --git a/perl-FFI.spec b/perl-FFI.spec
new file mode 100644
index 0000000..3bf7d79
--- /dev/null
+++ b/perl-FFI.spec
@@ -0,0 +1,59 @@
+#
+# Conditional build:
+%bcond_with	tests		# do perform "make test"
+
+%define		pdir	FFI
+%include	/usr/lib/rpm/macros.perl
+Summary:	FFI - Perl Foreign Function Interface based on GNU ffcall
+Name:		perl-FFI
+Version:	1.09
+Release:	1
+License:	GPL v1+ or Artistic
+Group:		Development/Languages/Perl
+Source0:	http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{version}.tar.gz
+# Source0-md5:	0c0e575e6440ea8fa39e132eada55ce4
+Patch0:		%{name}-Makefile.patch
+URL:		http://search.cpan.org/dist/FFI/
+BuildRequires:	ffcall-devel
+BuildRequires:	perl-devel >= 1:5.8.0
+BuildRequires:	rpm-perlprov >= 4.1-13
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+This module provides a low-level foreign function interface to Perl.
+It allows the calling of any function for which the user can supply
+an address and calling signature. Furthermore, it provides a method
+of encapsulating Perl subroutines as callback functions whose
+addresses can be passed to C code.
+
+%prep
+%setup -q -n %{pdir}-%{version}
+%patch0 -p1
+
+%build
+%{__perl} Makefile.PL \
+	INSTALLDIRS=vendor
+%{__make} \
+	CC="%{__cc}" \
+	OPTIMIZE="%{rpmcflags}"
+
+%{?with_tests:%{__make} test}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} pure_install \
+	DESTDIR=$RPM_BUILD_ROOT
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc Changes README TODO
+%dir %{perl_vendorarch}/FFI
+%{perl_vendorarch}/FFI.pm
+%{perl_vendorarch}/FFI/Library.pm
+%dir %{perl_vendorarch}/auto/FFI/
+%attr(755,root,root) %{perl_vendorarch}/auto/FFI/*.so
+%{_mandir}/man3/*.3pm*
diff --git a/perl-FFI-Makefile.patch b/perl-FFI-Makefile.patch
new file mode 100644
index 0000000..ea273bf
--- /dev/null
+++ b/perl-FFI-Makefile.patch
@@ -0,0 +1,21 @@
+diff -ruN FFI-1.09.orig/Makefile.PL FFI-1.09/Makefile.PL
+--- FFI-1.09.orig/Makefile.PL	2015-08-01 19:58:23.000000000 +0200
++++ FFI-1.09/Makefile.PL	2016-10-02 20:06:58.398109893 +0200
+@@ -7,7 +7,6 @@
+ 
+ use 5.008001;
+ use ExtUtils::MakeMaker;
+-use Alien::FFCall;
+ 
+ WriteMakefile(
+   'NAME'               => 'FFI',
+@@ -17,8 +16,7 @@
+   'LICENSE'            => 'gpl_2',
+   'DEFINE'             => ($^O eq "MSWin32" ? '-DWIN32' : ''),
+   'MIN_PERL_VERSION'   => '5.008001',
+-  'CCFLAGS'            => Alien::FFCall->cflags,
+-  'LIBS'               => Alien::FFCall->libs,
++  'LIBS'               => '-lcallback -lavcall',
+   'CONFIGURE_REQUIRES' => {
+     'Alien::FFCall'       => 0.02,
+     'ExtUtils::MakeMaker' => '6.52',
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/perl-FFI.git/commitdiff/cb387258dba4a8cc57cfae788a1fbf1aef88625b



More information about the pld-cvs-commit mailing list