2017-10-08 07:51:56 +00:00
|
|
|
#
|
|
|
|
# spec file for package perl-PerlIO-eol
|
|
|
|
#
|
2024-03-08 22:56:38 +00:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2017-10-08 07:51:56 +00:00
|
|
|
#
|
|
|
|
# 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.
|
|
|
|
|
2023-05-03 15:20:39 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2017-10-08 07:51:56 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
|
2023-05-03 15:20:39 +00:00
|
|
|
%define cpan_name PerlIO-eol
|
2017-10-08 07:51:56 +00:00
|
|
|
Name: perl-PerlIO-eol
|
2023-07-28 07:44:14 +00:00
|
|
|
Version: 0.190.0
|
2017-10-08 07:51:56 +00:00
|
|
|
Release: 0
|
2023-07-28 07:44:14 +00:00
|
|
|
%define cpan_version 0.19
|
|
|
|
Provides: perl(PerlIO::eol) = 0.190.0
|
2018-03-01 08:31:20 +00:00
|
|
|
License: Artistic-1.0 OR GPL-1.0-or-later
|
2023-05-03 15:20:39 +00:00
|
|
|
Summary: PerlIO layer for normalizing line endings
|
|
|
|
URL: https://metacpan.org/release/%{cpan_name}
|
2023-07-28 07:44:14 +00:00
|
|
|
Source0: https://cpan.metacpan.org/authors/id/S/SH/SHLOMIF/%{cpan_name}-%{cpan_version}.tar.gz
|
2017-10-08 07:51:56 +00:00
|
|
|
Source1: cpanspec.yml
|
2025-08-12 18:16:29 +02:00
|
|
|
Source100: README.md
|
2017-10-08 07:51:56 +00:00
|
|
|
BuildRequires: perl
|
|
|
|
BuildRequires: perl-macros
|
2023-07-28 07:44:14 +00:00
|
|
|
BuildRequires: perl(File::Temp) >= 0.19
|
2024-03-08 22:56:38 +00:00
|
|
|
%undefine __perllib_provides
|
2017-10-08 07:51:56 +00:00
|
|
|
%{perl_requires}
|
|
|
|
|
|
|
|
%description
|
|
|
|
This layer normalizes any of 'CR', 'LF', 'CRLF' and 'Native' into the
|
|
|
|
designated line ending. It works for both input and output handles.
|
|
|
|
|
|
|
|
If you specify two different line endings joined by a '-', it will use the
|
|
|
|
first one for reading and the second one for writing. For example, the
|
|
|
|
'LF-CRLF' encoding means that all input should be normalized to 'LF', and
|
|
|
|
all output should be normalized to 'CRLF'.
|
|
|
|
|
|
|
|
By default, data with mixed newlines are normalized silently. Append a '!'
|
|
|
|
to the line ending will raise a fatal exception when mixed newlines are
|
|
|
|
spotted. Append a '?' will raise a warning instead.
|
|
|
|
|
|
|
|
It is advised to pop any potential ':crlf' or encoding layers before this
|
|
|
|
layer; this is usually done using a ':raw' prefix.
|
|
|
|
|
|
|
|
This module also optionally exports a 'eol_is_mixed' function; it takes a
|
|
|
|
string and returns the position of the first inconsistent line ending found
|
|
|
|
in that string, or '0' if the line endings are consistent.
|
|
|
|
|
|
|
|
The 'CR', 'LF', 'CRLF' and 'NATIVE' constants are also exported at request.
|
|
|
|
|
|
|
|
%prep
|
2023-07-28 07:44:14 +00:00
|
|
|
%autosetup -n %{cpan_name}-%{cpan_version}
|
2017-10-08 07:51:56 +00:00
|
|
|
|
|
|
|
%build
|
2023-05-03 15:20:39 +00:00
|
|
|
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
|
|
|
|
%make_build
|
2017-10-08 07:51:56 +00:00
|
|
|
|
|
|
|
%check
|
2023-05-03 15:20:39 +00:00
|
|
|
make test
|
2017-10-08 07:51:56 +00:00
|
|
|
|
|
|
|
%install
|
|
|
|
%perl_make_install
|
|
|
|
%perl_process_packlist
|
|
|
|
%perl_gen_filelist
|
|
|
|
|
|
|
|
%files -f %{name}.files
|
|
|
|
%doc Changes README
|
|
|
|
%license LICENSE
|
|
|
|
|
|
|
|
%changelog
|