aboutsummaryrefslogtreecommitdiff
path: root/benchmarks
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2021-07-23 11:15:32 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2021-07-23 11:15:42 +0000
commit8c256a205fa0cf4805f51040a1a6d10af3b48ca9 (patch)
tree56a1b28375280cbc5c9c4ef31617d1ca93710d06 /benchmarks
parentc1a14b441f38e3fc8f713bb3f75e24d1be6eb198 (diff)
downloadports-8c256a205fa0cf4805f51040a1a6d10af3b48ca9.tar.gz
ports-8c256a205fa0cf4805f51040a1a6d10af3b48ca9.zip
benchmarks/kdiskmark: the port had been updated (+)
- Update KDiskMark to version 2.2.1 - Make cache clearing and KDE dependency optional - Amend port description and add pkg-help file Reported by: portscout
Diffstat (limited to 'benchmarks')
-rw-r--r--benchmarks/kdiskmark/Makefile18
-rw-r--r--benchmarks/kdiskmark/distinfo6
-rw-r--r--benchmarks/kdiskmark/files/patch-src_diskdriveinfo.cpp40
-rw-r--r--benchmarks/kdiskmark/pkg-descr6
-rw-r--r--benchmarks/kdiskmark/pkg-help5
-rw-r--r--benchmarks/kdiskmark/pkg-plist9
6 files changed, 32 insertions, 52 deletions
diff --git a/benchmarks/kdiskmark/Makefile b/benchmarks/kdiskmark/Makefile
index f85b77a86154..afb88f70ef69 100644
--- a/benchmarks/kdiskmark/Makefile
+++ b/benchmarks/kdiskmark/Makefile
@@ -1,7 +1,7 @@
# Created by: Alexey Dokuchaev <danfe@FreeBSD.org>
-PORTNAME= kdiskmark
-PORTVERSION= 2.2.0
+PORTNAME= ${GH_PROJECT:tl}
+PORTVERSION= 2.2.1
CATEGORIES= benchmarks
MAINTAINER= danfe@FreeBSD.org
@@ -18,7 +18,19 @@ GH_PROJECT= KDiskMark
USES= cmake compiler:c++11-lang kde:5 qt:5
USE_QT= buildtools_build linguisttools_build qmake_build \
core gui widgets
-USE_KDE= ecm_build auth coreaddons
+USE_KDE= ecm_build
+
+OPTIONS_DEFINE= CLEARCACHE KF5AUTH
+KF5AUTH_IMPLIES= CLEARCACHE
+OPTIONS_SUB= yes
+
+CLEARCACHE_DESC= Cache clearing functionality
+KF5AUTH_DESC= KF5Auth cache clearing helper
+
+CLEARCACHE_CMAKE_OFF= -DBUILD_WITH_PAGECACHE_CLEARING_SUPPORT:BOOL=OFF
+
+KF5AUTH_CMAKE_OFF= -DPERFORM_PAGECACHE_CLEARING_USING_KF5AUTH:BOOL=OFF
+KF5AUTH_USE= KDE=auth,coreaddons
post-patch:
@${REINPLACE_CMD} -e '/--ioengine=/s,libaio,posixaio,' \
diff --git a/benchmarks/kdiskmark/distinfo b/benchmarks/kdiskmark/distinfo
index 7908ba9b2ee4..0d50c7fc76ae 100644
--- a/benchmarks/kdiskmark/distinfo
+++ b/benchmarks/kdiskmark/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1613729258
-SHA256 (JonMagon-KDiskMark-2.2.0_GH0.tar.gz) = f778dd8422ebbeff07d335284a0fd658fc581a87d4a8e07a1c3c7e17dfbe6d3c
-SIZE (JonMagon-KDiskMark-2.2.0_GH0.tar.gz) = 232843
+TIMESTAMP = 1626939014
+SHA256 (JonMagon-KDiskMark-2.2.1_GH0.tar.gz) = 52a49b983284bca8a11c5238809a29c9967ff7a6d7a0adc5ee76aab00dc82f53
+SIZE (JonMagon-KDiskMark-2.2.1_GH0.tar.gz) = 237361
diff --git a/benchmarks/kdiskmark/files/patch-src_diskdriveinfo.cpp b/benchmarks/kdiskmark/files/patch-src_diskdriveinfo.cpp
deleted file mode 100644
index a08da7de24a4..000000000000
--- a/benchmarks/kdiskmark/files/patch-src_diskdriveinfo.cpp
+++ /dev/null
@@ -1,40 +0,0 @@
---- src/diskdriveinfo.cpp.orig 2021-02-19 10:07:38 UTC
-+++ src/diskdriveinfo.cpp
-@@ -3,6 +3,10 @@
- #include <QString>
- #include <QFile>
- #include <QFileInfo>
-+#ifdef __FreeBSD__
-+#include <sys/disk.h>
-+#include <sys/fcntl.h>
-+#endif
-
- QString DiskDriveInfo::getDeviceByVolume(const QString &volume)
- {
-@@ -12,6 +16,7 @@ QString DiskDriveInfo::getDeviceByVolume(const QString
-
- QString DiskDriveInfo::getModelName(const QString &volume)
- {
-+#if defined(__linux__)
- QFileInfo sysClass(QFileInfo(QString("/sys/class/block/%1/..")
- .arg(getDeviceByVolume(volume)))
- .canonicalFilePath());
-@@ -24,7 +29,18 @@ QString DiskDriveInfo::getModelName(const QString &vol
- QString model = sysBlock.readAll().simplified();
-
- sysBlock.close();
-+#elif defined(__FreeBSD__)
-+ struct diocgattr_arg arg;
-
-+ strlcpy(arg.name, "GEOM::descr", sizeof(arg.name));
-+ arg.len = sizeof(arg.value.str);
-+
-+ int fd = open(volume.toStdString().c_str(), O_RDONLY);
-+ if (fd == -1 || ioctl(fd, DIOCGATTR, &arg) == -1)
-+ return QString();
-+
-+ QString model(arg.value.str);
-+#endif
- return model;
- }
-
diff --git a/benchmarks/kdiskmark/pkg-descr b/benchmarks/kdiskmark/pkg-descr
index e48aa2fa53b3..29a93776fd58 100644
--- a/benchmarks/kdiskmark/pkg-descr
+++ b/benchmarks/kdiskmark/pkg-descr
@@ -1,7 +1,9 @@
KDiskMark is an HDD and SSD benchmark tool with a very friendly graphical
user interface. KDiskMark with its presets and powerful GUI calls Flexible
I/O Tester and handles the output to provide an easy to view and interpret
-comprehensive benchmark result. The application is written in C++ with Qt
-and has minimal KDE dependencies.
+comprehensive benchmark result. The program is written in C++ with Qt and
+optionally needs a minimal set of KDE dependencies (KF5Auth).
+
+It is inspired by and resembles famous CrystalDiskMark program for Windows.
WWW: https://github.com/JonMagon/KDiskMark
diff --git a/benchmarks/kdiskmark/pkg-help b/benchmarks/kdiskmark/pkg-help
new file mode 100644
index 000000000000..b139b96e4e30
--- /dev/null
+++ b/benchmarks/kdiskmark/pkg-help
@@ -0,0 +1,5 @@
+If pagecache clearing is disabled, the program will *not* be
+able to clear the pagecache in any way.
+
+If the KF5Auth helper is not built, the program will be able
+to clear the pagecache if it is run as super-user (root).
diff --git a/benchmarks/kdiskmark/pkg-plist b/benchmarks/kdiskmark/pkg-plist
index c5c68876bc5c..af0ee683eb55 100644
--- a/benchmarks/kdiskmark/pkg-plist
+++ b/benchmarks/kdiskmark/pkg-plist
@@ -1,8 +1,8 @@
bin/kdiskmark
-lib/libexec/kauth/kdiskmark_helper
+%%KF5AUTH%%lib/libexec/kauth/kdiskmark_helper
share/applications/kdiskmark.desktop
-share/dbus-1/system-services/org.jonmagon.kdiskmark.service
-share/dbus-1/system.d/org.jonmagon.kdiskmark.conf
+%%KF5AUTH%%share/dbus-1/system-services/org.jonmagon.kdiskmark.service
+%%KF5AUTH%%share/dbus-1/system.d/org.jonmagon.kdiskmark.conf
share/icons/hicolor/128x128/apps/kdiskmark.png
share/icons/hicolor/16x16/apps/kdiskmark.png
share/icons/hicolor/24x24/apps/kdiskmark.png
@@ -15,6 +15,7 @@ share/icons/hicolor/64x64/apps/kdiskmark.png
%%DATADIR%%/translations/kdiskmark_de_DE.qm
%%DATADIR%%/translations/kdiskmark_es_MX.qm
%%DATADIR%%/translations/kdiskmark_fr_FR.qm
+%%DATADIR%%/translations/kdiskmark_hi_IN.qm
%%DATADIR%%/translations/kdiskmark_it_IT.qm
%%DATADIR%%/translations/kdiskmark_pl_PL.qm
%%DATADIR%%/translations/kdiskmark_pt_BR.qm
@@ -22,4 +23,4 @@ share/icons/hicolor/64x64/apps/kdiskmark.png
%%DATADIR%%/translations/kdiskmark_sk_SK.qm
%%DATADIR%%/translations/kdiskmark_uk_UA.qm
%%DATADIR%%/translations/kdiskmark_zh_CN.qm
-share/polkit-1/actions/org.jonmagon.kdiskmark.policy
+%%KF5AUTH%%share/polkit-1/actions/org.jonmagon.kdiskmark.policy