xterm.spec revision e39b573c
1# $XTermId: xterm.spec,v 1.13 2011/07/14 22:15:37 tom Exp $ 2Summary: A text-based Web browser 3Name: xterm-dev 4Version: 271 5Release: 1 6License: X11 7Group: Applications/Internet 8Source: xterm-%{version}.tgz 9# URL: http://invisible-island.net/xterm/ 10Provides: x-terminal-emulator 11 12%description 13xterm is the standard terminal emulator for the X Window System. 14It provides DEC VT102 and Tektronix 4014 compatible terminals for 15programs that cannot use the window system directly. This version 16implements ISO/ANSI colors, Unicode, and most of the control sequences 17used by DEC VT220 terminals. 18 19This package provides four commands: 20 a) xterm, which is the actual terminal emulator 21 b) uxterm, which is a wrapper around xterm which sets xterm to use UTF-8 22 encoding when the user's locale supports this, 23 c) koi8rxterm, a wrapper similar to uxterm for locales that use the 24 KOI8-R character set, and 25 d) resize. 26 27A complete list of control sequences supported by the X terminal emulator 28is provided in /usr/share/doc/xterm. 29 30The xterm program uses bitmap images provided by the xbitmaps package. 31 32Those interested in using koi8rxterm will likely want to install the 33xfonts-cyrillic package as well. 34 35This package is configured to use "xterm-dev" and "XTermDev" for the program 36and its resource class, to avoid conflict with other packages. 37 38%prep 39 40%define my_suffix -dev 41%define my_class XTermDev 42 43%define desktop_vendor dickey 44%define desktop_utils %(if which desktop-file-install 2>&1 >/dev/null ; then echo "yes" ; fi) 45 46%define apps_shared %(test -d /usr/share/X11/app-defaults && echo 1 || echo 0) 47%define apps_syscnf %(test -d /etc/X11/app-defaults && echo 1 || echo 0) 48 49%if %{apps_shared} 50%define _xresdir %{_datadir}/X11/app-defaults 51%else 52%define _xresdir %{_sysconfdir}/X11/app-defaults 53%endif 54 55%define _iconsdir %{_datadir}/icons 56%define _pixmapsdir %{_datadir}/pixmaps 57%define my_docdir %{_datadir}/doc/xterm%{my_suffix} 58 59%setup -q -n xterm-%{version} 60 61%build 62CPPFLAGS="-DMISC_EXP -DEXP_HTTP_HEADERS" \ 63%configure \ 64 --target %{_target_platform} \ 65 --prefix=%{_prefix} \ 66 --bindir=%{_bindir} \ 67 --datadir=%{_datadir} \ 68 --mandir=%{_mandir} \ 69%if "%{my_suffix}" != "" 70 --program-suffix=%{my_suffix} \ 71 --without-xterm-symlink \ 72%endif 73 --with-app-class=%{my_class} \ 74 --enable-256-color \ 75 --enable-88-color \ 76 --enable-dabbrev \ 77 --enable-dec-locator \ 78 --enable-exec-xterm \ 79 --enable-hp-fkeys \ 80 --enable-load-vt-fonts \ 81 --enable-logfile-exec \ 82 --enable-logging \ 83 --enable-mini-luit \ 84 --enable-paste64 \ 85 --enable-rectangles \ 86 --enable-sco-fkeys \ 87 --enable-tcap-fkeys \ 88 --enable-tcap-query \ 89 --enable-toolbar \ 90 --enable-wide-chars \ 91 --enable-xmc-glitch \ 92 --with-app-defaults=%{_xresdir} \ 93 --with-icondir=%{_pixmapsdir} \ 94 --with-own-terminfo=%{_datadir}/terminfo \ 95 --with-terminal-type=xterm-new \ 96 --with-utempter 97make 98 99chmod u+w XTerm.ad 100cat >>XTerm.ad <<EOF 101*backarrowKeyIsErase: true 102*ptyInitialErase: true 103EOF 104ls -l *.ad 105 106%install 107rm -rf $RPM_BUILD_ROOT 108 109# Usually do not use install-ti, since that will conflict with ncurses. 110make install-bin install-man install-app install-icon \ 111%if "%{install_ti}" == "yes" 112 install-ti \ 113%endif 114 DESTDIR=$RPM_BUILD_ROOT \ 115 TERMINFO=%{_datadir}/terminfo 116 117 mkdir -p $RPM_BUILD_ROOT%{my_docdir} 118 cp \ 119 ctlseqs.txt \ 120 README.i18n \ 121 THANKS \ 122 xterm.log.html \ 123 $RPM_BUILD_ROOT%{my_docdir}/ 124 125 cp -r vttests \ 126 $RPM_BUILD_ROOT%{my_docdir}/ 127 128 # The scripts are readable, but not executable, to let find-requires 129 # know that they do not depend on Perl packages. 130 chmod 644 $RPM_BUILD_ROOT%{my_docdir}/vttests/* 131 132%if "%{desktop_utils}" == "yes" 133make install-desktop \ 134 DESKTOP_FLAGS="--vendor='%{desktop_vendor}' --dir $RPM_BUILD_ROOT%{_datadir}/applications" 135 136test -n "%{my_suffix}" && \ 137( cd $RPM_BUILD_ROOT%{_datadir}/applications 138 for p in *.desktop 139 do 140 mv $p `basename $p .desktop`%{my_suffix}.desktop 141 done 142) 143%endif 144 145%clean 146rm -rf $RPM_BUILD_ROOT 147 148%files 149%defattr(-,root,root,-) 150%{_bindir}/koi8rxterm%{my_suffix} 151%{_bindir}/xterm%{my_suffix} 152%{_bindir}/uxterm%{my_suffix} 153%{_bindir}/resize%{my_suffix} 154%{_mandir}/*/* 155%{my_docdir}/* 156%{_pixmapsdir}/xterm*.xpm 157%{_xresdir}/*XTerm* 158 159%if "%{install_ti}" == "yes" 160%{_datadir}/terminfo/* 161%endif 162 163%if "%{desktop_utils}" == "yes" 164%config(missingok) %{_datadir}/applications/%{desktop_vendor}-xterm%{my_suffix}.desktop 165%config(missingok) %{_datadir}/applications/%{desktop_vendor}-uxterm%{my_suffix}.desktop 166%endif 167 168%changelog 169 170* Fri Oct 22 2010 Thomas E. Dickey 171- initial version. 172