a7b75e
%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}}
a7b75e
10f71c
Name:		byobu
4bfda0
Version:	5.69
4bfda0
Release:	1%{?dist}
10f71c
Summary:	Light-weight, configurable window manager built upon GNU screen
10f71c
10f71c
Group:		Applications/System
10f71c
License:	GPLv3
10f71c
URL:		http://launchpad.net/byobu
10f71c
Source0:	http://code.launchpad.net/byobu/trunk/%{version}/+download/byobu_%{version}.orig.tar.gz
766637
# default windows
766637
Source1:	fedoracommon
10f71c
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
10f71c
BuildArch:	noarch
e82ebc
%if 0%{?rhel}%{?fedora} > 5
f241cf
Requires:	python >= 2.5
e82ebc
%else
e82ebc
Requires:	python26
f241cf
%endif
10f71c
ff1dfe
BuildRequires:	gettext, desktop-file-utils, automake
4bfda0
Requires:	screen, newt, gettext, tmux
10f71c
10f71c
%Description
10f71c
Byobu is a Japanese term for decorative, multi-panel screens that serve 
10f71c
as folding room dividers. As an open source project, Byobu is an 
10f71c
elegant enhancement of the otherwise functional, plain, 
10f71c
practical GNU Screen. Byobu includes an enhanced profile 
10f71c
and configuration utilities for the GNU screen window manager, 
10f71c
such as toggle-able system status notifications.
10f71c
10f71c
%prep
10f71c
%setup -q
cb3201
# remove swap file
af907d
if [ -e "usr/bin/.byobu-status-print.swp" ]; then rm usr/bin/.byobu-status-print.swp
af907d
fi
ff1dfe
# fix path for lib directory in scripts
ff1dfe
for i in `grep -Ri {BYOBU_PREFIX}/lib/ * | awk -F: '{print $1}' | uniq`; do
ff1dfe
sed -i "s#{BYOBU_PREFIX}/lib/#{BYOBU_PREFIX}/libexec/#g" $i;
10f71c
done
e82ebc
for i in `grep -Ri BYOBU_PREFIX/lib/ * | awk -F: '{print $1}' | uniq`; do
e82ebc
sed -i "s#BYOBU_PREFIX/lib/#BYOBU_PREFIX/libexec/#g" $i;
e82ebc
done
4bfda0
4bfda0
# fix path for correct directory in /usr/share
4bfda0
sed -i "s#DOC = BYOBU_PREFIX + '/share/doc/' + PKG#DOC='%{_pkgdocdir}'#g" usr/lib/byobu/include/config.py
4bfda0
ff1dfe
# set default fedora windows
766637
cp -p %{SOURCE1} usr/share/byobu/windows/common
4bfda0
52cd5d
# fix path from lib to libexec by modified Makefile.am and in
ff1dfe
sed -i "s#/lib/#/libexec/#g" usr/lib/byobu/Makefile.am
52cd5d
sed -i "s#/lib/#/libexec/#g" usr/lib/byobu/Makefile.in
52cd5d
sed -i "s#/lib/#/libexec/#g" usr/lib/byobu/include/Makefile.am
52cd5d
sed -i "s#/lib/#/libexec/#g" usr/lib/byobu/include/Makefile.in
10f71c
10f71c
%build
ff1dfe
%configure
ff1dfe
make %{?_smp_mflags}
10f71c
10f71c
%install
10f71c
rm -rf %{buildroot}
a7b75e
make DESTDIR=%{buildroot} INSTALL="install -p" CP="cp -p" docdir=%{_pkgdocdir} install
52cd5d
rm -rf %{buildroot}%{_sysconfdir}/profile.d
ff1dfe
# remove apport which is not available in fedora
52cd5d
rm %{buildroot}/%{_libexecdir}/%{name}/apport
ff1dfe
sed -i 's#status\[\"apport\"\]=0##g' %{buildroot}%{_bindir}/byobu-config
a7b75e
cp -p README COPYING %{buildroot}%{_pkgdocdir}
10f71c
for po in po/*.po
10f71c
do
10f71c
    lang=${po#po/}
10f71c
    lang=${lang%.po}
10f71c
    mkdir -p %{buildroot}%{_datadir}/locale/${lang}/LC_MESSAGES/
10f71c
    msgfmt ${po} -o %{buildroot}%{_datadir}/locale/${lang}/LC_MESSAGES/%{name}.mo
10f71c
done
10f71c
desktop-file-install usr/share/applications/%{name}.desktop --dir %{buildroot}%{_datadir}/applications
10f71c
10f71c
%find_lang %{name}
10f71c
10f71c
%clean
ff1dfe
rm -rf %{buildroot}
10f71c
10f71c
10f71c
%files -f %{name}.lang
10f71c
%defattr(-,root,root,-)
10f71c
%dir %{_datadir}/%{name}
10f71c
%dir %{_libexecdir}/%{name}
52cd5d
%dir %{_sysconfdir}/%{name}
a7b75e
%dir %{_pkgdocdir}
a7b75e
%{_pkgdocdir}/*
10f71c
%{_bindir}/%{name}*
ec771f
%if 0%{?rhel} == 5
ec771f
%{_datadir}/applications/*.desktop
ec771f
%else
10f71c
%{_datadir}/applications/%{name}.desktop
ec771f
%endif
10f71c
%{_datadir}/%{name}/*
10f71c
%{_mandir}/man1/%{name}*.1.gz
10f71c
%{_libexecdir}/%{name}/*
52cd5d
%config(noreplace) %{_sysconfdir}/%{name}/*
10f71c
10f71c
%changelog
4bfda0
* Wed Jan 8 2014 Jan Klepek <jan.klepek at,="" gmail.com=""> - 5.69-1
4bfda0
- update to latest version (#873560)
4bfda0
- added tmux dependency (#907267)
4bfda0
a7b75e
* Thu Dec 12 2013 Ville Skyttä <ville.skytta@iki.fi> - 5.21-7
a7b75e
- Install docs to %%{_pkgdocdir} where available (#993689).
a7b75e
- Fix bogus dates in %%changelog.
a7b75e
30261e
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.21-6
30261e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
30261e
74fa30
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.21-5
74fa30
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
74fa30
b7d905
* Sat Aug 25 2012 Jan Klepek <jan.klepek at,="" gmail.com=""> - 5.21-4 
b7d905
- desktop file handling fixed
b7d905
a2f27d
* Sat Aug 25 2012 Jan Klepek <jan.klepek at,="" gmail.com=""> - 5.21-3
a2f27d
- another fix into documentation
a2f27d
a7b75e
* Sun Aug 19 2012 Jan Klepek <jan.klepek at,="" gmail.com=""> - 5.21-2
965067
- fixed documentation
965067
a7b75e
* Sun Aug 19 2012 Jan Klepek <jan.klepek at,="" gmail.com=""> - 5.21-1
e21e71
- new minor release
e21e71
0726c8
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.17-2
0726c8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
0726c8
52cd5d
* Sun Apr 08 2012 Jan Klepek <jan.klepek at,="" gmail.com=""> - 5.17-1
52cd5d
- update to latest version
52cd5d
158064
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.41-2
158064
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
158064
af907d
* Sat Oct 15 2011 Jan Klepek <jan.klepek at,="" gmail.com=""> - 4.41-1
af907d
- update to 4.41
af907d
cb3201
* Mon Aug 1 2011 Jan Klepek <jan.klepek at,="" gmail.com=""> - 4.23-1
cb3201
- update to 4.23
cb3201
e82ebc
* Sat Jul 23 2011 Jan Klepek <jan.klepek at,="" gmail.com=""> - 4.22-2
e82ebc
- updated to 4.22 + various bugfixes
e82ebc
e82ebc
* Sat Jul 23 2011 Jan Klepek <jan.klepek at,="" gmail.com=""> - 4.20-1
ff1dfe
- new major release
1fa2aa
fad730
* Sat Jan 8 2011 Jan Klepek <jan.klepek at,="" gmail.com=""> - 3.21-1
fad730
- new release
fad730
fad730
* Sat Dec 18 2010 Jan Klepek <jan.klepek at,="" gmail.com=""> - 3.20-2
fad730
- upgrade to 3.20 + some patches
3a66e6
8961a7
* Fri Sep 3 2010 Jan Klepek <jan.klepek at,="" gmail.com=""> - 3.4-1
8961a7
- upgraded to 3.4
8961a7
766637
* Thu Jun 17 2010 Jan Klepek - 2.80-1
766637
- bugfix for BZ#595087, changed default windows selection, removed apport from toggle status notification
766637
- upgraded to 2.80 version
766637
10f71c
* Sun May 2 2010 Jan Klepek <jan.klepek at,="" gmail.com=""> - 2.73-1
10f71c
- new version released
10f71c
10f71c
* Wed Apr 21 2010 Jan Klepek <jan.klepek at,="" gmail.com=""> - 2.67-3
10f71c
- adjusted SHARE path
10f71c
10f71c
* Tue Apr 20 2010 Jan Klepek <jan.klepek at,="" gmail.com=""> - 2.67-2
10f71c
- adjusted path for looking for po files and removed duplicate file entry
10f71c
10f71c
* Fri Apr 2 2010 Jan Klepek <jan.klepek at,="" gmail.com=""> - 2.67-1
10f71c
- Initial fedora RPM release