#
# spec file for package perl-Unicode-String
#
# Copyright (c) 2016 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-Unicode-String
Version:        2.10
Release:        154.135
%define cpan_name Unicode-String
Summary:        String of Unicode characters (UTF-16BE)
License:        GPL-1.0+ or Artistic-1.0
Group:          Development/Libraries/Perl
Url:            http://search.cpan.org/dist/Unicode-String/
Source0:        http://www.cpan.org/authors/id/G/GA/GAAS/GAAS/%{cpan_name}-%{version}.tar.gz
Source1:        cpanspec.yml
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  perl
BuildRequires:  perl-macros
%{perl_requires}

%description
A 'Unicode::String' object represents a sequence of Unicode characters.
Methods are provided to convert between various external formats
(encodings) and 'Unicode::String' objects, and methods are provided for
common string manipulations.

The functions utf32be(), utf32le(), utf16be(), utf16le(), utf8(), utf7(),
latin1(), uhex(), uchr() can be imported from the 'Unicode::String' module
and will work as constructors initializing strings of the corresponding
encoding.

The 'Unicode::String' objects overload various operators, which means that
they in most cases can be treated like plain strings.

Internally a 'Unicode::String' object is represented by a string of 2 byte
numbers in network byte order (big-endian). This representation is not
visible by the API provided, but it might be useful to know in order to
predict the efficiency of the provided methods.

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

%build
%{__perl} Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
%{__make} %{?_smp_mflags}

%check
%{__make} test

%install
%perl_make_install
%perl_process_packlist
%perl_gen_filelist

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

%changelog
* Fri Sep  9 2016 coolo@suse.com
- updated to 2.10
  * Applied patch from Michael Joyce that is required to make the
    test pass for perl-5.24 (perl522.patch)
* Thu Aug 27 2015 hsk@imb-jena.de
- perl522.patch: fix to make module work with perl-5.22
* Wed Oct 15 2014 jengelh@inai.de
- Use source URLs and remove ancient specfile tags and sections
* Fri Nov 18 2011 coolo@suse.com
- use original .tar.gz
* Tue Nov 30 2010 coolo@novell.com
- switch to perl_requires macro
* Mon Nov 29 2010 coolo@novell.com
- remove /var/adm/perl-modules
* Tue Oct 19 2010 coolo@novell.com
- add perl as explicit buildrequire
* Sun Jan 10 2010 jengelh@medozas.de
- enable parallel build
* Wed Jan 25 2006 mls@suse.de
- converted neededforbuild to BuildRequires
* Wed Jan  4 2006 anicka@suse.cz
- update to 2.09
* Tue Oct  4 2005 dmueller@suse.de
- add norootforbuild
* Fri Aug 22 2003 mjancar@suse.cz
- require the perl version we build with
* Tue Jul 15 2003 mjancar@suse.cz
- adapt to perl-5.8.1
- use %%perl_process_packlist
* Mon Jun 16 2003 mjancar@suse.cz
- update to 2.07
- use $RPM_OPT_FLAGS
- fix filelist
* Mon May 19 2003 ro@suse.de
- remove perllocal.pod
* Mon Jul 29 2002 mls@suse.de
- Fixed neededforbuild for perl-5.8.0
* Tue Jul  2 2002 mls@suse.de
- remove race in .packlist generation
* Wed Aug 15 2001 rvasice@suse.cz
- initial package release (version 2.06)