From fddddb3a48e236c6733383112f00b4fe6768a558 Mon Sep 17 00:00:00 2001 From: David Abdurachmanov Date: Tue, 13 Sep 2022 17:12:19 +0300 Subject: [PATCH] Disable GUI on riscv64 Temporary change. Signed-off-by: David Abdurachmanov --- cppcheck.spec | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/cppcheck.spec b/cppcheck.spec index 4d2495b..b07130e 100644 --- a/cppcheck.spec +++ b/cppcheck.spec @@ -2,7 +2,7 @@ Name: cppcheck Version: 2.9 -Release: 1%{?dist} +Release: 1.0.riscv64%{?dist} Summary: Tool for static C/C++ code analysis License: GPLv3+ URL: http://cppcheck.wiki.sourceforge.net/ @@ -24,9 +24,11 @@ BuildRequires: tinyxml2-devel >= 2.1.0 BuildRequires: zlib-devel BuildRequires: python3-devel BuildRequires: python3-setuptools +%ifnarch riscv64 BuildRequires: qt5-qtbase-devel BuildRequires: qt5-qttools-devel BuildRequires: qt5-linguist +%endif BuildRequires: make @@ -37,12 +39,14 @@ errors in the code. Cppcheck primarily detects the types of bugs that the compilers normally do not detect. The goal is to detect only real errors in the code (i.e. have zero false positives). +%ifnarch riscv64 %package gui Summary: Graphical user interface for cppcheck Requires: %{name}%{?_isa} = %{version}-%{release} %description gui This package contains the graphical user interface for cppcheck. +%endif %package htmlreport Summary: HTML reporting for cppcheck @@ -60,8 +64,10 @@ from xml files first generated using cppcheck. # Make sure bundled tinyxml2 is not used rm -r externals/tinyxml2 # Generate the Qt online-help file +%ifnarch riscv64 cd gui/help qhelpgenerator-qt5 online-help.qhcp -o online-help.qhc +%endif %build # Manuals @@ -78,6 +84,7 @@ pandoc man/reference-cfg-format.md -o man/reference-cfg-format.html -s --number- rm -rf %{buildroot} %cmake_install install -D -p -m 644 cppcheck.1 %{buildroot}%{_mandir}/man1/cppcheck.1 +%ifnarch riscv64 # Install desktop file desktop-file-validate %{buildroot}%{_datadir}/applications/cppcheck-gui.desktop # Install logo @@ -85,6 +92,7 @@ install -D -p -m 644 gui/cppcheck-gui.png %{buildroot}%{_datadir}/pixmaps/cppche # Install the Qt online-help file install -D -p -m 644 gui/help/online-help.qhc %{buildroot}%{_datadir}/Cppcheck/help/online-help.qhc install -D -p -m 644 gui/help/online-help.qch %{buildroot}%{_datadir}/Cppcheck/help/online-help.qch +%endif # Install htmlreport install -D -p -m 755 htmlreport/cppcheck-htmlreport %{buildroot}%{_bindir}/cppcheck-htmlreport # Restore execute permission of python files @@ -101,17 +109,22 @@ cd %{_vpath_builddir}/bin %{_bindir}/cppcheck %{_mandir}/man1/cppcheck.1* +%ifnarch riscv64 %files gui %{_bindir}/cppcheck-gui %{_datadir}/applications/cppcheck-gui.desktop %{_datadir}/pixmaps/cppcheck-gui.png %{_datadir}/icons/hicolor/64x64/apps/cppcheck-gui.png %{_datadir}/icons/hicolor/scalable/apps/cppcheck-gui.svg +%endif %files htmlreport %{_bindir}/cppcheck-htmlreport %changelog +* Tue Sep 13 2022 David Abdurachmanov - 2.9-1.0.riscv64 +- Disable QT based GUI on riscv64 + * Sun Aug 28 2022 Wolfgang Stöggl - 2.9-1 - Update to 2.9