55696a1
%if ! (0%{?rhel})
f7bb5f3
# Run extra test
f7bb5f3
%bcond_without perl_Data_OptList_enables_extra_test
f7bb5f3
# Run optional test
f7bb5f3
%bcond_without perl_Data_OptList_enables_optional_test
55696a1
%else
55696a1
%bcond_with perl_Data_OptList_enables_extra_test
55696a1
%bcond_with perl_Data_OptList_enables_optional_test
55696a1
%endif
f7bb5f3
Chris Weyl 0fb4f64
Name:           perl-Data-OptList
3349cb0
Version:        0.110
fa2bc61
Release:        15%{?dist}
Chris Weyl 0fb4f64
Summary:        Parse and validate simple name/value option pairs
5d962d9
License:        GPL+ or Artistic
e032663
URL:            https://metacpan.org/release/Data-OptList
0f13ce0
Source0:        https://cpan.metacpan.org/modules/by-module/Data/Data-OptList-%{version}.tar.gz
Chris Weyl 0fb4f64
BuildArch:      noarch
3349cb0
# Module Build
3349cb0
BuildRequires:  coreutils
3349cb0
BuildRequires:  findutils
3349cb0
BuildRequires:  make
5e3ba51
BuildRequires:  perl-interpreter
c9cdf07
BuildRequires:  perl-generators
3349cb0
BuildRequires:  perl(ExtUtils::MakeMaker)
3349cb0
# Module Runtime
Chris Weyl 27be91e
BuildRequires:  perl(List::Util)
4da62bd
BuildRequires:  perl(Params::Util)
3349cb0
BuildRequires:  perl(strict)
Chris Weyl 27be91e
BuildRequires:  perl(Sub::Install) >= 0.921
3349cb0
BuildRequires:  perl(warnings)
3349cb0
# Test Suite
3349cb0
BuildRequires:  perl(File::Spec)
5b89ff0
BuildRequires:  perl(Test::More) >= 0.88
f7bb5f3
%if %{with perl_Data_OptList_enables_optional_test}
3349cb0
# Optional Tests
3349cb0
BuildRequires:  perl(CPAN::Meta) >= 2.120900
3349cb0
BuildRequires:  perl(CPAN::Meta::Prereqs)
f7bb5f3
%endif
f7bb5f3
%if %{with perl_Data_OptList_enables_extra_test}
3349cb0
# Extra Tests
e0be4ae
BuildRequires:  perl(Test::Pod) >= 1.41
f7bb5f3
%endif
3349cb0
# Dependencies
9b6ccf9
Requires:       perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
Chris Weyl 0fb4f64
Chris Weyl 0fb4f64
%description
9bc1700
Hashes are great for storing named data, but if you want more than one entry
9bc1700
for a name, you have to use a list of pairs. Even then, this is really boring
9bc1700
to write:
9bc1700
9bc1700
$values = [
9bc1700
    foo => undef,
9bc1700
    bar => undef,
9bc1700
    baz => undef,
9bc1700
    xyz => { ... },
9bc1700
];
9bc1700
9bc1700
With Data::OptList, you can do this instead:
9bc1700
9bc1700
$values = Data::OptList::mkopt([
9bc1700
    qw(foo bar baz),
9bc1700
    xyz => { ... },
9bc1700
]);
9bc1700
9bc1700
This works by assuming that any defined scalar is a name and any reference
9bc1700
following a name is its value.
Chris Weyl 0fb4f64
Chris Weyl 0fb4f64
%prep
Chris Weyl 0fb4f64
%setup -q -n Data-OptList-%{version}
Chris Weyl 0fb4f64
3349cb0
# Fix shellbangs in tests
d8aca68
for F in t/*; do
d8aca68
    perl -MExtUtils::MakeMaker -e "ExtUtils::MM_Unix->fixin(q{$F})"
d8aca68
done
43f7280
Chris Weyl 0fb4f64
%build
9b6ccf9
perl Makefile.PL INSTALLDIRS=vendor
Chris Weyl 0fb4f64
make %{?_smp_mflags}
Chris Weyl 0fb4f64
Chris Weyl 0fb4f64
%install
Chris Weyl 27be91e
make pure_install DESTDIR=%{buildroot}
3349cb0
find %{buildroot} -type f -name .packlist -delete
9bc1700
%{_fixperms} %{buildroot}
Chris Weyl 0fb4f64
Chris Weyl 0fb4f64
%check
5b89ff0
make test
f7bb5f3
%if %{with perl_Data_OptList_enables_extra_test}
5b89ff0
make test TEST_FILES="$(echo $(find xt/ -name '*.t'))"
f7bb5f3
%endif
Chris Weyl 0fb4f64
Chris Weyl 0fb4f64
%files
3349cb0
%license LICENSE
3349cb0
%doc Changes README t/
9bc1700
%{perl_vendorlib}/Data/
3349cb0
%{_mandir}/man3/Data::OptList.3*
Chris Weyl 0fb4f64
Chris Weyl 0fb4f64
%changelog
fa2bc61
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-15
fa2bc61
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
fa2bc61
a228b36
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-14
a228b36
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
a228b36
9312813
* Tue Jun 23 2020 Jitka Plesnikova <jplesnik@redhat.com> - 0.110-13
9312813
- Perl 5.32 rebuild
9312813
a6fc914
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-12
a6fc914
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
a6fc914
378059d
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-11
378059d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
378059d
f7baa89
* Fri May 31 2019 Jitka Plesnikova <jplesnik@redhat.com> - 0.110-10
f7baa89
- Perl 5.30 rebuild
f7baa89
91acce4
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-9
91acce4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
91acce4
7bf9a0c
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-8
7bf9a0c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
7bf9a0c
69d9cac
* Thu Jun 28 2018 Jitka Plesnikova <jplesnik@redhat.com> - 0.110-7
69d9cac
- Perl 5.28 rebuild
69d9cac
79b92e0
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-6
79b92e0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
79b92e0
b927fff
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-5
b927fff
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
b927fff
65a491a
* Sun Jun 04 2017 Jitka Plesnikova <jplesnik@redhat.com> - 0.110-4
65a491a
- Perl 5.26 rebuild
65a491a
9512df0
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.110-3
9512df0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
9512df0
3af8770
* Sun May 15 2016 Jitka Plesnikova <jplesnik@redhat.com> - 0.110-2
3af8770
- Perl 5.24 rebuild
3af8770
3349cb0
* Fri Mar 25 2016 Paul Howarth <paul@city-fan.org> - 0.110-1
3349cb0
- Update to 0.110
3349cb0
  - Major optimization to mkopt
3349cb0
- Use %%license
3349cb0
- Simplify find expression using -delete
3349cb0
7bc0c08
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.109-7
7bc0c08
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
7bc0c08
3eee7d5
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.109-6
3eee7d5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
3eee7d5
e48dd82
* Fri Jun 05 2015 Jitka Plesnikova <jplesnik@redhat.com> - 0.109-5
e48dd82
- Perl 5.22 rebuild
e48dd82
d8aca68
* Thu Jan 15 2015 Petr Pisar <ppisar@redhat.com> - 0.109-4
d8aca68
- Do not hard-code interpreter name
e0be4ae
- Specify all dependencies
d8aca68
a49c180
* Wed Aug 27 2014 Jitka Plesnikova <jplesnik@redhat.com> - 0.109-3
a49c180
- Perl 5.20 rebuild
a49c180
d5ca254
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.109-2
d5ca254
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
d5ca254
5e4c3c1
* Fri Dec 13 2013 Paul Howarth <paul@city-fan.org> - 0.109-1
5e4c3c1
- Update to 0.109:
5e4c3c1
  - Update bugtracker and repo links
5e4c3c1
b1ad603
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.108-3
b1ad603
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
b1ad603
78229c2
* Sun Jul 21 2013 Petr Pisar <ppisar@redhat.com> - 0.108-2
78229c2
- Perl 5.18 rebuild
78229c2
5b89ff0
* Sat Jul  6 2013 Paul Howarth <paul@city-fan.org> - 0.108-1
5b89ff0
- Update to 0.108:
5b89ff0
  - Repackage, new bug tracker
5b89ff0
- Explicitly run the extra tests
5b89ff0
- Don't need to remove empty directories from the buildroot
5b89ff0
- Drop obsoletes/provides for old -tests sub-package
5b89ff0
40e0e01
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.107-9
40e0e01
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
40e0e01
43f7280
* Tue Nov 13 2012 Jitka Plesnikova <jplesnik@redhat.com> - 0.107-8
43f7280
- Fix wrong script interpreter
43f7280
a1d01ae
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.107-7
a1d01ae
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
a1d01ae
0bbe386
* Mon Jun 11 2012 Petr Pisar <ppisar@redhat.com> - 0.107-6
0bbe386
- Perl 5.16 rebuild
0bbe386
c09fc58
* Sat Jan 21 2012 Paul Howarth <paul@city-fan.org> - 0.107-5
c09fc58
- obsolete/provide old -tests subpackage to support upgrades
c09fc58
9b6ccf9
* Fri Jan 20 2012 Paul Howarth <paul@city-fan.org> - 0.107-4
9b6ccf9
- drop -tests subpackage (general lack of interest in this), but include
9b6ccf9
  them as documentation for the main package
9b6ccf9
- drop redundant %%{?perl_default_filter}
9b6ccf9
- don't use macros for commands
9b6ccf9
- can't find any dependency cycle so drop %%{?perl_bootstrap} usage
9b6ccf9
- drop ExtUtils::MakeMaker version requirement to 6.30, actual working minimum
9b6ccf9
9bc1700
* Wed Jan 11 2012 Paul Howarth <paul@city-fan.org> - 0.107-3
9bc1700
- package LICENSE file
9bc1700
- run test suite even when bootstrapping, as it should still pass
9bc1700
- run release tests too
9bc1700
- enhance %%description so it makes sense
9bc1700
- BR: perl(Test::More)
9bc1700
f5994a9
* Tue Jun 28 2011 Marcela Mašláňová <mmaslano@redhat.com> - 0.107-2
f5994a9
- Perl mass rebuild
f5994a9
- add perl_bootstrap macro
f5994a9
4da62bd
* Wed May 11 2011 Iain Arnell <iarnell@gmail.com> 0.107-1
4da62bd
- update to latest upstream version
4da62bd
- clean up spec for modern rpmbuild
4da62bd
8f74b5f
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.106-4
8f74b5f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
8f74b5f
c0d5001
* Thu Dec 16 2010 Marcela Maslanova <mmaslano@redhat.com> - 0.106-3
9b6ccf9
- rebuild to fix problems with vendorarch/lib (#661697)
c0d5001
e9f7aaa
* Fri Apr 30 2010 Marcela Maslanova <mmaslano@redhat.com> - 0.106-2
e9f7aaa
- Mass rebuild with perl-5.12.0
e9f7aaa
Chris Weyl 27be91e
* Mon Mar 08 2010 Chris Weyl <cweyl@alumni.drew.edu> 0.106-1
Chris Weyl 27be91e
- update by Fedora::App::MaintainerTools 0.004
Chris Weyl 27be91e
- PERL_INSTALL_ROOT => DESTDIR
Chris Weyl 27be91e
- updating to latest GA CPAN version (0.106)
Chris Weyl 27be91e
- added a new br on perl(ExtUtils::MakeMaker) (version 6.42)
Chris Weyl 27be91e
- added a new br on perl(List::Util) (version 0)
Chris Weyl 27be91e
- altered br on perl(Sub::Install) (0.92 => 0.921)
Chris Weyl 27be91e
- added a new req on perl(List::Util) (version 0)
Chris Weyl 27be91e
- added a new req on perl(Params::Util) (version 0.14)
Chris Weyl 27be91e
- added a new req on perl(Sub::Install) (version 0.921)
Chris Weyl 27be91e
f00923e
* Mon Dec  7 2009 Stepan Kasal <skasal@redhat.com> - 0.104-4
f00923e
- rebuild against perl 5.10.1
f00923e
bd73f01
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.104-3
bd73f01
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
bd73f01
9a07377
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.104-2
9a07377
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
9a07377
Chris Weyl 00709d1
* Wed Feb 11 2009 Chris Weyl <cweyl@alumni.drew.edu> 0.104-1
Chris Weyl 00709d1
- update to 0.104
Chris Weyl 00709d1
d5d8bdb
* Wed Feb 27 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0.103-2
d5d8bdb
- Rebuild for perl 5.10 (again)
d5d8bdb
5d962d9
* Thu Jan 24 2008 Tom "spot" Callaway <tcallawa@redhat.com> 0.103-1
5d962d9
- rebuild for new perl
5d962d9
- bump to 0.103
5d962d9
- fix license tag
5d962d9
Chris Weyl a923a28
* Thu Sep 07 2006 Chris Weyl <cweyl@alumni.drew.edu> 0.101-2
Chris Weyl a923a28
- bump
Chris Weyl a923a28
Chris Weyl 0fb4f64
* Sat Sep 02 2006 Chris Weyl <cweyl@alumni.drew.edu> 0.101-1
Chris Weyl 0fb4f64
- Specfile autogenerated by cpanspec 1.69.1.