summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorTroy Engel2019-06-07 09:40:28 -0500
committerTroy Engel2019-06-07 09:40:28 -0500
commit75daff3d06ed4bbd0c47491c6fc3cb4f53feee6c (patch)
tree942610381ccbb6e9863324090630845eb91be153
parentda6fcc80823e7f7c4e0e67b5b5f244fdf65d100b (diff)
downloadaur-75daff3d06ed4bbd0c47491c6fc3cb4f53feee6c.tar.gz
update to match recent upstream fixes
-rw-r--r--.SRCINFO4
-rw-r--r--001_ksdir_ksmainwindow.patch92
-rw-r--r--PKGBUILD30
3 files changed, 6 insertions, 120 deletions
diff --git a/.SRCINFO b/.SRCINFO
index efd3c5e3fe12..781b8b5976b1 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = trace-cmd-git
pkgdesc = user-space front-end command-line tool for Ftrace, inclduing the GUI interface application kernelshark as well as trace-graph and trace-view.
- pkgver = 2.7.r368.gff13b78
+ pkgver = 2.7.r406.gb43f658
pkgrel = 1
url = http://git.kernel.org/?p=linux/kernel/git/rostedt/trace-cmd.git
arch = x86_64
@@ -25,8 +25,6 @@ pkgbase = trace-cmd-git
provides = trace-cmd
conflicts = trace-cmd
source = git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git
- source = 001_ksdir_ksmainwindow.patch
- sha256sums = SKIP
sha256sums = SKIP
pkgname = trace-cmd-git
diff --git a/001_ksdir_ksmainwindow.patch b/001_ksdir_ksmainwindow.patch
deleted file mode 100644
index 04634d9e3131..000000000000
--- a/001_ksdir_ksmainwindow.patch
+++ /dev/null
@@ -1,92 +0,0 @@
---- a/kernel-shark/src/KsMainWindow.cpp 2019-04-01 18:33:38.995391098 -0500
-+++ b/kernel-shark/src/KsMainWindow.cpp 2019-04-01 19:01:00.669394063 -0500
-@@ -23,6 +23,7 @@
- #include <QMenuBar>
- #include <QLabel>
- #include <QLocalSocket>
-+#include <QStandardPaths>
-
- // KernelShark
- #include "libkshark.h"
-@@ -133,7 +134,11 @@
- KsMainWindow::~KsMainWindow()
- {
- kshark_context *kshark_ctx(nullptr);
-- QString file = KS_CONF_DIR;
-+
-+ QString file = QStandardPaths::writableLocation(QStandardPaths::AppConfigLocation);
-+ QDir dir(file);
-+ if (!dir.exists())
-+ dir.mkpath(dir.absolutePath());
-
- file += "/lastsession.json";
-
-@@ -361,7 +366,7 @@
- QString fileName =
- QFileDialog::getOpenFileName(this,
- "Open File",
-- KS_DIR,
-+ QDir::homePath(),
- "trace-cmd files (*.dat);;All files (*)");
-
- if (!fileName.isEmpty())
-@@ -370,7 +375,11 @@
-
- void KsMainWindow::_restoreSession()
- {
-- QString file = KS_CONF_DIR;
-+ QString file = QStandardPaths::writableLocation(QStandardPaths::AppConfigLocation);
-+ QDir dir(file);
-+ if (!dir.exists())
-+ dir.mkpath(dir.absolutePath());
-+
- file += "/lastsession.json";
-
- loadSession(file);
-@@ -382,7 +391,7 @@
- QString fileName =
- QFileDialog::getOpenFileName(this,
- "Import Session",
-- KS_DIR,
-+ QDir::homePath(),
- "Kernel Shark Config files (*.json);;");
-
- if (fileName.isEmpty())
-@@ -413,7 +422,7 @@
- QString fileName =
- QFileDialog::getSaveFileName(this,
- "Export Filter",
-- KS_DIR,
-+ QDir::homePath(),
- "Kernel Shark Config files (*.json);;");
-
- if (fileName.isEmpty())
-@@ -462,7 +471,8 @@
- if (!kshark_instance(&kshark_ctx))
- return;
-
-- fileName = QFileDialog::getOpenFileName(this, "Import Filter", KS_DIR,
-+ fileName = QFileDialog::getOpenFileName(this, "Import Filter",
-+ QDir::homePath(),
- "Kernel Shark Config files (*.json);;");
-
- if (fileName.isEmpty())
-@@ -490,7 +500,8 @@
- if (!kshark_instance(&kshark_ctx))
- return;
-
-- fileName = QFileDialog::getSaveFileName(this, "Export Filter", KS_DIR,
-+ fileName = QFileDialog::getSaveFileName(this, "Export Filter",
-+ QDir::homePath(),
- "Kernel Shark Config files (*.json);;");
-
- if (fileName.isEmpty())
-@@ -811,7 +822,7 @@
-
- fileNames =
- QFileDialog::getOpenFileNames(this, "Add KernelShark plugins",
-- KS_DIR,
-+ QDir::homePath(),
- "KernelShark Plugins (*.so);;");
-
- if (fileNames.isEmpty())
diff --git a/PKGBUILD b/PKGBUILD
index 0236bc8f16e7..70f69ba7d5d3 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,7 +3,7 @@
# Maintainer: Netanel Shine <netanel at archlinux.org.il>
pkgname=trace-cmd-git
-pkgver=2.7.r368.gff13b78
+pkgver=2.7.r406.gb43f658
pkgrel=1
pkgdesc="user-space front-end command-line tool for Ftrace, inclduing the GUI interface application kernelshark as well as trace-graph and trace-view."
arch=('x86_64' 'aarch64')
@@ -19,9 +19,8 @@ provides=("trace-cmd")
conflicts=("trace-cmd")
source=(
"git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git"
- "001_ksdir_ksmainwindow.patch"
)
-sha256sums=("SKIP" "SKIP")
+sha256sums=("SKIP")
pkgver() {
cd "$srcdir/trace-cmd"
@@ -37,35 +36,20 @@ prepare() {
## fixes for getting kernelshark installed correctly to /usr
- # this implements QStandardPaths in KsMainWindow.cpp
- patch -p1 < "${srcdir}/001_ksdir_ksmainwindow.patch"
-
- # pass down Release as build type
+ # pass down Release as build type to strip build directories
+ # from final binaries
sed -i.cip 's|\(-D_INSTALL_PREFIX=\)|-DCMAKE_BUILD_TYPE=Release \1|g' \
Makefile
# all work below is within kernel-shark/
cd kernel-shark
- # KS_DIR is the random local build directory, relocate it to /usr
- sed -i.ks 's|@KS_DIR@|@_INSTALL_PREFIX@/share/kernelshark|g' \
- build/ks.desktop.cmake
- sed -i.ks 's|@KS_DIR@|@_INSTALL_PREFIX@|g' build/deff.h.cmake
+ # the build sets TRACECMD_BIN_DIR=(local build path) instead of /usr/bin/
sed -i.tb 's|@TRACECMD_BIN_DIR@|@_INSTALL_PREFIX@/bin|g' build/deff.h.cmake
- # this ends up hard-coded to the build directory, with the above
- # patches it's no longer useful so set it to a safe directory
- sed -i.ksc 's|KS_CONF_DIR "\${KS_DIR}|KS_CONF_DIR "/tmp|g' CMakeLists.txt
-
# the gcc/g++ debug flag is enabled even when _DEBUG=0 which causes
# the build directory to get coded into the libraries
sed -i.dbg 's/-Wall -g/-Wall/g' CMakeLists.txt
-
- # this source is hard-coded to KS_DIR/lib/plugin-* (bug?)
- sed -i.plg 's|lib/plugin|lib/kshark/plugin|g' src/KsUtils.cpp
-
- # this tries to use KS_DIR for open/close of files
- sed -i.hm 's/KS_DIR/QDir::homePath()/g' src/KsCaptureDialog.cpp
}
build() {
@@ -81,8 +65,4 @@ package() {
# pkg-config --cflags --libs $PYTHON_VERS
make PYTHON_VERS=python3 prefix="/usr" DESTDIR="$pkgdir" \
install install_doc install_gui
-
- # referenced in the .desktop file
- install -Dm0644 "${srcdir}/trace-cmd/kernel-shark/icons/ksharkicon.png" \
- "${pkgdir}/usr/share/kernelshark/icons/ksharkicon.png"
}