[PyMca] Fix FTBFS with -Werror=format-security (#1105919)
Yaakov Selkowitz
yselkowitz at fedoraproject.org
Tue Jul 8 20:19:50 UTC 2014
commit 295d5f2b0e56fb10ec199587185c7b2453ec34f1
Author: Yaakov Selkowitz <yselkowitz at users.sourceforge.net>
Date: Wed Jun 18 23:35:12 2014 -0500
Fix FTBFS with -Werror=format-security (#1105919)
PyMca-4.5.0-format-security.patch | 13 +++++++++++++
PyMca.spec | 14 +++++++-------
2 files changed, 20 insertions(+), 7 deletions(-)
---
diff --git a/PyMca-4.5.0-format-security.patch b/PyMca-4.5.0-format-security.patch
new file mode 100644
index 0000000..b5241b7
--- /dev/null
+++ b/PyMca-4.5.0-format-security.patch
@@ -0,0 +1,13 @@
+diff --git a/PyMca/Object3D/Object3DQhull/src/io.c b/PyMca/Object3D/Object3DQhull/src/io.c
+index c219100..38d301d 100755
+--- a/PyMca/Object3D/Object3DQhull/src/io.c
++++ b/PyMca/Object3D/Object3DQhull/src/io.c
+@@ -2166,7 +2166,7 @@ void qh_printfacet3math (FILE *fp, facetT *facet, int format, int notfirst) {
+ qh_memfree (point, qh normal_size);
+ qh_settempfree(&points);
+ qh_settempfree(&vertices);
+- fprintf(fp, endfmt);
++ fprintf(fp, "%s", endfmt);
+ } /* printfacet3math */
+
+
diff --git a/PyMca.spec b/PyMca.spec
index e49f060..22b45e4 100644
--- a/PyMca.spec
+++ b/PyMca.spec
@@ -7,7 +7,7 @@
Name: PyMca
Version: 4.5.0
-Release: 5%{?dist}
+Release: 6%{?dist}
Summary: GUI for multi-channel analyser spectra visualization and analysis
Group: Applications/Engineering
License: GPLv2+
@@ -15,7 +15,7 @@ URL: http://pymca.sourceforge.net/
Source0: http://downloads.sourceforge.net/sourceforge/pymca/pymca%{version}-src.tgz
# Desktop file
Source1: PyMca.desktop
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+Patch0: PyMca-4.5.0-format-security.patch
BuildRequires: desktop-file-utils
BuildRequires: python-devel
@@ -38,6 +38,7 @@ from SPEC during acquisitions.
%prep
%setup -q -n %{name}%{version}
+%patch0 -p1
# Fix perms
chmod 644 LICENSE.GPL README
find -name *.c -exec chmod 644 {} \;
@@ -52,7 +53,6 @@ sed "s|#!python|#!%{_bindir}/python|g" -i PyMca/scripts/pymcapostbatch
echo yes | python setup.py build
%install
-rm -rf %{buildroot}
# setup.py asks for license approval
echo yes | python setup.py install -O1 --skip-build --root %{buildroot}
@@ -78,11 +78,7 @@ for lib in %{buildroot}%{python_sitearch}/PyMca/*.py; do
mv $lib.new $lib
done
-%clean
-rm -rf %{buildroot}
-
%files
-%defattr(-,root,root,-)
%doc LICENSE.GPL README
%{python_sitearch}/PyMca/
%{python_sitearch}/PyMca-%{version}-py*.egg-info
@@ -95,6 +91,10 @@ rm -rf %{buildroot}
%{_datadir}/applications/PyMca.desktop
%changelog
+* Wed Jun 18 2014 Yaakov Selkowitz <yselkowi at redhat.com> - 4.5.0-6
+- Fix FTBFS with -Werror=format-security (#1105919)
+- Cleanup spec
+
* Fri Jun 06 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 4.5.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
More information about the scm-commits
mailing list