8
0
Files
perl-Time-Local/perl-Time-Local.spec

73 lines
2.5 KiB
RPMSpec
Raw Permalink Normal View History

#
# spec file for package perl-Time-Local
#
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
# Copyright (c) 2023 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
%define cpan_name Time-Local
Name: perl-Time-Local
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
Version: 1.35
Release: 0
License: Artistic-1.0 OR GPL-1.0-or-later
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
Summary: Efficiently compute time from local and GMT time
URL: https://metacpan.org/release/%{cpan_name}
Source0: https://cpan.metacpan.org/authors/id/D/DR/DROLSKY/%{cpan_name}-%{version}.tar.gz
Source1: cpanspec.yml
2025-08-12 18:18:13 +02:00
Source100: README.md
BuildArch: noarch
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(Test::More) >= 0.96
BuildRequires: perl(parent)
Requires: perl(parent)
%{perl_requires}
%description
This module provides functions that are the inverse of built-in perl
functions 'localtime()' and 'gmtime()'. They accept a date as a six-element
array, and return the corresponding 'time(2)' value in seconds since the
system epoch (Midnight, January 1, 1970 GMT on Unix, for example). This
value can be positive or negative, though POSIX only requires support for
positive values, so dates before the system's epoch may not work on all
operating systems.
It is worth drawing particular attention to the expected ranges for the
values provided. The value for the day of the month is the actual day (i.e.
1..31), while the month is the number of months since January (0..11). This
is consistent with the values returned from 'localtime()' and 'gmtime()'.
%prep
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
%autosetup -n %{cpan_name}-%{version}
find . -type f ! -path "*/t/*" ! -name "*.pl" ! -path "*/bin/*" ! -path "*/script/*" ! -path "*/scripts/*" ! -name "configure" -print0 | xargs -0 chmod 644
%build
perl Makefile.PL INSTALLDIRS=vendor
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
%make_build
%check
make test
%install
%perl_make_install
%perl_process_packlist
%perl_gen_filelist
%files -f %{name}.files
Accepting request 1084392 from devel:languages:perl:autoupdate - updated to 1.35 see /usr/share/doc/packages/perl-Time-Local/Changes 1.35 2023-04-29 - This is the same as 1.34. - The code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.34 2023-03-25 (TRIAL RELEASE) - Fix for test failures seen on 32-bit systems with older Perl versions. 1.33 2023-02-12 (TRIAL RELEASE) - Fix for breakage on (some?) 32-bit platforms. If an integer calculation done internally overflowed all calls to this module's subs could error with "Day too big - 105412 > -2147483648". This fix reduces the range of acceptable epochs but should make the module usable again on such systems. 1.32 2023-02-12 (TRIAL RELEASE) - This is an alternative to the changes in the 1.31 release. Instead of restoring "use integer", the code now explicitly handles non-integer seconds values. This fixes the confusing things that timelocal() does with non-integer seconds but does not turn the seconds value into an integer. Based on a bug report from Dmitriy Shamatrin. GH #18. 1.31 2021-11-09 (TRIAL RELEASE) - Restored the use of "use integer", which was removed in 2010 as part of the change to support a 64-bit time_t in Perl, regardless of the platform. The timelocal() sub does very confusing things with non-integer seconds because internally it calls the system's localtime() function. And that localtime() function may strip off the non-integer portion of the seconds value. This leads to extremely confusing results because of the math that this module does on the return value of localtime() internally. With "use integer" back in effect the results are much more predictable. Based on a bug report from Dmitriy Shamatrin. GH #18. OBS-URL: https://build.opensuse.org/request/show/1084392 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Time-Local?expand=0&rev=5
2023-05-03 15:20:57 +00:00
%doc Changes CODE_OF_CONDUCT.md CONTRIBUTING.md README.md
%license LICENSE
%changelog