Disable GUI on riscv64

Temporary change.

Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
This commit is contained in:
David Abdurachmanov 2022-09-13 17:12:19 +03:00
parent c375328a31
commit fddddb3a48
Signed by: davidlt
GPG Key ID: 8B7F1DA0E2C9FDBB
1 changed files with 14 additions and 1 deletions

View File

@ -2,7 +2,7 @@
Name: cppcheck Name: cppcheck
Version: 2.9 Version: 2.9
Release: 1%{?dist} Release: 1.0.riscv64%{?dist}
Summary: Tool for static C/C++ code analysis Summary: Tool for static C/C++ code analysis
License: GPLv3+ License: GPLv3+
URL: http://cppcheck.wiki.sourceforge.net/ URL: http://cppcheck.wiki.sourceforge.net/
@ -24,9 +24,11 @@ BuildRequires: tinyxml2-devel >= 2.1.0
BuildRequires: zlib-devel BuildRequires: zlib-devel
BuildRequires: python3-devel BuildRequires: python3-devel
BuildRequires: python3-setuptools BuildRequires: python3-setuptools
%ifnarch riscv64
BuildRequires: qt5-qtbase-devel BuildRequires: qt5-qtbase-devel
BuildRequires: qt5-qttools-devel BuildRequires: qt5-qttools-devel
BuildRequires: qt5-linguist BuildRequires: qt5-linguist
%endif
BuildRequires: make 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 the compilers normally do not detect. The goal is to detect only real
errors in the code (i.e. have zero false positives). errors in the code (i.e. have zero false positives).
%ifnarch riscv64
%package gui %package gui
Summary: Graphical user interface for cppcheck Summary: Graphical user interface for cppcheck
Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}%{?_isa} = %{version}-%{release}
%description gui %description gui
This package contains the graphical user interface for cppcheck. This package contains the graphical user interface for cppcheck.
%endif
%package htmlreport %package htmlreport
Summary: HTML reporting for cppcheck Summary: HTML reporting for cppcheck
@ -60,8 +64,10 @@ from xml files first generated using cppcheck.
# Make sure bundled tinyxml2 is not used # Make sure bundled tinyxml2 is not used
rm -r externals/tinyxml2 rm -r externals/tinyxml2
# Generate the Qt online-help file # Generate the Qt online-help file
%ifnarch riscv64
cd gui/help cd gui/help
qhelpgenerator-qt5 online-help.qhcp -o online-help.qhc qhelpgenerator-qt5 online-help.qhcp -o online-help.qhc
%endif
%build %build
# Manuals # Manuals
@ -78,6 +84,7 @@ pandoc man/reference-cfg-format.md -o man/reference-cfg-format.html -s --number-
rm -rf %{buildroot} rm -rf %{buildroot}
%cmake_install %cmake_install
install -D -p -m 644 cppcheck.1 %{buildroot}%{_mandir}/man1/cppcheck.1 install -D -p -m 644 cppcheck.1 %{buildroot}%{_mandir}/man1/cppcheck.1
%ifnarch riscv64
# Install desktop file # Install desktop file
desktop-file-validate %{buildroot}%{_datadir}/applications/cppcheck-gui.desktop desktop-file-validate %{buildroot}%{_datadir}/applications/cppcheck-gui.desktop
# Install logo # 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 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.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 install -D -p -m 644 gui/help/online-help.qch %{buildroot}%{_datadir}/Cppcheck/help/online-help.qch
%endif
# Install htmlreport # Install htmlreport
install -D -p -m 755 htmlreport/cppcheck-htmlreport %{buildroot}%{_bindir}/cppcheck-htmlreport install -D -p -m 755 htmlreport/cppcheck-htmlreport %{buildroot}%{_bindir}/cppcheck-htmlreport
# Restore execute permission of python files # Restore execute permission of python files
@ -101,17 +109,22 @@ cd %{_vpath_builddir}/bin
%{_bindir}/cppcheck %{_bindir}/cppcheck
%{_mandir}/man1/cppcheck.1* %{_mandir}/man1/cppcheck.1*
%ifnarch riscv64
%files gui %files gui
%{_bindir}/cppcheck-gui %{_bindir}/cppcheck-gui
%{_datadir}/applications/cppcheck-gui.desktop %{_datadir}/applications/cppcheck-gui.desktop
%{_datadir}/pixmaps/cppcheck-gui.png %{_datadir}/pixmaps/cppcheck-gui.png
%{_datadir}/icons/hicolor/64x64/apps/cppcheck-gui.png %{_datadir}/icons/hicolor/64x64/apps/cppcheck-gui.png
%{_datadir}/icons/hicolor/scalable/apps/cppcheck-gui.svg %{_datadir}/icons/hicolor/scalable/apps/cppcheck-gui.svg
%endif
%files htmlreport %files htmlreport
%{_bindir}/cppcheck-htmlreport %{_bindir}/cppcheck-htmlreport
%changelog %changelog
* Tue Sep 13 2022 David Abdurachmanov <davidlt@rivosinc.com> - 2.9-1.0.riscv64
- Disable QT based GUI on riscv64
* Sun Aug 28 2022 Wolfgang Stöggl <c72578@yahoo.de> - 2.9-1 * Sun Aug 28 2022 Wolfgang Stöggl <c72578@yahoo.de> - 2.9-1
- Update to 2.9 - Update to 2.9