[byobu] new major release
Jan Klepek
hpejakle at fedoraproject.org
Sun Jul 24 20:12:18 UTC 2011
commit ff1dfe86d61fed0f4a7df7605e62b6a7e602323d
Author: Jan Klepek <jan.klepek at gmail.com>
Date: Sun Jul 24 22:08:46 2011 +0200
new major release
.gitignore | 1 +
byobu.spec | 62 ++++++++++++++++++++++------------------------
byobu_byobu-shell.patch | 19 ++++++++++++++
byobu_updates.patch | 41 +++++++++++++++++++++++++++++++
sources | 2 +-
5 files changed, 92 insertions(+), 33 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 55c686a..3aff64b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,4 @@ byobu_2.80.orig.tar.gz
/byobu_3.4.orig.tar.gz
/byobu_3.20.orig.tar.gz
/byobu_3.21.orig.tar.gz
+/byobu_4.22.orig.tar.gz
diff --git a/byobu.spec b/byobu.spec
index e57d622..af7d70e 100644
--- a/byobu.spec
+++ b/byobu.spec
@@ -1,6 +1,6 @@
Name: byobu
-Version: 3.21
-Release: 2%{?dist}
+Version: 4.22
+Release: 1%{?dist}
Summary: Light-weight, configurable window manager built upon GNU screen
Group: Applications/System
@@ -9,15 +9,17 @@ URL: http://launchpad.net/byobu
Source0: http://code.launchpad.net/byobu/trunk/%{version}/+download/byobu_%{version}.orig.tar.gz
# default windows
Source1: fedoracommon
+Patch0: byobu_updates.patch
+Patch1: byobu_byobu-shell.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
-%if 0%{?rhel}
+%if 0%{?rhel} < 6
Requires: python26
%else
Requires: python >= 2.5
%endif
-BuildRequires: gettext, desktop-file-utils
+BuildRequires: gettext, desktop-file-utils, automake
Requires: screen, newt, gettext
%Description
@@ -30,36 +32,32 @@ such as toggle-able system status notifications.
%prep
%setup -q
-find . -name "Makefile*" | xargs rm -f
-# fix path
-FILES="usr/share/man/man1/byobu-status.1 usr/share/byobu/tests/byobu-time-notifications usr/lib/byobu/updates_available"
-for i in $FILES; do
-sed -i "s#usr/lib#%{_libexecdir}#g" $i;
+%patch0
+%patch1
+# fix path for lib directory in scripts
+for i in `grep -Ri {BYOBU_PREFIX}/lib/ * | awk -F: '{print $1}' | uniq`; do
+sed -i "s#{BYOBU_PREFIX}/lib/#{BYOBU_PREFIX}/libexec/#g" $i;
done
-# remove categories
-sed -i "s/GNOME;GTK;//g" usr/share/applications/byobu.desktop
-# fix path for po files
-sed -i "s#gettext.bindtextdomain(PKG, SHARE+'/po')#gettext.bindtextdomain(PKG, '%{_datadir}/locale')#g" usr/bin/byobu-config
# fix path for help file
sed -i "s#DOC=PREFIX+'/share/doc/'+PKG#DOC=PREFIX+'/share/doc/'+PKG+'-%{version}'#g" usr/bin/byobu-config
-# remove apport which is not available in fedora
-rm usr/lib/byobu/apport
-sed -i 's#status\[\"apport\"\]=0##g' usr/bin/byobu-config
-# apply fedora default settings
+# set default fedora windows
cp -p %{SOURCE1} usr/share/byobu/windows/common
+# fix path from lib to libexec by modified Makefile.am
+sed -i "s#/lib/#/libexec/#g" usr/lib/byobu/Makefile.am
%build
+%configure
+make %{?_smp_mflags}
%install
rm -rf %{buildroot}
-mkdir -p %{buildroot}%{_libexecdir}
-mkdir -p %{buildroot}%{_datadir}
-mkdir -p %{buildroot}%{_bindir}
-cp -par etc %{buildroot}/
-cp -par usr/bin/* %{buildroot}%{_bindir}
-cp -par usr/share/* %{buildroot}%{_datadir}
-cp -par usr/lib/* %{buildroot}%{_libexecdir}/
-rm -rf %{buildroot}%{_docdir}
+make DESTDIR=%{buildroot} INSTALL="install -p" CP="cp -p" install
+# remove doc from make install
+rm -rf %{buildroot}%{_docdir}/%{name}
+
+# remove apport which is not available in fedora
+rm %{buildroot}%{_libexecdir}/%{name}/apport
+sed -i 's#status\[\"apport\"\]=0##g' %{buildroot}%{_bindir}/byobu-config
for po in po/*.po
do
@@ -73,7 +71,7 @@ desktop-file-install usr/share/applications/%{name}.desktop --dir %{buildroot}%{
%find_lang %{name}
%clean
-#rm -rf %{buildroot}
+rm -rf %{buildroot}
%files -f %{name}.lang
@@ -82,20 +80,20 @@ desktop-file-install usr/share/applications/%{name}.desktop --dir %{buildroot}%{
%doc usr/share/doc/%{name}/help.txt
%dir %{_datadir}/%{name}
%dir %{_libexecdir}/%{name}
-%dir %{_sysconfdir}/%{name}
-%config(noreplace) %{_sysconfdir}/%{name}/*
%{_bindir}/%{name}*
-%{_bindir}/shell
%{_datadir}/applications/%{name}.desktop
%{_datadir}/%{name}/*
-%{_mandir}/man1/shell*
%{_mandir}/man1/%{name}*.1.gz
%{_libexecdir}/%{name}/*
+%{_libexecdir}/%{name}/.common
+%{_libexecdir}/%{name}/.constants
+%{_libexecdir}/%{name}/.dirs
%{_libexecdir}/%{name}/.notify_osd
+%{_libexecdir}/%{name}/.shutil
%changelog
-* Tue Feb 08 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 3.21-2
-- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
+* Sat Jul 23 2011 Jan Klepek <jan.klepek at, gmail.com> - 4.22-1
+- new major release
* Sat Jan 8 2011 Jan Klepek <jan.klepek at, gmail.com> - 3.21-1
- new release
diff --git a/byobu_byobu-shell.patch b/byobu_byobu-shell.patch
new file mode 100644
index 0000000..590ea14
--- /dev/null
+++ b/byobu_byobu-shell.patch
@@ -0,0 +1,19 @@
+--- usr/bin/byobu-shell 2011-07-24 12:08:13.952856847 +0200
++++ usr/bin/byobu-shell 2011-07-24 21:12:37.182934145 +0200
+@@ -27,12 +27,15 @@
+
+ if [ ! -e "$FLAG" ]; then
+ echo
+- echo "Welcome to Ubuntu's powerful, text-based window manager, Byobu."
++ echo "Welcome to powerful, text-based window manager, Byobu."
+ echo "You can toggle the launch of Byobu at login with:"
+ echo " 'byobu-disable' and 'byobu-enable'"
+ echo
+ echo "For tips, tricks, and more information, see:"
+ echo " * https://help.ubuntu.com/community/Byobu"
++ echo ""
++ echo "Please report any bug in Fedora Bugzilla system"
++ echo "* https://bugzilla.redhat.com"
+ echo
+ touch "$FLAG"
+ fi
diff --git a/byobu_updates.patch b/byobu_updates.patch
new file mode 100644
index 0000000..d08d230
--- /dev/null
+++ b/byobu_updates.patch
@@ -0,0 +1,41 @@
+--- usr/lib/byobu/updates_available.old 2011-07-24 12:47:09.348399496 +0200
++++ usr/lib/byobu/updates_available 2011-07-24 13:04:49.087807911 +0200
+@@ -44,7 +44,11 @@
+ # These are very computationally intensive processes.
+ # Background this work, have it write to the cache files,
+ # and let the next cache check pick up the results.
+- if [ -x /usr/lib/update-notifier/apt-check ]; then
++ # packagekit should be available almost everywhere nowadays
++ if command -v pkcon >/dev/null; then
++ # use packagekit to show list of packages
++ pkcon get-updates -p | grep -E '^Package' | wc -l > "$mycache" &
++ elif [ -x /usr/lib/update-notifier/apt-check ]; then
+ # If apt-check binary exists, use it
+ /usr/lib/update-notifier/apt-check 2>&1 | awk '-F;' 'END { print $1, $2 }' > "$mycache" &
+ elif command -v apt-get >/dev/null; then
+@@ -69,6 +73,10 @@
+ mycache=$1
+ # The cache doesn't exist: create it
+ [ ! -e "$mycache" ] && return 0
++ # packagekit support
++ if -e /var/lib/PackageKit/transactions.db; then
++ [ "/var/lib/PackageKit/transactions.db" -nt "$mycache" ] && return 0
++ fi
+ if command -v apt-get >/dev/null; then
+ # Debian/ubuntu
+ [ "/var/lib/apt" -nt "$mycache" ] || [ "/var/lib/apt/lists" -nt "$mycache" ]
+@@ -83,8 +91,13 @@
+ return 1
+ }
+
++# show name of available update packages
++
+ __updates_available_detail() {
+- if command -v apt-get >/dev/null; then
++ if command pkcon >/dev/null; then
++ detail=`pkcon get-updates -p | grep -E '^Package'`
++ printf "$detail"
++ elif command -v apt-get >/dev/null; then
+ detail=`apt-get -s -o Debug::NoLocking=true upgrade`
+ if [ "$1" = "--detail" ]; then
+ printf "$detail"
diff --git a/sources b/sources
index 41b543c..e2d1af4 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-44f34ee5f1c11559213756f359ca585c byobu_3.21.orig.tar.gz
+e3c0e9b32e960a7497d7f918c25fbd50 byobu_4.22.orig.tar.gz
More information about the scm-commits
mailing list