サイトトップMandriva Linux向けパッケージ ≫ screen-4.0.3-8(独自修正)

screen-4.0.3-8kkr2010.0.spec

Summary:	A screen manager that supports multiple logins on one terminal
Name:		screen
Version:	4.0.3
Release: 	%mkrel 8
License:	GPLv2+
Group:		Terminals
BuildRequires:	ncurses-devel
BuildRequires:	utempter-devel
BuildRequires:	texinfo
URL:		http://www.gnu.org/software/screen/
Source0:	ftp://ftp.uni-erlangen.de/pub/utilities/screen/%{name}-%{version}.tar.gz
# TODO check if still needed
Patch1: 	screen-ia64.patch
# TODO check if still needed 
Patch3:		screen-makefile-ppc.patch
# correct the location of various files in man page and info page 
Patch4:		screen-3.9.11-fix-utmp.diff
# do not link with libelf, this is not needed
Patch6:		screen-3.9.13-no-libelf.patch
# for portability ? is it needed ? in doubt, let's apply it
Patch7:		screen-3.9.11-biarch-utmp.patch
# add U as default binding to switch to utf8, in /etc/screenrc
Patch8:		screen-4.0.2-screenrc-utf8-switch.patch
# manpage of execl specify that the list should be NULL terminated, so there is a bug
# i however do not know if this fix a crash or anything
Patch9:		screen-4.0.2-varargs.patch
# east asian ambiguous characters
Patch10:	screen-4.0.2-patch-cjkwidth-cvs-2006052001
# add ipv6 support to the builtin telnet client
Patch12:	screen-4.0.3-ipv6.patch
# from git, workaround vte's autodetect DEL
Patch13:	screen-4.0.3-vte-autodetect-workaround.patch
# Prevent format-string errors:
Patch14:        screen-4.0.3-format-string.patch
Requires(post): info-install
Requires(pre):  info-install
BuildRoot:	%{_tmppath}/%{name}-root

%description
The screen utility allows you to have multiple logins on just one
terminal.  Screen is useful for users who telnet into a machine or
are connected via a dumb terminal, but want to use more than just
one login.

Install the screen package if you need a screen manager that can
support multiple logins on one terminal.

%prep

%setup -q
%patch1 -p1
%ifarch ppc
%patch3 -p1
%endif
%patch4 -p1
%patch6 -p1 -b .no-libelf
%patch7 -p1 -b .biarch-utmp
%patch8 -p0
%patch9 -p1 -b .varargs
%patch10 -p0 -b .cjkwidth
%patch12 -p1 -b .ipv6
%patch13 -p2 -b .vte
%patch14 -p1 -b .format-string

%build
%configure2_5x --enable-colors256
perl -pi -e 's|.*#.*PTYMODE.*|#define PTYMODE 0620|' config.h
perl -pi -e 's|.*#.*PTYGROUP.*|#define PTYGROUP 5|' config.h

perl -pi -e 's|.*#undef HAVE_BRAILLE.*|#define HAVE_BRAILLE 1|' config.h
perl -pi -e 's|.*#undef BUILTIN_TELNET.*|#define BUILTIN_TELNET 1|' config.h

