forked from pool/perl-IPC-ShareLite
remove old
OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-IPC-ShareLite?expand=0&rev=10
This commit is contained in:
committed by
Git OBS Bridge
parent
a82e1e6a98
commit
82a549fe90
@@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:1ac32a4cb5e3841766687e1f3fc2d2ae1b9e5739feb5f661ccd5b32d90104969
|
|
||||||
size 20136
|
|
@@ -1,3 +1,18 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Sep 19 05:29:17 UTC 2014 - coolo@suse.com
|
||||||
|
|
||||||
|
- updated to 0.17
|
||||||
|
- Make unicode test work on older Perls.
|
||||||
|
|
||||||
|
0.16 2009-03-09
|
||||||
|
- Add unicode test.
|
||||||
|
|
||||||
|
0.15 2009-03-09
|
||||||
|
- Add some logging to help diagnose smoke failures.
|
||||||
|
|
||||||
|
0.14 2009-03-07
|
||||||
|
- Croak if 4 char key string is not 8-bit clean. See #33672.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Nov 30 19:20:23 UTC 2010 - coolo@novell.com
|
Tue Nov 30 19:20:23 UTC 2010 - coolo@novell.com
|
||||||
|
|
||||||
|
@@ -1,47 +1,108 @@
|
|||||||
%define modname IPC-ShareLite
|
#
|
||||||
Name: perl-%{modname}
|
# spec file for package perl-IPC-ShareLite
|
||||||
Version: 0.13
|
#
|
||||||
Release: 1
|
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
Summary: Light-Weight Interface to Shared Memory
|
#
|
||||||
|
# All modifications and additions to the file contributed by third parties
|
||||||
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
|
# upon. The license for this file, and modifications and additions to the
|
||||||
|
# file, is the same license as for the pristine package itself (unless the
|
||||||
|
# license for the pristine package is not an Open Source License, in which
|
||||||
|
# case the license is the MIT License). An "Open Source License" is a
|
||||||
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
|
Name: perl-IPC-ShareLite
|
||||||
|
Version: 0.17
|
||||||
|
Release: 0
|
||||||
|
%define cpan_name IPC-ShareLite
|
||||||
|
Summary: Lightweight interface to shared memory
|
||||||
|
License: Artistic-1.0 or GPL-1.0+
|
||||||
|
Group: Development/Libraries/Perl
|
||||||
|
Url: http://search.cpan.org/dist/IPC-ShareLite/
|
||||||
|
Source: http://www.cpan.org/authors/id/A/AN/ANDYA/%{cpan_name}-%{version}.tar.gz
|
||||||
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
BuildRequires: perl
|
BuildRequires: perl
|
||||||
BuildRequires: perl-macros
|
BuildRequires: perl-macros
|
||||||
License: GPL/Artistic
|
|
||||||
Group: Development/Libraries/Perl
|
|
||||||
Source: %{modname}-%{version}.tar.bz2
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-root
|
|
||||||
%{perl_requires}
|
%{perl_requires}
|
||||||
|
|
||||||
%description
|
%description
|
||||||
IPC::ShareLite provides a simple interface to shared memory, allowing data to
|
IPC::ShareLite provides a simple interface to shared memory, allowing data
|
||||||
be efficiently communicated between processes.
|
to be efficiently communicated between processes. Your operating system
|
||||||
|
must support SysV IPC (shared memory and semaphores) in order to use this
|
||||||
|
module.
|
||||||
|
|
||||||
Authors:
|
IPC::ShareLite provides an abstraction of the shared memory and semaphore
|
||||||
--------
|
facilities of SysV IPC, allowing the storage of arbitrarily large data; the
|
||||||
Maurice Aubrey <maurice@hevanet.com>
|
module automatically acquires and removes shared memory segments as needed.
|
||||||
|
Storage and retrieval of data is atomic, and locking functions are provided
|
||||||
|
for higher-level synchronization.
|
||||||
|
|
||||||
|
In many respects, this module is similar to IPC::Shareable. However,
|
||||||
|
IPC::ShareLite does not provide a tied interface, does not (automatically)
|
||||||
|
allow the storage of variables, and is written in C for additional speed.
|
||||||
|
|
||||||
|
Construct an IPC::ShareLite object by calling its constructor:
|
||||||
|
|
||||||
|
my $share = IPC::ShareLite->new(
|
||||||
|
-key => 1971,
|
||||||
|
-create => 'yes',
|
||||||
|
-destroy => 'no'
|
||||||
|
) or die $!;
|
||||||
|
|
||||||
|
Once an instance has been created, data can be written to shared memory by
|
||||||
|
calling the store() method:
|
||||||
|
|
||||||
|
$share->store("This is going in shared memory");
|
||||||
|
|
||||||
|
Retrieve the data by calling the fetch() method:
|
||||||
|
|
||||||
|
my $str = $share->fetch();
|
||||||
|
|
||||||
|
The store() and fetch() methods are atomic; any processes attempting to
|
||||||
|
read or write to the memory are blocked until these calls finish. However,
|
||||||
|
in certain situations, you'll want to perform multiple operations
|
||||||
|
atomically. Advisory locking methods are available for this purpose.
|
||||||
|
|
||||||
|
An exclusive lock is obtained by calling the lock() method:
|
||||||
|
|
||||||
|
$share->lock();
|
||||||
|
|
||||||
|
Happily, the lock() method also accepts all of the flags recognized by the
|
||||||
|
flock() system call. So, for example, you can obtain a shared lock like
|
||||||
|
this:
|
||||||
|
|
||||||
|
$share->lock( LOCK_SH );
|
||||||
|
|
||||||
|
Or, you can make either type of lock non-blocking:
|
||||||
|
|
||||||
|
$share->lock( LOCK_EX|LOCK_NB );
|
||||||
|
|
||||||
|
Release the lock by calling the unlock() method:
|
||||||
|
|
||||||
|
$share->unlock;
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{modname}-%{version}
|
%setup -q -n %{cpan_name}-%{version}
|
||||||
|
|
||||||
%build
|
%build
|
||||||
perl Makefile.PL OPTIMIZE="$RPM_OPT_FLAGS -Wall"
|
%{__perl} Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
|
||||||
make
|
%{__make} %{?_smp_mflags}
|
||||||
make test
|
|
||||||
|
%check
|
||||||
|
%{__make} test
|
||||||
|
|
||||||
%install
|
%install
|
||||||
make DESTDIR=$RPM_BUILD_ROOT install_vendor
|
%perl_make_install
|
||||||
%perl_process_packlist
|
%perl_process_packlist
|
||||||
|
%perl_gen_filelist
|
||||||
|
|
||||||
%clean
|
%files -f %{name}.files
|
||||||
rm -rf %{buildroot}
|
%defattr(-,root,root,755)
|
||||||
|
|
||||||
%files
|
|
||||||
%defattr(-, root, root)
|
|
||||||
%doc Changes README
|
%doc Changes README
|
||||||
%doc %{_mandir}/man?/*
|
|
||||||
%{perl_vendorarch}/IPC
|
|
||||||
%{perl_vendorarch}/auto/IPC
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
|
||||||
* Thu Nov 01 2007 - James Oakley <jfunk@funktronics.ca> - 0.09-1
|
|
||||||
- Initial release
|
|
||||||
|
Reference in New Issue
Block a user