RHEL 9.0.0 Alpha bootstrap
The content of this branch was automatically imported from Fedora ELN with the following as its source: https://src.fedoraproject.org/rpms/tuna#ae7dfbc0b5294daf4f1270d8668b8ac32b1ada8e
This commit is contained in:
parent
b301e6df2a
commit
9da4fc02a4
6
.gitignore
vendored
6
.gitignore
vendored
@ -0,0 +1,6 @@
|
||||
/tuna-0.11.tar.bz2
|
||||
/tuna-0.11.1.tar.bz2
|
||||
/tuna-0.12.tar.xz
|
||||
/tuna-0.13.1.tar.xz
|
||||
/tuna-0.14.tar.xz
|
||||
/tuna-0.14.1.tar.xz
|
156
oscilloscope-move-from-pygtk2-to-gtk3-gobject.patch
Normal file
156
oscilloscope-move-from-pygtk2-to-gtk3-gobject.patch
Normal file
@ -0,0 +1,156 @@
|
||||
From 4511a331b8ea986b0026277e4753538b749c0a29 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Kastner <jkastner@redhat.com>
|
||||
Date: Mon, 7 Jan 2019 21:57:56 +0100
|
||||
Subject: [PATCH] oscilloscope: move from pygtk2 to gtk3 gobject
|
||||
|
||||
oscilloscope migration from pygtk2 to gtk3 + python
|
||||
gobject introspection
|
||||
|
||||
Signed-off-by: Jiri Kastner <jkastner@redhat.com>
|
||||
---
|
||||
oscilloscope-cmd.py | 5 ++++-
|
||||
tuna/oscilloscope.py | 47 ++++++++++++++++++++++++--------------------
|
||||
2 files changed, 30 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/oscilloscope-cmd.py b/oscilloscope-cmd.py
|
||||
index 753b879..b9c24b4 100755
|
||||
--- a/oscilloscope-cmd.py
|
||||
+++ b/oscilloscope-cmd.py
|
||||
@@ -20,7 +20,10 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
||||
# USA
|
||||
|
||||
-import getopt, sys, gtk
|
||||
+import getopt, sys
|
||||
+import gi
|
||||
+gi.require_version('Gtk', '3.0')
|
||||
+from gi.repository import Gtk as gtk
|
||||
from tuna import oscilloscope
|
||||
|
||||
def usage():
|
||||
diff --git a/tuna/oscilloscope.py b/tuna/oscilloscope.py
|
||||
index b26f903..af54d83 100755
|
||||
--- a/tuna/oscilloscope.py
|
||||
+++ b/tuna/oscilloscope.py
|
||||
@@ -23,16 +23,21 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
||||
# USA
|
||||
|
||||
-import gobject, gtk, os, sys
|
||||
-from matplotlib.backends.backend_gtkagg import \
|
||||
- FigureCanvasGTKAgg as figure_canvas
|
||||
+import os, sys, gi
|
||||
+gi.require_version('Gtk', '3.0')
|
||||
+from gi.repository import Gtk as gtk
|
||||
+from gi.repository import Gdk as gdk
|
||||
+from gi.repository import GObject as gobject
|
||||
+
|
||||
+from matplotlib.backends.backend_gtk3agg import \
|
||||
+ FigureCanvasGTK3Agg as figure_canvas
|
||||
import matplotlib.figure, matplotlib.ticker, numpy
|
||||
|
||||
class histogram_frame(gtk.Frame):
|
||||
def __init__(self, title = "Statistics", width = 780, height = 100,
|
||||
max_value = 500, nr_entries = 10,
|
||||
facecolor = "white"):
|
||||
- gtk.Frame.__init__(self, title)
|
||||
+ gtk.Frame.__init__(self)
|
||||
|
||||
self.fraction = int(max_value / nr_entries)
|
||||
if self.fraction == 0:
|
||||
@@ -69,7 +74,7 @@ class histogram_frame(gtk.Frame):
|
||||
label.set_alignment(0, 1)
|
||||
table.attach(self.buckets_counter[bucket], 2, 3, bucket, bucket + 1, 0, 0, 0, 0)
|
||||
|
||||
- self.modify_bg(gtk.STATE_NORMAL, gtk.gdk.color_parse(facecolor))
|
||||
+ self.modify_bg(gtk.StateFlags.NORMAL, gdk.color_parse(facecolor))
|
||||
|
||||
def add_sample(self, sample):
|
||||
if sample > self.max_value:
|
||||
@@ -97,7 +102,7 @@ class oscilloscope_frame(gtk.Frame):
|
||||
bg_color = "darkgreen", facecolor = "white",
|
||||
ylabel = "Latency", picker = None):
|
||||
|
||||
- gtk.Frame.__init__(self, title)
|
||||
+ gtk.Frame.__init__(self)
|
||||
|
||||
self.font = { 'fontname' : 'Liberation Sans',
|
||||
'color' : 'b',
|
||||
@@ -113,7 +118,7 @@ class oscilloscope_frame(gtk.Frame):
|
||||
facecolor = facecolor)
|
||||
ax = figure.add_subplot(111)
|
||||
self.ax = ax
|
||||
- ax.set_axis_bgcolor(bg_color)
|
||||
+ ax.set_facecolor(bg_color)
|
||||
|
||||
self.on_screen_samples = ax.plot(self.ind, self.samples, graph_type,
|
||||
color = plot_color,
|
||||
@@ -132,7 +137,7 @@ class oscilloscope_frame(gtk.Frame):
|
||||
self.canvas.set_size_request(width, height)
|
||||
|
||||
self.add(self.canvas)
|
||||
- self.modify_bg(gtk.STATE_NORMAL, gtk.gdk.color_parse(facecolor))
|
||||
+ self.modify_bg(gtk.StateFlags.NORMAL, gdk.color_parse(facecolor))
|
||||
self.nr_samples = 0
|
||||
|
||||
def add_sample(self, sample):
|
||||
@@ -164,9 +169,9 @@ def add_table_row(table, row, label_text, label_value = "0"):
|
||||
|
||||
class system_info_frame(gtk.Frame):
|
||||
def __init__(self, title = "System", facecolor = "white"):
|
||||
- gtk.Frame.__init__(self, title)
|
||||
+ gtk.Frame.__init__(self)
|
||||
|
||||
- self.modify_bg(gtk.STATE_NORMAL, gtk.gdk.color_parse(facecolor))
|
||||
+ self.modify_bg(gtk.StateFlags.NORMAL, gdk.color_parse(facecolor))
|
||||
|
||||
table = gtk.Table(3, 2, False)
|
||||
table.set_border_width(5)
|
||||
@@ -209,8 +214,8 @@ class oscilloscope(gtk.Window):
|
||||
vbox.set_border_width(8)
|
||||
self.add(vbox)
|
||||
|
||||
- stats_frame = gtk.Frame("Statistics")
|
||||
- stats_frame.modify_bg(gtk.STATE_NORMAL, gtk.gdk.color_parse(facecolor))
|
||||
+ stats_frame = gtk.Frame.new("Statistics")
|
||||
+ stats_frame.modify_bg(gtk.StateFlags.NORMAL, gdk.color_parse(facecolor))
|
||||
|
||||
table = gtk.Table(3, 2, False)
|
||||
table.set_border_width(5)
|
||||
@@ -222,8 +227,8 @@ class oscilloscope(gtk.Window):
|
||||
self.avg_label = add_table_row(table, 1, "Avg")
|
||||
self.max_label = add_table_row(table, 2, "Max")
|
||||
|
||||
- help_frame = gtk.Frame("Help")
|
||||
- help_frame.modify_bg(gtk.STATE_NORMAL, gtk.gdk.color_parse(facecolor))
|
||||
+ help_frame = gtk.Frame.new("Help")
|
||||
+ help_frame.modify_bg(gtk.StateFlags.NORMAL, gdk.color_parse(facecolor))
|
||||
|
||||
table = gtk.Table(4, 2, False)
|
||||
table.set_border_width(5)
|
||||
@@ -251,15 +256,15 @@ class oscilloscope(gtk.Window):
|
||||
info_frame = system_info_frame()
|
||||
|
||||
vbox_help_info = gtk.VBox()
|
||||
- vbox_help_info.pack_start(info_frame, False, False)
|
||||
- vbox_help_info.pack_end(help_frame, False, False)
|
||||
+ vbox_help_info.pack_start(info_frame, False, False, 0)
|
||||
+ vbox_help_info.pack_end(help_frame, False, False, 0)
|
||||
hbox = gtk.HBox()
|
||||
- hbox.pack_start(vbox_help_info, False, False)
|
||||
- hbox.pack_start(stats_frame, False, False)
|
||||
- hbox.pack_end(self.hist, True, True)
|
||||
+ hbox.pack_start(vbox_help_info, False, False, 0)
|
||||
+ hbox.pack_start(stats_frame, False, False, 0)
|
||||
+ hbox.pack_end(self.hist, True, True, 0)
|
||||
|
||||
- vbox.pack_start(self.scope, True, True)
|
||||
- vbox.pack_end(hbox, True, False)
|
||||
+ vbox.pack_start(self.scope, True, True, 0)
|
||||
+ vbox.pack_end(hbox, True, False, 0)
|
||||
|
||||
self.show_all()
|
||||
|
||||
--
|
||||
2.20.1
|
||||
|
1
sources
Normal file
1
sources
Normal file
@ -0,0 +1 @@
|
||||
SHA512 (tuna-0.14.1.tar.xz) = fda7bc0da96ed2b7900f8fe42db67a7e74f83ff29b8ecf02dc3ad7131df76e6a47e3b8e66a76449be4f11020400360324d1eb4e996e9745542e2c5ee1075de69
|
205
tuna.spec
Normal file
205
tuna.spec
Normal file
@ -0,0 +1,205 @@
|
||||
Name: tuna
|
||||
Version: 0.14.1
|
||||
Release: 3%{?dist}
|
||||
License: GPLv2
|
||||
Summary: Application tuning GUI & command line utility
|
||||
Source: https://www.kernel.org/pub/software/utils/%{name}/%{name}-%{version}.tar.xz
|
||||
Patch0: oscilloscope-move-from-pygtk2-to-gtk3-gobject.patch
|
||||
URL: https://rt.wiki.kernel.org/index.php/Tuna
|
||||
BuildArch: noarch
|
||||
BuildRequires: python3-devel, gettext
|
||||
Requires: python3-ethtool
|
||||
Requires: python3-linux-procfs >= 0.6
|
||||
Requires: python3-schedutils >= 0.6
|
||||
# This really should be a Suggests...
|
||||
# Requires: python-inet_diag
|
||||
|
||||
%description
|
||||
Provides interface for changing scheduler and IRQ tunables, at whole CPU and at
|
||||
per thread/IRQ level. Allows isolating CPUs for use by a specific application
|
||||
and moving threads and interrupts to a CPU by just dragging and dropping them.
|
||||
Operations can be done on CPU sockets, understanding CPU topology.
|
||||
|
||||
Can be used as a command line utility without requiring the GUI libraries to be
|
||||
installed.
|
||||
|
||||
%package -n oscilloscope
|
||||
Summary: Generic graphical signal plotting tool
|
||||
Requires: python3-matplotlib-gtk3
|
||||
Requires: python3-numpy
|
||||
Requires: python3-cairocffi
|
||||
Requires: gobject-introspection
|
||||
Requires: tuna = %{version}-%{release}
|
||||
|
||||
%description -n oscilloscope
|
||||
Plots stream of values read from standard input on the screen together with
|
||||
statistics and a histogram.
|
||||
|
||||
Allows to instantly see how a signal generator, such as cyclictest, signaltest
|
||||
or even ping, reacts when, for instance, its scheduling policy or real time
|
||||
priority is changed, be it using tuna or plain chrt & taskset.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1
|
||||
|
||||
%build
|
||||
%py3_build
|
||||
pathfix.py -pni "%{__python3} %{py3_shbang_opts}" tuna/
|
||||
pathfix.py -pni "%{__python3} %{py3_shbang_opts}" tuna-cmd.py
|
||||
pathfix.py -pni "%{__python3} %{py3_shbang_opts}" oscilloscope-cmd.py
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
%py3_install
|
||||
mkdir -p %{buildroot}/%{_sysconfdir}/tuna/
|
||||
mkdir -p %{buildroot}/{%{_bindir},%{_datadir}/tuna/help/kthreads,%{_mandir}/man8}
|
||||
mkdir -p %{buildroot}/%{_datadir}/polkit-1/actions/
|
||||
install -p -m644 tuna/tuna_gui.glade %{buildroot}/%{_datadir}/tuna/
|
||||
install -p -m755 tuna-cmd.py %{buildroot}/%{_bindir}/tuna
|
||||
install -p -m755 oscilloscope-cmd.py %{buildroot}/%{_bindir}/oscilloscope
|
||||
install -p -m644 help/kthreads/* %{buildroot}/%{_datadir}/tuna/help/kthreads/
|
||||
install -p -m644 docs/tuna.8 %{buildroot}/%{_mandir}/man8/
|
||||
install -p -m644 etc/tuna/example.conf %{buildroot}/%{_sysconfdir}/tuna/
|
||||
install -p -m644 etc/tuna.conf %{buildroot}/%{_sysconfdir}/
|
||||
install -p -m644 org.tuna.policy %{buildroot}/%{_datadir}/polkit-1/actions/
|
||||
|
||||
# l10n-ed message catalogues
|
||||
for lng in `cat po/LINGUAS`; do
|
||||
po=po/"$lng.po"
|
||||
mkdir -p %{buildroot}/%{_datadir}/locale/${lng}/LC_MESSAGES
|
||||
msgfmt $po -o %{buildroot}/%{_datadir}/locale/${lng}/LC_MESSAGES/%{name}.mo
|
||||
done
|
||||
|
||||
%find_lang %name
|
||||
|
||||
%files -f %{name}.lang
|
||||
%doc ChangeLog
|
||||
%{python3_sitelib}/*.egg-info
|
||||
%{_bindir}/tuna
|
||||
%{_datadir}/tuna/
|
||||
%{python3_sitelib}/tuna/
|
||||
%{_mandir}/man8/tuna.8*
|
||||
%{_sysconfdir}/tuna.conf
|
||||
%{_sysconfdir}/tuna/*
|
||||
%{_datadir}/polkit-1/actions/org.tuna.policy
|
||||
|
||||
%files -n oscilloscope
|
||||
%{_bindir}/oscilloscope
|
||||
%doc docs/oscilloscope+tuna.html
|
||||
%doc docs/oscilloscope+tuna.pdf
|
||||
|
||||
%changelog
|
||||
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.14.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 0.14.1-2
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Thu May 21 2020 Jiri Kastner <jkastner@fedoraproject.org> - 0.14.1
|
||||
- update to 0.14.1
|
||||
- fixes RHBZ#1773339
|
||||
|
||||
* Fri Jan 31 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.14-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 0.14-5
|
||||
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
||||
|
||||
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.14-4
|
||||
- Rebuilt for Python 3.8
|
||||
|
||||
* Sat Jul 27 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.14-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Tue Feb 12 2019 Jiri Kastner <jkastner@fedoraproject.org> - 0.14-3
|
||||
- upload patch
|
||||
|
||||
* Tue Feb 12 2019 Jiri Kastner <jkastner@fedoraproject.org> - 0.14-2
|
||||
- oscilloscope gtk3 patch
|
||||
|
||||
* Tue Feb 12 2019 Jiri Kastner <jkastner@fedoraproject.org> - 0.14-1
|
||||
- update to 0.14
|
||||
- switch to python3
|
||||
|
||||
* Sun Feb 03 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.13.1-8
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.13.1-7
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Wed Feb 14 2018 Iryna Shcherbina <ishcherb@redhat.com> - 0.13.1-6
|
||||
- Update Python 2 dependency declarations to new packaging standards
|
||||
(See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
|
||||
|
||||
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.13.1-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Wed Nov 29 2017 Lubomir Rintel <lkundrak@v3.sk> - 0.13.1-4
|
||||
- Add a missing dependency for oscilloscope
|
||||
|
||||
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.13.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.13.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Wed Dec 21 2016 Jiri Kastner <jkastner@redhat.com> - 0.13.1-1
|
||||
- new version
|
||||
|
||||
* Mon Sep 26 2016 Dominik Mierzejewski <rpm@greysector.net> - 0.12-5
|
||||
- rebuilt for matplotlib-2.0.0
|
||||
|
||||
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12-4
|
||||
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
|
||||
|
||||
* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.12-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||
|
||||
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
||||
|
||||
* Fri Oct 10 2014 Jiri Kastner <jkastner@redhat.com> - 0.12-1
|
||||
- new upstream release
|
||||
|
||||
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
||||
|
||||
* Mon Jul 29 2013 Jiri Kastner <jkastner@redhat.com> - 0.11.1-1
|
||||
- New upstream release
|
||||
|
||||
* Tue Jun 11 2013 Jiri Kastner <jkastner@redhat.com> - 0.11-2
|
||||
- changed dependencies from python-numeric to numpy
|
||||
- merged spec changes from upstream
|
||||
|
||||
* Thu Jun 6 2013 Jiri Kastner <jkastner@redhat.com> - 0.11-1
|
||||
- New upstream release
|
||||
|
||||
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.1-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
||||
|
||||
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.1-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
||||
|
||||
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.1-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
||||
|
||||
* Sun Aug 01 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 0.9.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
|
||||
|
||||
* Thu Sep 03 2009 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.9.1-1
|
||||
- New upstream release
|
||||
|
||||
* Wed Aug 26 2009 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.9-3
|
||||
- Rewrite the oscilloscope package summary
|
||||
- Remove the shebang in tuna/oscilloscope.py
|
||||
|
||||
* Mon Aug 17 2009 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.9-2
|
||||
- Use install -p
|
||||
- Add BuildRequires for gettext
|
||||
|
||||
* Fri Jul 10 2009 Arnaldo Carvalho de Melo <acme@redhat.com> - 0.9-1
|
||||
- Fedora package reviewing changes: introduce ChangeLog file
|
Loading…
Reference in New Issue
Block a user