perl -pi -e 's|%{_prefix}/etc/screenrc|%{_sysconfdir}/screenrc|' config.h
perl -pi -e 's|/usr/local/etc/screenrc|%{_sysconfdir}/screenrc|' etc/etcscreenrc doc/*
perl -pi -e 's|/local/etc/screenrc|%{_sysconfdir}/screenrc|' doc/*
rm doc/screen.info*

%make CFLAGS="$RPM_OPT_FLAGS -DETCSCREENRC=\\\"%{_sysconfdir}/screenrc\\\""

%install
rm -Rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/skel

%makeinstall SCREENENCODINGS=%buildroot/%{_datadir}/screen/utf8encodings/

( cd $RPM_BUILD_ROOT/%{_bindir} && {
	rm -f screen.old screen
	mv screen-%{version} screen
  }
)

install -c -m 0644 etc/etcscreenrc $RPM_BUILD_ROOT/%{_sysconfdir}/screenrc
install -c -m 0644 etc/screenrc $RPM_BUILD_ROOT/%{_sysconfdir}/skel/.screenrc

mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d

cat > $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d/20screen.sh <<'EOF'
if [ -z "$SCREENDIR" ]; then
    export SCREENDIR=$HOME/tmp
fi
EOF

%clean
rm -fr $RPM_BUILD_ROOT

%post
%_install_info %name.


%preun
%_remove_install_info %name

%files
%defattr(-,root,root)
%doc NEWS README doc/FAQ doc/README.DOTSCREEN ChangeLog
%{_bindir}/screen
%{_mandir}/man1/screen.1*
%{_infodir}/screen.info*
%config(noreplace) %{_sysconfdir}/profile.d/20screen.sh
%config(noreplace) %{_sysconfdir}/screenrc
%attr(644,root,root) %config(noreplace) %{_sysconfdir}/skel/.screenrc
%{_datadir}/screen/




%changelog
* Mon Nov 16 2009 kakurasan <kakurasan AT gmail DOT com> 4.0.3-8kkr2010.0
- cjkwidth support

* Mon Jun 22 2009 Lev Givon <lev AT mandriva DOT org> 4.0.3-7mdv2010.0
+ Revision: 388108
- Refactor ia64 patch.
  Add patch to fix format-string errors.
  Enable 256 color support.

* Mon Oct 13 2008 Funda Wang <fundawang AT mandriva DOT org> 4.0.3-6mdv2009.1
+ Revision: 293321
- add patch from git to wor around vte's del key autodetect feature
  https://savannah.gnu.org/bugs/index.php?23868
- clearify the license

* Wed Jun 18 2008 Thierry Vignaud <tvignaud AT mandriva DOT com> 4.0.3-5mdv2009.0
+ Revision: 225411
- rebuild

  + Olivier Blin <oblin AT mandriva DOT com>
    - restore BuildRoot

* Sat Dec 22 2007 Guillaume Rousse <guillomovitch AT mandriva DOT org> 4.0.3-4mdv2008.1
+ Revision: 137010
- no executable bit on profile scriptlet
  order prefix on profile scriptlet

  + Thierry Vignaud <tvignaud AT mandriva DOT com>
    - kill re-definition of %%buildroot on Pixel's request

* Mon Sep 24 2007 Thierry Vignaud <tvignaud AT mandriva DOT com> 4.0.3-3mdv2008.0
+ Revision: 92613
- fix man pages extension


* Wed Mar 14 2007 Michael Scherer <misc AT mandriva DOT org> 4.0.3-2mdv2007.1
+ Revision: 143661
- remove patch11, was unclear and caused problem ( #29468 )

* Thu Jan 25 2007 Per テvind Karlsen <pkarlsen AT mandriva DOT com> 4.0.3-1mdv2007.1
+ Revision: 113524
- new release: 4.0.3
- bump MAXSTR (string buffer size) to 4k (from 256 bytes), fixes
  status line issues with window list in status line and too many
  windows (and possibly other issues with long strings) (P11 from fedora)
- ipv6 patch (RHBZ #198410)

* Tue Oct 31 2006 Michael Scherer <misc AT mandriva DOT org> 4.0.2-10mdv2007.1
+ Revision: 74233
- Bump release
- document the remaining patchs
-remove patch 5, screen-3.9.11-max-window-size.diff, as it does nothing except setting a constant,
  that is used nowhere in the source ( and nowhere on the internet, according to google code search and
  koders.com )
- remove Patch0, it is applied to a code snippet enclosed in a #if !defined(linux), so it doesn't
  apply to this package, unless we start to port mandriva to bsd.
- bunzip patch
- add fix for CVE-2006-4573
- Import screen

* Tue Sep 19 2006 Gwenole Beauchesne <gbeauchesne AT mandriva DOT com> 4.0.2-9mdv2007.0
- Rebuild

* Fri Jul 21 2006 Michael Scherer <misc AT mandriva DOT org> 4.0.2-8mdv2007.0
- use mkrel
- clean buildRoot

* Mon May 08 2006 Stefan van der Eijk <stefan AT eijk DOT nu> 4.0.2-7mdk
- rebuild for sparc

* Wed Aug 24 2005 Gwenole Beauchesne <gbeauchesne AT mandriva DOT com> 4.0.2-6mdk
- varargs fixes

* Tue Apr 26 2005 Rafael Garcia-Suarez <rgarciasuarez AT mandriva DOT com> 4.0.2-5mdk
- Patch 8: add 'C-a U' binding to /etc/skel/.screenrc

* Tue Nov 09 2004 Rafael Garcia-Suarez <rgarciasuarez AT mandrakesoft DOT com> 4.0.2-4mdk
- The screen profile.d script (and hence $SCREENDIR) was broken

* Thu Oct 14 2004 Olivier Thauvin <thauvin AT aerov.jussieu DOT fr> 4.0.2-3mdk
- don't use a bash fonction to start screen profile.d, exporting SCREENDIR instead

* Wed Apr 21 2004 Olivier Blin <blino AT mandrake DOT org> 4.0.2-2mdk
- rebuild for new libncurses