package init
This commit is contained in:
parent
620874f6a9
commit
d823d90077
81
0001-fix-building-error.patch
Normal file
81
0001-fix-building-error.patch
Normal file
@ -0,0 +1,81 @@
|
|||||||
|
From cc0990a7923c40a163d75fa99f046b3759651558 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Your Name <you@example.com>
|
||||||
|
Date: Thu, 7 May 2020 13:31:04 +0800
|
||||||
|
Subject: [PATCH 2/2] 2
|
||||||
|
|
||||||
|
---
|
||||||
|
src/common/collator.cpp | 2 ++
|
||||||
|
src/common/collator.h | 2 ++
|
||||||
|
src/model/process_sort_filter_proxy_model.cpp | 4 ++--
|
||||||
|
src/model/system_service_sort_filter_proxy_model.cpp | 2 +-
|
||||||
|
4 files changed, 7 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/common/collator.cpp b/src/common/collator.cpp
|
||||||
|
index 14a98fa..9c6f11c 100644
|
||||||
|
--- a/src/common/collator.cpp
|
||||||
|
+++ b/src/common/collator.cpp
|
||||||
|
@@ -2,6 +2,7 @@
|
||||||
|
|
||||||
|
#include "collator.h"
|
||||||
|
|
||||||
|
+namespace Common {
|
||||||
|
std::atomic<Collator *> Collator::m_instance;
|
||||||
|
std::mutex Collator::m_mutex;
|
||||||
|
|
||||||
|
@@ -48,3 +49,4 @@ Collator::~Collator()
|
||||||
|
{
|
||||||
|
delete m_collator;
|
||||||
|
}
|
||||||
|
+}
|
||||||
|
diff --git a/src/common/collator.h b/src/common/collator.h
|
||||||
|
index ceeb67c..88d08d5 100644
|
||||||
|
--- a/src/common/collator.h
|
||||||
|
+++ b/src/common/collator.h
|
||||||
|
@@ -12,6 +12,7 @@
|
||||||
|
|
||||||
|
#include <QString>
|
||||||
|
|
||||||
|
+namespace Common {
|
||||||
|
class Collator
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
@@ -41,4 +42,5 @@ private:
|
||||||
|
static std::mutex m_mutex;
|
||||||
|
};
|
||||||
|
|
||||||
|
+}
|
||||||
|
#endif // COLLATOR_H
|
||||||
|
diff --git a/src/model/process_sort_filter_proxy_model.cpp b/src/model/process_sort_filter_proxy_model.cpp
|
||||||
|
index f2c3d4a..82f86db 100644
|
||||||
|
--- a/src/model/process_sort_filter_proxy_model.cpp
|
||||||
|
+++ b/src/model/process_sort_filter_proxy_model.cpp
|
||||||
|
@@ -77,11 +77,11 @@ bool ProcessSortFilterProxyModel::lessThan(const QModelIndex &left, const QModel
|
||||||
|
} else {
|
||||||
|
QString lname = left.data(Qt::DisplayRole).toString();
|
||||||
|
QString rname = right.data(Qt::DisplayRole).toString();
|
||||||
|
- return Collator::instance()->compare(lname, rname) < 0;
|
||||||
|
+ return Common::Collator::instance()->compare(lname, rname) < 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case ProcessTableModel::kProcessUserColumn: {
|
||||||
|
- return Collator::instance()->compare(left.data(Qt::DisplayRole).toString(),
|
||||||
|
+ return Common::Collator::instance()->compare(left.data(Qt::DisplayRole).toString(),
|
||||||
|
right.data(Qt::DisplayRole).toString()) < 0;
|
||||||
|
}
|
||||||
|
case ProcessTableModel::kProcessMemoryColumn: {
|
||||||
|
diff --git a/src/model/system_service_sort_filter_proxy_model.cpp b/src/model/system_service_sort_filter_proxy_model.cpp
|
||||||
|
index 515a2a4..ae1e019 100644
|
||||||
|
--- a/src/model/system_service_sort_filter_proxy_model.cpp
|
||||||
|
+++ b/src/model/system_service_sort_filter_proxy_model.cpp
|
||||||
|
@@ -41,7 +41,7 @@ bool SystemServiceSortFilterProxyModel::lessThan(const QModelIndex &left,
|
||||||
|
return left.data().toUInt() < right.data().toUInt();
|
||||||
|
case SystemServiceTableModel::kSystemServiceNameColumn:
|
||||||
|
case SystemServiceTableModel::kSystemServiceDescriptionColumn: {
|
||||||
|
- return Collator::instance()->compare(left.data(Qt::DisplayRole).toString(),
|
||||||
|
+ return Common::Collator::instance()->compare(left.data(Qt::DisplayRole).toString(),
|
||||||
|
right.data(Qt::DisplayRole).toString()) < 0;
|
||||||
|
}
|
||||||
|
default:
|
||||||
|
--
|
||||||
|
2.18.2
|
||||||
|
|
||||||
32
deepin-system-monitor-appdata.xml
Normal file
32
deepin-system-monitor-appdata.xml
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!-- Copyright 2017 mosquito -->
|
||||||
|
<component type="desktop">
|
||||||
|
<id>deepin-system-monitor.desktop</id>
|
||||||
|
<metadata_license>CC0-1.0</metadata_license>
|
||||||
|
<name>Deepin System Monitor</name>
|
||||||
|
<name xml:lang="zh_CN">深度系统监视器</name>
|
||||||
|
<name xml:lang="zh_TW">深度系统监视器</name>
|
||||||
|
<summary>Deepin System Monitor is Deepin Desktop Environment system monitor</summary>
|
||||||
|
<summary xml:lang="zh_CN">深度系统监视器是一个免费开源的跨平台系统性能监视工具</summary>
|
||||||
|
<summary xml:lang="zh_TW">深度系统监视器是一个免费开源的跨平台系统性能监视工具</summary>
|
||||||
|
<description>
|
||||||
|
<p>
|
||||||
|
Deepin System Monitor is a free and open source cross-platform system monitor tool.
|
||||||
|
</p>
|
||||||
|
<p xml:lang="zh_CN">
|
||||||
|
深度系统监视器是一个免费开源的跨平台系统性能监视工具。
|
||||||
|
</p>
|
||||||
|
</description>
|
||||||
|
<url type="homepage">https://github.com/linuxdeepin/deepin-system-monitor/</url>
|
||||||
|
<url type="bugtracker">https://github.com/linuxdeepin/deepin-system-monitor/issues/</url>
|
||||||
|
<releases>
|
||||||
|
<release version="1.3" date="2017-08-11"></release>
|
||||||
|
</releases>
|
||||||
|
<project_license>GPL-3.0</project_license>
|
||||||
|
<developer_name>Linux Deepin</developer_name>
|
||||||
|
<screenshots>
|
||||||
|
<screenshot type="default">http://api.lastore.deepin.org/static/deepin-system-monitor/meta/screenshots/zh_CN/phpCsoD79.png</screenshot>
|
||||||
|
<screenshot type="default">http://api.lastore.deepin.org/static/deepin-system-monitor/meta/screenshots/zh_CN/php0vAbT7.png</screenshot>
|
||||||
|
<screenshot type="default">http://api.lastore.deepin.org/static/deepin-system-monitor/meta/screenshots/zh_CN/phpSZvurm.png</screenshot>
|
||||||
|
</screenshots>
|
||||||
|
</component>
|
||||||
123
deepin-system-monitor.spec
Normal file
123
deepin-system-monitor.spec
Normal file
@ -0,0 +1,123 @@
|
|||||||
|
Name: deepin-system-monitor
|
||||||
|
Version: 5.6.1
|
||||||
|
Release: 1
|
||||||
|
Summary: A more user-friendly system monitor
|
||||||
|
License: GPLv3
|
||||||
|
URL: https://github.com/linuxdeepin/deepin-system-monitor
|
||||||
|
Source0: %{name}_%{version}.orig.tar.xz
|
||||||
|
Source1: %{name}-appdata.xml
|
||||||
|
Patch0: 0001-fix-building-error.patch
|
||||||
|
|
||||||
|
BuildRequires: dtkwidget-devel >= 5.1
|
||||||
|
#BuildRequires: pkgconfig(dtkwm) >= 2.0
|
||||||
|
BuildRequires: pkgconfig(libprocps)
|
||||||
|
BuildRequires: pkgconfig(xcb)
|
||||||
|
BuildRequires: pkgconfig(xcb-util)
|
||||||
|
BuildRequires: pkgconfig(x11)
|
||||||
|
BuildRequires: pkgconfig(xext)
|
||||||
|
BuildRequires: pkgconfig(xtst)
|
||||||
|
BuildRequires: pkgconfig(Qt5DBus)
|
||||||
|
BuildRequires: pkgconfig(Qt5Gui)
|
||||||
|
BuildRequires: pkgconfig(Qt5Network)
|
||||||
|
BuildRequires: pkgconfig(Qt5Widgets)
|
||||||
|
BuildRequires: pkgconfig(Qt5X11Extras)
|
||||||
|
BuildRequires: qt5-linguist
|
||||||
|
BuildRequires: libpcap-devel
|
||||||
|
BuildRequires: libcap-devel
|
||||||
|
BuildRequires: ncurses-devel
|
||||||
|
BuildRequires: desktop-file-utils
|
||||||
|
BuildRequires: libappstream-glib
|
||||||
|
BuildRequires: deepin-gettext-tools
|
||||||
|
BuildRequires: dtkwm-devel
|
||||||
|
BuildRequires: qt5-qtmultimedia-devel
|
||||||
|
BuildRequires: dtkcore-devel >= 5.1
|
||||||
|
BuildRequires: libicu-devel
|
||||||
|
Requires: hicolor-icon-theme
|
||||||
|
Recommends: deepin-manual
|
||||||
|
|
||||||
|
%description
|
||||||
|
%{summary}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q
|
||||||
|
####sed -i 's|lrelease|lrelease-qt5|' translations/translate_generation.sh
|
||||||
|
|
||||||
|
%patch0 -p1
|
||||||
|
|
||||||
|
%build
|
||||||
|
export PATH=$PATH:/usr/lib64/qt5/bin
|
||||||
|
%qmake_qt5 PREFIX=%{_prefix}
|
||||||
|
%make_build
|
||||||
|
|
||||||
|
%install
|
||||||
|
%make_install INSTALL_ROOT=%{buildroot}
|
||||||
|
install -Dm644 %SOURCE1 %{buildroot}%{_datadir}/appdata/%{name}.appdata.xml
|
||||||
|
|
||||||
|
%check
|
||||||
|
desktop-file-validate %{buildroot}%{_datadir}/applications/%{name}.desktop ||:
|
||||||
|
#appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/*.appdata.xml
|
||||||
|
|
||||||
|
%files
|
||||||
|
%doc README.md
|
||||||
|
%license LICENSE
|
||||||
|
%caps(cap_kill,cap_net_raw,cap_dac_read_search,cap_sys_ptrace=+ep) %{_bindir}/%{name}
|
||||||
|
%{_datadir}/appdata/%{name}.appdata.xml
|
||||||
|
%{_datadir}/applications/%{name}.desktop
|
||||||
|
%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
|
||||||
|
%{_datadir}/%{name}/
|
||||||
|
%{_datadir}/polkit-1/actions/com.deepin.pkexec.deepin-system-monitor.policy
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Mon Aug 05 2019 Robin Lee <cheeselee@fedoraproject.org> - 5.0.0-1
|
||||||
|
- Release 5.0.0
|
||||||
|
|
||||||
|
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.8.1-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jan 31 2019 mosquito <sensor.wen@gmail.com> - 1.4.8.1-1
|
||||||
|
- Update to 1.4.8.1
|
||||||
|
|
||||||
|
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.8-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Nov 29 2018 mosquito <sensor.wen@gmail.com> - 1.4.8-1
|
||||||
|
- Update to 1.4.8
|
||||||
|
|
||||||
|
* Fri Nov 9 2018 mosquito <sensor.wen@gmail.com> - 1.4.7-1
|
||||||
|
- Update to 1.4.7
|
||||||
|
|
||||||
|
* Sat Aug 25 2018 mosquito <sensor.wen@gmail.com> - 1.4.6-1
|
||||||
|
- Update to 1.4.6
|
||||||
|
|
||||||
|
* Fri Jul 27 2018 mosquito <sensor.wen@gmail.com> - 1.4.5-1
|
||||||
|
- Update to 1.4.5
|
||||||
|
|
||||||
|
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.7-5
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jun 14 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.3.7-4
|
||||||
|
- Rebuild for procps-ng-3.3.15
|
||||||
|
|
||||||
|
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.7-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jan 11 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.3.7-2
|
||||||
|
- Remove obsolete scriptlets
|
||||||
|
|
||||||
|
* Mon Nov 27 2017 mosquito <sensor.wen@gmail.com> - 1.3.7-1
|
||||||
|
- Update to 1.3.7
|
||||||
|
|
||||||
|
* Mon Oct 23 2017 mosquito <sensor.wen@gmail.com> - 1.3.5-1
|
||||||
|
- Update to 1.3.5
|
||||||
|
|
||||||
|
* Tue Oct 17 2017 mosquito <sensor.wen@gmail.com> - 1.3.1-1
|
||||||
|
- Update to 1.3.1
|
||||||
|
|
||||||
|
* Sun Aug 20 2017 mosquito <sensor.wen@gmail.com> - 1.3-1
|
||||||
|
- Update to 1.3
|
||||||
|
|
||||||
|
* Tue Aug 1 2017 mosquito <sensor.wen@gmail.com> - 1.0.2-1
|
||||||
|
- Update to 1.0.2
|
||||||
|
|
||||||
|
* Sat Jul 15 2017 mosquito <sensor.wen@gmail.com> - 0.0.4-1.gita73357d
|
||||||
|
- Initial build
|
||||||
BIN
deepin-system-monitor_5.6.1.orig.tar.xz
Normal file
BIN
deepin-system-monitor_5.6.1.orig.tar.xz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user