screen/screen.spec
Thomas Renninger a13ce2fdf3 - Add zombie and enhance windows commands
screen-poll-zombies.patch: Dead windows will be restarted after
                              a specified timeout (if enabled)
   screen_enhance_windows_list_1_3.patch:
       Cleanup window flags processing. This leads to a slight
       output change in "Ww" string escapes (window list), but these
       should be rather seldom used and flags are still shown.
   screen_enhance_windows_list_2_3.patch:
       Enhance windows command with an optional string escape based
       parameter which also removes the output size (1024 bytes)
       restriction (only if param is passed) of the windows command.   
- Only Require makeinfo for openSUSE versions 11.4 and above.
  This requirement did not exist in earlier versions, now the package
  builds again for example against SLES 11 (11.4 based).

OBS-URL: https://build.opensuse.org/package/show/Base:System/screen?expand=0&rev=41
2013-02-06 14:43:50 +00:00

132 lines
3.9 KiB
RPMSpec

#
# spec file for package screen
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Url: http://www.gnu.org/software/screen/
Name: screen
%if 0%{?suse_version} > 1140
BuildRequires: makeinfo
%endif
BuildRequires: ncurses-devel
%if 0%{?suse_version} > 1130
BuildRequires: utempter-devel
%else
BuildRequires: utempter
%endif
PreReq: %install_info_prereq
PreReq: coreutils
Version: 4.0.4
Release: 0
Summary: A program to allow multiple screens on a VT100/ANSI Terminal
License: GPL-2.0+
Group: System/Console
Source: %{name}-%{version}.tar.gz
Source1: screen.conf
Patch0: screen-4.0.2.dif
Patch1: screen-__P.diff
Patch2: screen-man-loginshell.diff
Patch3: screen-4.0.3-ipv6.patch
# upstream savannah#30880
Patch4: term_too_long.diff
Patch5: sort_command.patch
Patch6: libtinfo.diff
Patch7: mappedcmd.diff
Patch8: styroptcrash.diff
Patch9: use_locale.diff
Patch10: screen-poll-zombies.patch
Patch11: screen_enhance_windows_list_1_3.patch
Patch12: screen_enhance_windows_list_2_3.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
With this program you can take advantage of the multitasking abilities
of your Linux system by opening several sessions over one terminal. The
sessions can also be detached and resumed from another login terminal.
Documentation: man page
%prep
%setup
%patch0
%patch1
%patch2 -p1
%patch3
%patch4 -p1
%patch5
%patch6
%patch7 -p2
%patch8 -p2
%patch9 -p1
%patch10 -p1
%patch11 -p1
%patch12 -p1
%build
CFLAGS="-DMAXWIN=1000 $RPM_OPT_FLAGS" %configure --prefix=/usr --infodir=%{_infodir} \
--mandir=%{_mandir} \
--with-socket-dir='(eff_uid ? "/var/run/uscreens" : "/var/run/screens")' \
--with-sys-screenrc=/etc/screenrc \
--with-pty-group=5 \
--enable-use-locale \
--enable-telnet \
--enable-colors256 \
--verbose
make %{?_smp_mflags}
%install
make install DESTDIR=$RPM_BUILD_ROOT
rm -f $RPM_BUILD_ROOT/usr/bin/screen
mv $RPM_BUILD_ROOT/usr/bin/screen-%version $RPM_BUILD_ROOT/usr/bin/screen
chmod 755 $RPM_BUILD_ROOT/usr/bin/screen
mkdir -p $RPM_BUILD_ROOT/etc
mkdir -p $RPM_BUILD_ROOT/usr/lib
mkdir -p $RPM_BUILD_ROOT/usr/lib/tmpfiles.d
mkdir -p $RPM_BUILD_ROOT/var/run/screens
chmod 755 $RPM_BUILD_ROOT/var/run/screens
mkdir -p $RPM_BUILD_ROOT/var/run/uscreens
chmod 1777 $RPM_BUILD_ROOT/var/run/uscreens
install -m 644 screenrc $RPM_BUILD_ROOT/etc/screenrc
install -m 644 %SOURCE1 $RPM_BUILD_ROOT/usr/lib/tmpfiles.d
%files
%defattr(-,root,root)
%config /etc/screenrc
%attr(555,root,root) /usr/bin/screen
%dir /usr/share/screen
%dir /usr/lib/tmpfiles.d
/usr/lib/tmpfiles.d/screen.conf
/usr/share/screen/utf8encodings
# Created via aaa_base or systemd on system boot
%ghost %dir /var/run/screens
%ghost %dir /var/run/uscreens
%doc %{_infodir}/screen.info*.gz
%doc %{_mandir}/man1/screen.1.gz
%post
%install_info --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz
# Create our dirs immediatly, after a manual package install.
# After a reboot systemd/aaa_base will take care.
test -d /var/run/screens || mkdir -m 755 /var/run/screens
test -d /var/run/uscreens || mkdir -m 1777 /var/run/uscreens
%postun
%install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz
%changelog