commit 84613bd78c1f3105769a46b349989d4080db8fd1
Author: Arkadiusz Miƛkiewicz <[email protected]>
Date:   Fri Dec 11 10:15:32 2020 +0100

    - initial

 perl-PerlIO-via-Timeout.spec | 67 ++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 67 insertions(+)
---
diff --git a/perl-PerlIO-via-Timeout.spec b/perl-PerlIO-via-Timeout.spec
new file mode 100644
index 0000000..f25e943
--- /dev/null
+++ b/perl-PerlIO-via-Timeout.spec
@@ -0,0 +1,67 @@
+#
+# Conditional build:
+%bcond_without tests           # do not perform "make test"
+#
+%define                pdir    PerlIO
+%define                pnam    via-Timeout
+Summary:       PerlIO::via::Timeout - a PerlIO layer that adds read & write 
timeout to a handle
+#Summary(pl.UTF-8):
+Name:          perl-PerlIO-via-Timeout
+Version:       0.32
+Release:       1
+# same as perl
+License:       GPL v1+ or Artistic
+Group:         Development/Languages/Perl
+Source0:       
http://www.cpan.org/modules/by-module/PerlIO/%{pdir}-%{pnam}-%{version}.tar.gz
+# Source0-md5: f18328a39a5eaa386e34df80f066039b
+# generic URL, check or change before uncommenting
+#URL:          https://metacpan.org/release/PerlIO-via-Timeout
+BuildRequires: perl-Module-Build
+BuildRequires: perl-devel >= 1:5.8.0
+BuildRequires: rpm-perlprov >= 4.1-13
+BuildRequires: rpmbuild(macros) >= 1.745
+%if %{with tests}
+BuildRequires: perl-Test-TCP
+%endif
+BuildArch:     noarch
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+This package implements a PerlIO layer, that adds read / write
+timeout. This can be useful to avoid blocking while accessing a handle
+(file, socket, ...), and fail after some time.
+
+The timeout is implemented by using <select> on the handle before
+reading/writing.
+
+WARNING the handle won't timeout if you use sysread or syswrite on it,
+because these functions works at a lower level. However if you're
+trying to implement a timeout for a socket, see IO::Socket::Timeout
+that implements exactly that.
+
+%prep
+%setup -q -n %{pdir}-%{pnam}-%{version}
+
+%build
+%{__perl} Build.PL \
+       --destdir=$RPM_BUILD_ROOT \
+       --installdirs=vendor
+./Build
+
+%{?with_tests:./Build test}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+./Build install \
+       --prefix=%{_prefix} \
+       --destdir=$RPM_BUILD_ROOT
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc Changes README
+%{perl_vendorlib}/PerlIO/via/*.pm
+%{_mandir}/man3/*
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/perl-PerlIO-via-Timeout.git/commitdiff/84613bd78c1f3105769a46b349989d4080db8fd1

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to