[tar] fix build failure with undefined gets
Ondrej Vasik
ovasik at fedoraproject.org
Sat Jun 16 06:01:18 UTC 2012
commit 09e641387746ca82db25a7dae90d384edd144416
Author: Ondřej Vašík <ovasik at redhat.com>
Date: Sat Jun 16 07:57:33 2012 +0200
fix build failure with undefined gets
tar-1.26-stdio.in.patch | 13 +++++++++++++
tar.spec | 4 ++++
2 files changed, 17 insertions(+), 0 deletions(-)
---
diff --git a/tar-1.26-stdio.in.patch b/tar-1.26-stdio.in.patch
new file mode 100644
index 0000000..a687592
--- /dev/null
+++ b/tar-1.26-stdio.in.patch
@@ -0,0 +1,13 @@
+diff -urNp tar-1.26-orig/gnu/stdio.in.h tar-1.26/gnu/stdio.in.h
+--- tar-1.26-orig/gnu/stdio.in.h
++++ tar-1.26/gnu/stdio.in.h
+@@ -139,7 +139,9 @@ _GL_WARN_ON_USE (fflush, "fflush is not
+ so any use of gets warrants an unconditional warning. Assume it is
+ always declared, since it is required by C89. */
+ #undef gets
++#if HAVE_RAW_DECL_GETS
+ _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
++#endif
+
+ #if @GNULIB_FOPEN@
+ # if @REPLACE_FOPEN@
diff --git a/tar.spec b/tar.spec
index 2e25c95..06cb0ce 100644
--- a/tar.spec
+++ b/tar.spec
@@ -34,6 +34,8 @@ Patch7: tar-sigpipe.patch
Patch8: tar-1.24-openat-partial-revert.patch
# fix for bad cooperation of -C and -u options (#688567)
Patch9: tar-1.26-update-with-change-directory.patch
+# fix rawhide buildfailure with undefined gets
+Patch10: tar-1.26-stdio.in.patch
BuildRequires: autoconf automake gzip texinfo gettext libacl-devel gawk rsh
%if %{WITH_SELINUX}
BuildRequires: libselinux-devel
@@ -66,6 +68,7 @@ the rmt package.
%patch7 -p1 -b .fail
%patch8 -p1 -b .openat
%patch9 -p1 -b .update_and_changedir
+%patch10 -p1 -b .gets
autoreconf
@@ -130,6 +133,7 @@ fi
* Sat Jun 16 2012 Ondrej Vasik <ovasik at redhat.com> 2:1.26-7
- store&restore security.capability extended attributes category
(#771927)
+- fix build failure with undefined gets
* Tue May 15 2012 Ondrej Vasik <ovasik at redhat.com> 2:1.26-6
- add virtual provides for bundled(gnulib) copylib (#821790)
More information about the scm-commits
mailing list