Files
perl-DateTime-Set/perl-DateTime-Set.spec

95 lines
3.2 KiB
RPMSpec
Raw Normal View History

#
# spec file for package perl-DateTime-Set (Version 0.28)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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/
#
# norootforbuild
Name: perl-DateTime-Set
%define cpan_name DateTime-Set
Summary: Datetime sets and set math
Version: 0.28
Release: 1
License: Distributable, see LICENSE
Group: Development/Libraries/Perl
Url: http://search.cpan.org/dist/DateTime-Set/
#Source: http://www.cpan.org/authors/id/F/FG/FGLOCK/DateTime-Set-0.28.tar.gz
Source: %{cpan_name}-%{version}.tar.bz2
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%{perl_requires}
BuildRequires: perl
BuildRequires: perl(Module::Build)
BuildRequires: perl-macros
BuildRequires: perl(DateTime) >= 0.12
BuildRequires: perl(Set::Infinite) >= 0.59
BuildRequires: perl(Test::More)
BuildRequires: perl(Params::Validate)
Requires: perl(DateTime) >= 0.12
Requires: perl(Set::Infinite) >= 0.59
Requires: perl(Params::Validate)
%description
DateTime::Set is a module for datetime sets. It can be used to handle two
different types of sets.
The first is a fixed set of predefined datetime objects. For example, if we
wanted to create a set of datetimes containing the birthdays of people in
our family for the current year.
The second type of set that it can handle is one based on a recurrence,
such as "every Wednesday", or "noon on the 15th day of every month". This
type of set can have fixed starting and ending datetimes, but neither is
required. So our "every Wednesday set" could be "every Wednesday from the
beginning of time until the end of time", or "every Wednesday after
2003-03-05 until the end of time", or "every Wednesday between 2003-03-05
and 2004-01-07".
This module also supports set math operations, so you do things like create
a new set from the union or difference of two sets, check whether a
datetime is a member of a given set, etc.
This is different from a 'DateTime::Span', which handles a continuous range
as opposed to individual datetime points. There is also a module
'DateTime::SpanSet' to handle sets of spans.
Authors:
--------
Flavio Soibelmann Glock <fglock@pucrs.br>
The API was developed together with Dave Rolsky and the DateTime Community.
%prep
%setup -q -n %{cpan_name}-%{version}
%build
%{__perl} Build.PL installdirs=vendor
./Build build flags=%{?_smp_mflags}
%check
./Build test
%install
./Build install destdir=$RPM_BUILD_ROOT create_packlist=0
%perl_gen_filelist
%clean
%{__rm} -rf $RPM_BUILD_ROOT
%files -f %{name}.files
%defattr(-,root,root,-)
%doc Changes LICENSE README TODO
%changelog