[cppcheck/el6] Fix build on EPEL-4.
Jussi Lehtola
jussilehtola at fedoraproject.org
Fri Aug 19 09:12:35 UTC 2011
commit 33a1c66ecff8b6c99f4b4fc9ce2d779781b02757
Author: Jussi Lehtola <jussilehtola at fedoraproject.org>
Date: Fri Aug 19 12:12:19 2011 +0300
Fix build on EPEL-4.
cppcheck.spec | 13 ++++++++++++-
1 files changed, 12 insertions(+), 1 deletions(-)
---
diff --git a/cppcheck.spec b/cppcheck.spec
index c9f6b28..48beeb0 100644
--- a/cppcheck.spec
+++ b/cppcheck.spec
@@ -1,6 +1,6 @@
Name: cppcheck
Version: 1.50
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: A tool for static C/C++ code analysis
Group: Development/Languages
License: GPLv3+
@@ -33,14 +33,22 @@ rm -r externals/tinyxml
%build
# TINYXML= prevents use of bundled tinyxml
+%if 0%{?rhel} == 4
+make CXXFLAGS="%{optflags} -I%{_includedir}/pcre -DNDEBUG -DHAVE_RULES" TINYXML= LDFLAGS="-ltinyxml -lpcre" %{?_smp_mflags}
+%else
make CXXFLAGS="%{optflags} -DNDEBUG -DHAVE_RULES" TINYXML= LDFLAGS="-ltinyxml -lpcre" %{?_smp_mflags}
+%endif
%install
rm -rf %{buildroot}
install -D -p -m 755 cppcheck %{buildroot}%{_bindir}/cppcheck
%check
+%if 0%{?rhel} == 4
+make CXXFLAGS="%{optflags} -I%{_includedir}/pcre -DNDEBUG -DHAVE_RULES" TINYXML= LDFLAGS="-ltinyxml -lpcre" %{?_smp_mflags} check
+%else
make CXXFLAGS="%{optflags} -DNDEBUG -DHAVE_RULES" TINYXML= LDFLAGS="-ltinyxml -lpcre" %{?_smp_mflags} check
+%endif
%clean
rm -rf %{buildroot}
@@ -51,6 +59,9 @@ rm -rf %{buildroot}
%{_bindir}/cppcheck
%changelog
+* Fri Aug 19 2011 Jussi Lehtola <jussilehtola at fedoraproject.org> - 1.50-2
+- Fix build on EPEL-4.
+
* Sun Aug 14 2011 Jussi Lehtola <jussilehtola at fedoraproject.org> - 1.50-1
- Update to 1.50.
More information about the scm-commits
mailing list