Fix FTBFS due to false detection of strlcpy() and _getpty()
https://github.com/toddr/IO-Tty/pull/24 Modernize spec using %{make_build} and %{make_install}
This commit is contained in:
parent
f64ec0bee3
commit
6bdeb47bf6
28
0001-Make-function-tests-more-robust.patch
Normal file
28
0001-Make-function-tests-more-robust.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From 1747cdf9f98cfd3aada9bf6c09f9d46297e18a5e Mon Sep 17 00:00:00 2001
|
||||
From: Paul Howarth <paul@city-fan.org>
|
||||
Date: Sat, 22 Aug 2020 13:16:00 +0100
|
||||
Subject: [PATCH] Make function tests more robust
|
||||
|
||||
Actually try calling the function rather than just referencing it.
|
||||
This prevents some false-positive function detections, such as seen in
|
||||
https://github.com/toddr/IO-Tty/issues/23
|
||||
---
|
||||
Makefile.PL | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.PL b/Makefile.PL
|
||||
index 3ff081b..25824d1 100644
|
||||
--- a/Makefile.PL
|
||||
+++ b/Makefile.PL
|
||||
@@ -160,7 +160,7 @@ main ()
|
||||
#if defined (__stub_$f) || defined (__stub___$f)
|
||||
choke me
|
||||
#else
|
||||
-f = $f;
|
||||
+f = $f ();
|
||||
#endif
|
||||
|
||||
;
|
||||
--
|
||||
2.26.2
|
||||
|
||||
@ -1,10 +1,11 @@
|
||||
Name: perl-IO-Tty
|
||||
Version: 1.14
|
||||
Release: 4%{?dist}
|
||||
Release: 5%{?dist}
|
||||
Summary: Perl interface to pseudo tty's
|
||||
License: (GPL+ or Artistic) and BSD
|
||||
URL: https://metacpan.org/release/IO-Tty
|
||||
Source0: https://cpan.metacpan.org/modules/by-module/IO/IO-Tty-%{version}.tar.gz
|
||||
Patch0: 0001-Make-function-tests-more-robust.patch
|
||||
# Module Build
|
||||
BuildRequires: coreutils
|
||||
BuildRequires: findutils
|
||||
@ -16,7 +17,7 @@ BuildRequires: perl-interpreter
|
||||
BuildRequires: perl(Config)
|
||||
BuildRequires: perl(Cwd)
|
||||
BuildRequires: perl(Exporter)
|
||||
BuildRequires: perl(ExtUtils::MakeMaker)
|
||||
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76
|
||||
# Module Runtime
|
||||
BuildRequires: perl(Carp)
|
||||
BuildRequires: perl(DynaLoader)
|
||||
@ -40,13 +41,16 @@ IO::Tty and IO::Pty provide an interface to pseudo tty's.
|
||||
%prep
|
||||
%setup -q -n IO-Tty-%{version}
|
||||
|
||||
# Prevent false-positive detection of functions, e.g strlcpy() and _getpty()
|
||||
# https://github.com/toddr/IO-Tty/pull/24
|
||||
%patch0 -p1
|
||||
|
||||
%build
|
||||
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
|
||||
make %{?_smp_mflags}
|
||||
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}" NO_PACKLIST=1 NO_PERLLOCAL=1
|
||||
%{make_build}
|
||||
|
||||
%install
|
||||
make pure_install DESTDIR=%{buildroot}
|
||||
find %{buildroot} -type f -name .packlist -delete
|
||||
%{make_install}
|
||||
find %{buildroot} -type f -name '*.bs' -empty -delete
|
||||
%{_fixperms} -c %{buildroot}
|
||||
|
||||
@ -62,6 +66,11 @@ make test
|
||||
%{_mandir}/man3/IO::Tty::Constant.3*
|
||||
|
||||
%changelog
|
||||
* Sat Aug 22 2020 Paul Howarth <paul@city-fan.org> - 1.14-5
|
||||
- Fix FTBFS due to false detection of strlcpy() and _getpty()
|
||||
https://github.com/toddr/IO-Tty/pull/24
|
||||
- Modernize spec using %%{make_build} and %%{make_install}
|
||||
|
||||
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.14-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user