File perl-MongoDB.spec of Package perl-MongoDB

#
# spec file for package perl-MongoDB
#
# Copyright (c) 2019 SUSE LINUX 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/
#


Name:           perl-MongoDB
Version:        2.0.3
Release:        0
%define cpan_name MongoDB
Summary: Official MongoDB Driver for Perl
License:        Apache-2.0
Group:          Development/Libraries/Perl
Url:            https://metacpan.org/release/%{cpan_name}
Source0:        https://cpan.metacpan.org/authors/id/M/MO/MONGODB/%{cpan_name}-v%{version}.tar.bz2
BuildArch:      noarch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
# BuildRequires: perl(Test::Pod) perl(Test::Pod::Coverage)
BuildRequires:  perl
BuildRequires:  perl-macros
BuildRequires:  perl(Authen::SASL::SASLprep)
BuildRequires:  perl(Authen::SCRAM::Client) >= 0.011
BuildRequires:  perl(BSON) >= 1.010001
BuildRequires:  perl(BSON::Bytes)
BuildRequires:  perl(BSON::Code)
BuildRequires:  perl(BSON::DBRef)
BuildRequires:  perl(BSON::Decimal128)
BuildRequires:  perl(BSON::OID)
BuildRequires:  perl(BSON::Raw)
BuildRequires:  perl(BSON::Regex)
BuildRequires:  perl(BSON::Time)
BuildRequires:  perl(BSON::Timestamp)
BuildRequires:  perl(BSON::Types)
BuildRequires:  perl(BSON::XS) >= 0.006000
BuildRequires:  perl(Class::XSAccessor)
BuildRequires:  perl(Compress::Zlib)
BuildRequires:  perl(JSON::MaybeXS)
BuildRequires:  perl(Moo) >= 2
BuildRequires:  perl(Moo::Role)
BuildRequires:  perl(Net::DNS)
BuildRequires:  perl(Path::Tiny) >= 0.054
BuildRequires:  perl(Safe::Isa) >= 1.000007
BuildRequires:  perl(Sub::Defer)
BuildRequires:  perl(Sub::Quote)
BuildRequires:  perl(Test::Deep) >= 0.111
BuildRequires:  perl(Test::Fatal)
BuildRequires:  perl(Test::More) >= 0.96
BuildRequires:  perl(Tie::IxHash)
BuildRequires:  perl(Try::Tiny)
BuildRequires:  perl(Type::Library)
BuildRequires:  perl(Type::Tiny::XS)
BuildRequires:  perl(Type::Utils)
BuildRequires:  perl(Types::Standard)
BuildRequires:  perl(UUID::URandom)
BuildRequires:  perl(boolean) >= 0.25
BuildRequires:  perl(namespace::clean)
BuildRequires:  perl(version)
Requires:       perl(Authen::SASL::SASLprep)
Requires:       perl(Authen::SCRAM::Client) >= 0.011
Requires:       perl(BSON) >= 1.010001
Requires:       perl(BSON::Bytes)
Requires:       perl(BSON::Code)
Requires:       perl(BSON::DBRef)
Requires:       perl(BSON::OID)
Requires:       perl(BSON::Raw)
Requires:       perl(BSON::Regex)
Requires:       perl(BSON::Time)
Requires:       perl(BSON::Timestamp)
Requires:       perl(BSON::Types)
Requires:       perl(BSON::XS) >= 0.006000
Requires:       perl(Class::XSAccessor)
Requires:       perl(Compress::Zlib)
Requires:       perl(Moo) >= 2
Requires:       perl(Moo::Role)
Requires:       perl(Net::DNS)
Requires:       perl(Safe::Isa) >= 1.000007
Requires:       perl(Sub::Defer)
Requires:       perl(Sub::Quote)
Requires:       perl(Tie::IxHash)
Requires:       perl(Try::Tiny)
Requires:       perl(Type::Library)
Requires:       perl(Type::Tiny::XS)
Requires:       perl(Type::Utils)
Requires:       perl(Types::Standard)
Requires:       perl(UUID::URandom)
Requires:       perl(boolean) >= 0.25
Requires:       perl(namespace::clean)
Requires:       perl(version)
Recommends:     perl(IO::Socket::IP) >= 0.32
Recommends:     perl(IO::Socket::SSL) >= 1.42
Recommends:     perl(Mozilla::CA) >= 20130114
Recommends:     perl(Net::SSLeay) >= 1.49
%{perl_requires}

%description
This is the official Perl driver for at http://www.mongodb.com. MongoDB is
an open-source document database that provides high performance, high
availability, and easy scalability.

A MongoDB server (or multi-server deployment) hosts a number of databases.
A database holds a set of collections. A collection holds a set of
documents. A document is a set of key-value pairs. Documents have dynamic
schema. Using dynamic schema means that documents in the same collection do
not need to have the same set of fields or structure, and common fields in
a collection's documents may hold different types of data.

Here are some resources for learning more about MongoDB:

  * at http://docs.mongodb.org/manual/contents/

  * at http://docs.mongodb.org/manual/core/crud-introduction/

  * at http://docs.mongodb.org/manual/core/data-modeling-introduction/

To get started with the Perl driver, see these pages:

  * MongoDB Perl Driver Tutorial

  * MongoDB Perl Driver Examples

Extensive documentation and support resources are available via the at
http://www.mongodb.org/.

%prep
%setup -q -n %{cpan_name}-v%{version}

%build
export AUTOMATED_TESTING=1
perl Makefile.PL INSTALLDIRS=vendor
make %{?_smp_mflags}

%check
export AUTOMATED_TESTING=1
make test

%install
%perl_make_install
find %buildroot/%_prefix -name *.bs -a -size 0 | xargs rm -f
%perl_process_packlist
%perl_gen_filelist

%files -f %{name}.files
%defattr(-,root,root,755)
%doc Changes CONTRIBUTING.md README README.md
%license LICENSE

%changelog