"Fossies" - the Fresh Open Source Software Archive 
Member "xterm-379/package/xterm.spec" (25 Jan 2023, 7966 Bytes) of package /linux/misc/xterm-379.tgz:
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) RPM Spec source code syntax highlighting (style:
standard) with prefixed line numbers.
Alternatively you can here
view or
download the uninterpreted source code file.
See also the latest
Fossies "Diffs" side-by-side code changes report for "xterm.spec":
377_vs_379.
1 # $XTermId: xterm.spec,v 1.157 2023/01/25 01:14:44 tom Exp $
2 Summary: X terminal emulator (development version)
3 %global my_middle xterm
4 %global my_suffix -dev
5 %global fullname %{my_middle}%{my_suffix}
6 %global my_class XTermDev
7 Name: %{fullname}
8 Version: 379
9 Release: 1
10 License: X11
11 Group: User Interface/X
12 Source: xterm-%{version}.tgz
13 URL: https://invisible-island.net/xterm/
14 Provides: x-terminal-emulator >= %{version}
15
16 # This part (the build-requires) would be useful if the various distributions
17 # had provided stable package-naming, or virtual packages to cover transitions.
18 # However, they have not done this in the past.
19 %define use_x_manpage %(test "x$_use_x_manpage" = xyes && echo 1 || echo 0)
20 %if "%{use_x_manpage}"
21
22 %global is_mandriva %(test -f /etc/mandriva-release && echo %{use_x_manpage} || echo 0)
23 %global is_redhat %(test -f /etc/redhat-release && echo %{use_x_manpage} || echo 0)
24 %global is_suse %(test -f /etc/SuSE-release && echo %{use_x_manpage} || echo 0)
25
26 %if %{is_mandriva}
27 BuildRequires: x11-docs
28 %else
29 %if %{is_redhat}
30 # missing in Fedora 37:
31 ## BuildRequires: xorg-x11-docs
32 BuildRequires: ncurses-devel
33 %else
34 %if %{is_suse}
35 BuildRequires: xorg-docs
36 %endif
37 %endif
38 %endif
39
40 %endif
41
42 %description
43 xterm is the standard terminal emulator for the X Window System.
44 It provides DEC VT102 and Tektronix 4014 compatible terminals for
45 programs that cannot use the window system directly. This version
46 implements ISO/ANSI colors, Unicode, and most of the control sequences
47 used by DEC VT220 terminals.
48
49 This package provides four commands:
50 a) %{fullname}, which is the actual terminal emulator
51 b) u%{fullname}, which is a wrapper around %{fullname}
52 which sets %{fullname} to use UTF-8 encoding when
53 the user's locale supports this,
54 c) koi8r%{fullname}, a wrapper similar to u%{fullname}
55 for locales that use the KOI8-R character set, and
56 d) resize%{my_suffix}.
57
58 A complete list of control sequences supported by the X terminal emulator
59 is provided in /usr/share/doc/%{fullname}.
60
61 The %{fullname} program uses bitmap images provided by the xbitmaps package.
62
63 Those interested in using koi8r%{fullname} will likely want to install the
64 xfonts-cyrillic package as well.
65
66 This package is configured to use "%{fullname}" and "%{my_class}"
67 for the program and its resource class, to avoid conflict with other packages.
68
69 %prep
70
71 %global target_appdata %{fullname}.appdata.xml
72
73 %define desktop_utils %(if which desktop-file-install 2>&1 >/dev/null ; then echo 1 || echo 0 ; fi)
74 %define icon_theme %(test -d /usr/share/icons/hicolor && echo 1 || echo 0)
75 %define apps_x11r6 %(test -d /usr/X11R6/lib/X11/app-defaults && echo 1 || echo 0)
76 %define apps_shared %(test -d /usr/share/X11/app-defaults && echo 1 || echo 0)
77 %define apps_syscnf %(test -d /etc/X11/app-defaults && echo 1 || echo 0)
78
79 %if %{apps_x11r6}
80 %define _xresdir %{_prefix}/X11R6/lib/X11/app-defaults
81 %else
82 %if %{apps_shared}
83 %define _xresdir %{_datadir}/X11/app-defaults
84 %else
85 %define _xresdir %{_sysconfdir}/X11/app-defaults
86 %endif
87 %endif
88
89 %define _iconsdir %{_datadir}/icons
90 %define _pixmapsdir %{_datadir}/pixmaps
91 %define my_docdir %{_datadir}/doc/%{fullname}
92
93 # no need for debugging symbols...
94 %define debug_package %{nil}
95
96 %setup -q -n xterm-%{version}
97
98 %build
99 CPPFLAGS="-DMISC_EXP -DEXP_HTTP_HEADERS" \
100 %configure \
101 --target %{_target_platform} \
102 --prefix=%{_prefix} \
103 --bindir=%{_bindir} \
104 --datadir=%{_datadir} \
105 --mandir=%{_mandir} \
106 %if "%{my_suffix}" != ""
107 --program-suffix=%{my_suffix} \
108 --without-xterm-symlink \
109 %endif
110 %if "%{icon_theme}"
111 --with-icon-symlink=%{fullname} \
112 --with-icon-theme \
113 --with-icondir=%{_iconsdir} \
114 %endif
115 --with-app-class=%{my_class} \
116 --disable-imake \
117 --enable-dabbrev \
118 --enable-dec-locator \
119 --enable-exec-xterm \
120 --enable-hp-fkeys \
121 --enable-load-vt-fonts \
122 --enable-logfile-exec \
123 --enable-logging \
124 --enable-mini-luit \
125 --enable-regis-graphics \
126 --enable-sco-fkeys \
127 --enable-toolbar \
128 --enable-xmc-glitch \
129 --with-app-defaults=%{_xresdir} \
130 --with-pixmapdir=%{_pixmapsdir} \
131 --with-own-terminfo=%{_datadir}/terminfo \
132 --with-terminal-type=xterm-new \
133 --with-utempter \
134 --with-icon-name=mini.xterm \
135 --with-xpm
136 make
137
138 chmod u+w XTerm.ad
139 cat >>XTerm.ad <<EOF
140 *backarrowKeyIsErase: true
141 *ptyInitialErase: true
142 EOF
143 ls -l *.ad
144
145 %install
146 rm -rf $RPM_BUILD_ROOT
147
148 # Usually do not use install-ti, since that will conflict with ncurses.
149 make install-bin install-man install-app install-icon \
150 %if "%{install_ti}" == "yes"
151 install-ti \
152 %endif
153 DESTDIR=$RPM_BUILD_ROOT \
154 TERMINFO=%{_datadir}/terminfo
155
156 mkdir -p $RPM_BUILD_ROOT%{my_docdir}
157 cp \
158 ctlseqs.txt \
159 README.i18n \
160 THANKS \
161 xterm.log.html \
162 $RPM_BUILD_ROOT%{my_docdir}/
163
164 cp -r vttests \
165 $RPM_BUILD_ROOT%{my_docdir}/
166
167 # The scripts are readable, but not executable, to let find-requires
168 # know that they do not depend on Perl packages.
169 chmod 644 $RPM_BUILD_ROOT%{my_docdir}/vttests/*.pl
170
171 %if "%{desktop_utils}"
172 make install-desktop \
173 DESKTOP_FLAGS="--dir $RPM_BUILD_ROOT%{_datadir}/applications"
174
175 test -n "%{my_suffix}" && \
176 ( cd $RPM_BUILD_ROOT%{_datadir}/applications
177 for p in *.desktop
178 do
179 mv $p `basename $p .desktop`%{my_suffix}.desktop
180 done
181 )
182
183 mkdir -p $RPM_BUILD_ROOT%{_datadir}/appdata && \
184 install -m 644 xterm.appdata.xml $RPM_BUILD_ROOT%{_datadir}/appdata/%{target_appdata} && \
185 ( cd $RPM_BUILD_ROOT%{_datadir}/appdata
186 sed -i \
187 -e 's/>xterm\.desktop</>%{fullname}.desktop</' \
188 -e 's/>XTerm</>%{my_class}</' \
189 %{target_appdata}
190 )
191 diff -u xterm.appdata.xml $RPM_BUILD_ROOT%{_datadir}/appdata/%{target_appdata} && \
192 %endif
193
194 %post
195 %if "%{icon_theme}"
196 touch --no-create %{_iconsdir}/hicolor
197 if [ -x %{_bindir}/gtk-update-icon-cache ]; then
198 %{_bindir}/gtk-update-icon-cache %{_iconsdir}/hicolor || :
199 fi
200 %endif
201 # find-requires does not care about at this point
202 chmod +x %{my_docdir}/vttests/*.*
203
204 %postun
205 %if "%{icon_theme}"
206 touch --no-create %{_iconsdir}/hicolor
207 if [ -x %{_bindir}/gtk-update-icon-cache ]; then
208 %{_bindir}/gtk-update-icon-cache %{_iconsdir}/hicolor || :
209 fi
210 %endif
211
212 %clean
213 if rm -rf $RPM_BUILD_ROOT; then
214 echo OK
215 else
216 find $RPM_BUILD_ROOT -type f | grep -F -v /.nfs && exit 1
217 fi
218 exit 0
219
220 %files
221 %defattr(-,root,root,-)
222 %{_bindir}/koi8r%{fullname}
223 %{_bindir}/%{fullname}
224 %{_bindir}/u%{fullname}
225 %{_bindir}/resize%{my_suffix}
226 %{_mandir}/*/*
227 %{my_docdir}/*
228 %{_xresdir}/*XTerm*
229
230 %if "%{install_ti}" == "yes"
231 %{_datadir}/terminfo/*
232 %endif
233
234 %if "%{desktop_utils}"
235 %config(missingok) %{_datadir}/appdata/%{target_appdata}
236 %config(missingok) %{_datadir}/applications/%{fullname}.desktop
237 %config(missingok) %{_datadir}/applications/u%{fullname}.desktop
238 %endif
239
240 %if "%{icon_theme}"
241 %{_iconsdir}/hicolor/*.png
242 %{_iconsdir}/hicolor/*.svg
243 %{_iconsdir}/hicolor/48x48/apps/*.png
244 %{_iconsdir}/hicolor/scalable/apps/*.svg
245 %endif
246 %{_pixmapsdir}/*.xpm
247
248 %changelog
249
250 * Fri Nov 25 2022 Thomas E. Dickey
251 - Fedora 37 has no xorg-x11-docs
252
253 * Thu Feb 24 2022 Thomas E. Dickey
254 - double-buffer is not enabled by default
255
256 * Sat Jul 25 2020 Thomas E. Dickey
257 - sixels are enabled by default
258
259 * Sun Mar 08 2020 Thomas E. Dickey
260 - remove "--vendor" option from desktop-file-install
261
262 * Sun Nov 17 2019 Thomas E. Dickey
263 - install appdata.xml file
264
265 * Wed May 02 2018 Thomas E. Dickey
266 - install all icons
267
268 * Fri Jan 29 2016 Thomas E. Dickey
269 - use --enable-screen-dumps
270
271 * Mon May 27 2013 Thomas E. Dickey
272 - use --with-icon-symlink
273
274 * Mon Oct 08 2012 Thomas E. Dickey
275 - added to pixmapsdir
276
277 * Fri Jun 15 2012 Thomas E. Dickey
278 - modify to support icon theme
279
280 * Fri Oct 22 2010 Thomas E. Dickey
281 - initial version.