[f2c] Fix FTBFS with -Werror=format-security (#1037057, #1106245)

Yaakov Selkowitz yselkowitz at fedoraproject.org
Mon Jul 7 23:51:21 UTC 2014


commit 6388b45aff9991f7eab253036eb28fa2a5621db6
Author: Yaakov Selkowitz <yselkowitz at users.sourceforge.net>
Date:   Fri Jun 13 12:24:22 2014 -0500

    Fix FTBFS with -Werror=format-security (#1037057, #1106245)

 f2c.spec                              |    7 ++++++-
 libf2c-20110801-format-security.patch |   13 +++++++++++++
 2 files changed, 19 insertions(+), 1 deletions(-)
---
diff --git a/f2c.spec b/f2c.spec
index 93eac08..719e437 100644
--- a/f2c.spec
+++ b/f2c.spec
@@ -1,13 +1,14 @@
 Name:           f2c
 Summary:        A Fortran 77 to C/C++ conversion program
 Version:        20110801
-Release:        5%{?dist}
+Release:        6%{?dist}
 License:        MIT
 Group:          Development/Languages
 URL:            http://netlib.org/f2c/
 Source:         ftp://netlib.org/f2c.tar
 # Patch makefile to build a shared library
 Patch:          f2c-20110801.patch
+Patch1:         libf2c-20110801-format-security.patch
 BuildRequires:  unzip
 BuildRoot:      %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 Requires:       %{name}-libs = %{version}-%{release}
@@ -32,6 +33,7 @@ pushd libf2c
 unzip ../libf2c.zip
 popd
 %patch
+%patch1 -p1
 
 %build
 cp src/makefile.u src/Makefile
@@ -70,6 +72,9 @@ rm -rf %{buildroot}
 
 
 %changelog
+* Fri Jun 13 2014 Yaakov Selkowitz <yselkowi at redhat.com> - 20110801-6
+- Fix FTBFS with -Werror=format-security (#1037057, #1106245)
+
 * Sat Jun 07 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 20110801-5
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
 
diff --git a/libf2c-20110801-format-security.patch b/libf2c-20110801-format-security.patch
new file mode 100644
index 0000000..d6501b9
--- /dev/null
+++ b/libf2c-20110801-format-security.patch
@@ -0,0 +1,13 @@
+diff --git a/libf2c/arithchk.c b/libf2c/arithchk.c
+index 8e15722..a1a03ac 100644
+--- a/libf2c/arithchk.c
++++ b/libf2c/arithchk.c
+@@ -110,7 +110,7 @@ icheck(void)
+ 	return 0;
+ 	}
+ 
+-char *emptyfmt = "";	/* avoid possible warning message with printf("") */
++const char emptyfmt[] = "";	/* avoid possible warning message with printf("") */
+ 
+  static Akind *
+ ccheck(void)


More information about the scm-commits mailing list