]> git.pld-linux.org Git - packages/vim.git/blob - vim.spec
bacea6c20fcc98029c2eeba5a3fb8952ddd7c67d
[packages/vim.git] / vim.spec
1 #
2 # Conditional build:
3 # _without_static       - without static version
4 # _without_athena       - without Athena Widgets-based gvim
5 # _without_motif        - without Motif-based gvim
6 # _without_gtk          - without gtk+-based gvim support
7 # _without_gnome        - without gnome-based gvim support
8 # _with_ispell          - with spell checking (non-standard feature; disables RIGHTLEFT and FKMAP)
9 #
10 Summary:        Vi IMproved - a Vi clone
11 Summary(de):    VIsual editor iMproved
12 Summary(fr):    editeur VIM : VIsual editor iMproved
13 Summary(pl):    Vi IMproved - klon edytora Vi
14 Summary(tr):    Geliþmiþ bir vi sürümü
15 Name:           vim
16 Version:        6.0
17 Release:        1
18 Epoch:          4
19 License:        Charityware
20 Group:          Applications/Editors/Vim
21 Group(de):      Applikationen/Editors/Vim
22 Group(pl):      Aplikacje/Edytory/Vim
23 Source0:        ftp://ftp.vim.org/pub/editors/vim/unix/%{name}-%{version}.tar.bz2
24 Source1:        ftp://ftp.vim.org/pub/editors/vim/extra/%{name}-%{version}-lang.tar.gz
25 #Source2:       ftp://ftp.vim.org/pub/editors/vim/extra/%{name}-%{version}-extra.tar.gz
26 Source3:        g%{name}-athena.desktop
27 Source4:        g%{name}-motif.desktop
28 Source5:        g%{name}-gtk.desktop
29 Source6:        g%{name}-gnome.desktop
30 Patch0:         %{name}-sysconfdir.patch
31 Patch1:         %{name}-visual.patch
32 Patch2:         %{name}-phphighlight.patch
33 Patch3:         %{name}-paths.patch
34 Patch4:         %{name}-ispell.patch
35 Patch5:         %{name}-pl.patch
36 Patch6:         %{name}-shsyntax.patch
37 URL:            http://www.vim.org/
38 BuildRequires:  gpm-devel
39 BuildRequires:  ncurses-devel
40 %{!?_without_athena:BuildRequires:      Xaw3d-devel}
41 %{!?_without_gnome:BuildRequires:       esound-devel}
42 %{!?_without_gnome:BuildRequires:       gnome-libs-devel}
43 %{!?_without_gtk:BuildRequires: gtk+-devel}
44 %{!?_without_motif:BuildRequires:       motif-devel}
45 %{!?_without_static:BuildRequires:      glibc-static}
46 %{!?_without_static:BuildRequires:      ncurses-static}
47 Requires:       %{name}-rt = %{version}
48 %{?_without_static:Requires:    %{name}-static = %{version}}
49 Obsoletes:      vim-enhanced
50 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
51
52 %description
53 Text editor similar to Vi. Important improvements: multiple windows,
54 multi-level undo, block highliting, and many other.
55
56 %description -l de
57 Der Visual-Editor iMproved ist ein aktualisierter und erweiterter Klon
58 des vi-Editors, der mit praktisch allen UN*X-Systemen ausgeliefert
59 wird. Er bringt mehrere Fenster, mehrstufige Widerrufen-Funktion,
60 Block-Markierung und viele weitere Zusatzfunktionen im Vergleich zum
61 Standard-vi-Programm.
62
63 %description -l fr
64 L'éditeur VIsuel aMélioré est un clone mis à jour et doté de
65 caractéristiques supplémentaires de l'éditeur « vi » fourni avec
66 pratiquement tous les systèmes UN*X. Il ajoute les fenêtres
67 mutltiples, l'annulation a plusieurs niveaux, la mise en évidence des
68 blocs et autres caractéristiques au vi de base.
69
70 %description -l pl
71 Edytor tekstu podobny do Vi. Wa¿ne ulepszenia: mo¿liwo¶æ pracy w wielu
72 oknach, wielopoziomowa opcja 'cofnij', bloki, pod¶wietlanie sk³adni
73 i wiele innych.
74
75 %description -l tr
76 Standart vi metin düzenleyicisinin geliþmiþ hali; daha fazla komut,
77 birden fazla pencere desteði ve blok iþaretleme yetenekleri içerir.
78
79 %package -n xxd
80 Summary:        Utility to convert files to hexdump or do the reverse
81 Summary(pl):    Narzêdzie do zamiany plików na postaæ szesnastkow± i odwrotnie
82 Group:          Applications/Editors/Vim
83 Group(de):      Applikationen/Editors/Vim
84 Group(pl):      Aplikacje/Edytory/Vim
85
86 %description -n xxd
87 xxd creates a hex dump of a given file or standard input. It can also
88 convert a hex dump back to its original binary form. Like uuencode and
89 uudecode it allows the transmission of binary data in a `mail-safe'
90 ASCII representation, but has the advantage of decoding to standard
91 output. Moreover, it can be used to perform binary file patching.
92
93 %description -n xxd -l pl
94 xxd tworzy szesnastkowy zapis pliku podanego na standardowe wej¶cie.
95 Mo¿e tak¿e przekonwertowaæ taki zapis na oryginaln±, binarn± postaæ.
96 Podobnie jak uuencode i uudecode pozwala na przesy³anie danych
97 binarnych w postaci ASCII, ale ma mo¿liwo¶æ dekodowania na standardowe
98 wyj¶cie. Co wiêcej, mo¿e byæ u¿yty do modyfikowania plików binarnych.
99
100 %package static
101 Summary:        Staticly linked Vim
102 Summary(pl):    Statycznie zlinkowany Vim
103 Group:          Applications/Editors/Vim
104 Group(de):      Applikationen/Editors/Vim
105 Group(pl):      Aplikacje/Edytory/Vim
106 Provides:       vi
107 Obsoletes:      vi
108 Obsoletes:      vim-minimal
109
110 %description static
111 Text editor similar to Vi. This version is build with minimal feature
112 and is installed in /bin as a rescue tool. The installation of this
113 package is STRONGLY recommended.
114
115 %description static -l pl
116 Edytor tekstu podobny do Vi. Ta wersja zosta³a skompilowana statycznie
117 i posiada minimaln± ilo¶æ dodatków. Jest instalowana w /bin jako
118 narzêdzie dla administratora. Instalacja tego pakietu jest MOCNO
119 zalecana, mo¿e on pomóc Ci uratowaæ system w czasie awarii.
120
121 %package rt
122 Summary:        Vim runtime files
123 Summary(pl):    Pliki przydatne edytorowi Vim
124 Group:          Applications/Editors/Vim
125 Group(de):      Applikationen/Editors/Vim
126 Group(pl):      Aplikacje/Edytory/Vim
127 Requires:       mktemp
128 Requires:       which
129 Obsoletes:      vim-common
130
131 %description rt
132 This package contains macros, documentation, syntax configuration and
133 manual pages for vim. If you want to take advantage of vim more
134 powerful features, you should install this package.
135
136 %description rt -l pl
137 W tym pakiecie znajdziesz dokumentacjê, makra, pliki konfiguracyjne i
138 strony podrêcznika dla edytora vim. Je¿eli chcesz korzystaæ z
139 zaawansowanych mo¿liwo¶ci vim-a, powiniene¶ zainstalowaæ ten pakiet.
140
141 %package -n gvim-athena
142 Summary:        Vim for X Window built with Athena
143 Summary(pl):    Vim dla X Window korzystaj±cy z biblioteki Athena
144 Group:          Applications/Editors/Vim
145 Group(de):      Applikationen/Editors/Vim
146 Group(pl):      Aplikacje/Edytory/Vim
147 Requires:       %{name}-rt = %{version}
148 Requires:       iconv
149 Obsoletes:      vim-X11
150
151 %description -n gvim-athena
152 The classic Unix text editor now also under X Window System! This
153 version is build with Athena Widget Set.
154
155 %description -n gvim-athena -l pl
156 Wersja edytora Vim pracuj±ca w ¶rodowisku X Window z wykorzystaniem
157 biblioteki Athena Widget Set.
158
159 %package -n gvim-motif
160 Summary:        Vim for X Window built with Motif
161 Summary(pl):    Vim dla X Window korzystaj±cy z biblioteki Motif
162 Group:          Applications/Editors/Vim
163 Group(de):      Applikationen/Editors/Vim
164 Group(pl):      Aplikacje/Edytory/Vim
165 Requires:       %{name}-rt = %{version}
166 Requires:       iconv
167 Obsoletes:      vim-X11
168
169 %description -n gvim-motif
170 The classic Unix text editor now also under X Window System! This
171 version is build with Motif.
172
173 %description -n gvim-motif -l pl
174 Wersja edytora Vim pracuj±ca w ¶rodowisku X Window z wykorzystaniem
175 biblioteki Motif.
176
177 %package -n gvim-gtk
178 Summary:        Vim for X Window built with gtk
179 Summary(pl):    Vim dla X Window korzystaj±cy z biblioteki GTK
180 Group:          Applications/Editors/Vim
181 Group(de):      Applikationen/Editors/Vim
182 Group(pl):      Aplikacje/Edytory/Vim
183 Requires:       %{name}-rt = %{version}
184 Requires:       iconv
185 Obsoletes:      vim-X11
186
187 %description -n gvim-gtk
188 The classic Unix text editor now also under X Window System! This
189 version is build with GTK.
190
191 %description -n gvim-gtk -l pl
192 Wersja edytora vim pracuj±ca w ¶rodowisku X Window z wykorzystaniem
193 biblioteki GTK.
194
195 %package -n gvim-gnome
196 Summary:        Vim for X Window built with gnome
197 Summary(pl):    Vim dla X Window korzystaj±cy z biblioteki GNOME
198 Group:          Applications/Editors/Vim
199 Group(de):      Applikationen/Editors/Vim
200 Group(pl):      Aplikacje/Edytory/Vim
201 Requires:       %{name}-rt = %{version}
202 Requires:       iconv
203 Obsoletes:      vim-X11
204
205 %description -n gvim-gnome
206 The classic Unix text editor now also under X Window System! This
207 version is build with GNOME.
208
209 %description -n gvim-gnome -l pl
210 Wersja edytora vim pracuj±ca w ¶rodowisku X Window z wykorzystaniem
211 bibliotek GNOME.
212
213 %prep
214 %setup -q -b1 -n %{name}%(echo %{version} | sed -e "s#\.##g")
215 %patch0 -p1
216 %patch1 -p1
217 %patch2 -p1
218 %patch3 -p1
219 %{?_with_ispell:%patch4 -p1}
220 %patch5 -p1
221 %patch6 -p1
222
223 %build
224 cd src
225 autoconf
226 %configure \
227         --disable-gui \
228         --without-x \
229         --disable-perlinterp \
230         --disable-pythoninterp \
231         --disable-tclinterp \
232         --disable-rubyinterp \
233         --enable-cscope \
234         --enable-gpm \
235         --with-features=huge \
236         --enable-multibyte \
237         --with-tlib=ncurses \
238         --enable-nls
239
240 %{__make} vim
241 mv -f vim vim.ncurses
242
243 %{__make} xxd/xxd
244
245 %if %{!?_without_static:1}%{?_without_static:0}
246 %{__make} distclean
247 LDFLAGS="%{rpmldflags} -static"
248 %configure \
249         --disable-gui \
250         --without-x \
251         --disable-perlinterp \
252         --disable-pythoninterp \
253         --disable-tclinterp \
254         --disable-cscope \
255         --disable-gpm \
256         --disable-multibyte \
257         --with-features=small \
258         --with-tlib=tinfo \
259         --disable-nls
260
261 %{__make} vim
262 mv -f vim vim.static
263 %endif
264
265 %if %{!?_without_athena:1}%{?_without_athena:0}
266 %{__make} distclean
267 LDFLAGS="%{rpmldflags}"
268 %configure \
269         --with-features=huge \
270         --enable-gui=athena \
271         --with-x \
272         --disable-perlinterp \
273         --disable-pythoninterp \
274         --disable-tclinterp \
275         --disable-rubyinterp \
276         --enable-cscope \
277         --enable-fontset \
278         --disable-gpm \
279         --without-gnome \
280         --enable-nls
281 %{__make} vim
282 mv -f vim gvim.athena
283 %endif
284
285 %if %{!?_without_motif:1}%{?_without_motif:0}
286 %{__make} distclean
287 %configure \
288         --with-features=huge \
289         --enable-gui=motif \
290         --with-x \
291         --disable-perlinterp \
292         --disable-pythoninterp \
293         --disable-tclinterp \
294         --disable-rubyinterp \
295         --enable-multibyte \
296         --enable-cscope \
297         --enable-fontset \
298         --disable-gpm \
299         --without-gnome \
300         --enable-nls
301 %{__make} vim
302 mv -f vim gvim.motif
303 %endif
304
305 %if %{!?_without_gtk:1}%{?_without_gtk:0}
306 %{__make} distclean
307 %configure \
308         --with-features=huge \
309         --enable-gui=gtk \
310         --with-x \
311         --disable-perlinterp \
312         --disable-pythoninterp \
313         --disable-tclinterp \
314         --disable-rubyinterp \
315         --disable-gpm \
316         --enable-cscope \
317         --enable-fontset \
318         --enable-nls
319 %{__make} vim
320 mv -f vim gvim.gtk
321 %endif
322
323 %if %{!?_without_gnome:1}%{?_without_gnome:0}
324 %{__make} distclean
325 %configure \
326         --with-features=huge \
327         --enable-gui=gnome \
328         --with-x \
329         --disable-perlinterp \
330         --disable-pythoninterp \
331         --disable-tclinterp \
332         --disable-rubyinterp \
333         --disable-gpm \
334         --enable-cscope \
335         --enable-fontset \
336         --enable-nls
337 %{__make} vim
338 mv -f vim gvim.gnome
339 %endif
340
341 %install
342 rm -rf $RPM_BUILD_ROOT
343 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/vim,%{_bindir}} \
344         $RPM_BUILD_ROOT{/bin,%{_mandir}/man1,%{_datadir}/vim} \
345         $RPM_BUILD_ROOT{%{_prefix}/X11R6/bin,%{_applnkdir}/Development/Editors}
346
347 %{__make} install DESTDIR=$RPM_BUILD_ROOT
348 rm $RPM_BUILD_ROOT%{_bindir}/*
349
350 %{!?_without_static:install src/vim.ncurses     $RPM_BUILD_ROOT%{_bindir}/vim}
351 %{?_without_static:install src/vim.ncurses      $RPM_BUILD_ROOT/bin/vi}
352 %{!?_without_static:install src/vim.static      $RPM_BUILD_ROOT/bin/vi}
353 %{?_without_static:ln -sf /bin/vi               $RPM_BUILD_ROOT%{_bindir}/vim}
354 install src/xxd/xxd                             $RPM_BUILD_ROOT%{_bindir}/xxd
355 install src/vimtutor                            $RPM_BUILD_ROOT%{_bindir}/vimtutor
356
357 rm -f $RPM_BUILD_ROOT%{_mandir}/man1/*.1
358
359 install runtime/doc/vim.1 $RPM_BUILD_ROOT%{_mandir}/man1
360 install runtime/doc/xxd.1 $RPM_BUILD_ROOT%{_mandir}/man1
361
362 install runtime/doc/vimtutor.1 $RPM_BUILD_ROOT%{_mandir}/man1
363
364 echo ".so vim.1" > $RPM_BUILD_ROOT%{_mandir}/man1/ex.1
365 echo ".so vim.1" > $RPM_BUILD_ROOT%{_mandir}/man1/rview.1
366 echo ".so vim.1" > $RPM_BUILD_ROOT%{_mandir}/man1/rvim.1
367 echo ".so vim.1" > $RPM_BUILD_ROOT%{_mandir}/man1/vi.1
368 echo ".so vim.1" > $RPM_BUILD_ROOT%{_mandir}/man1/view.1
369
370 mv -f $RPM_BUILD_ROOT%{_datadir}/vim/v*/vimrc_example.vim $RPM_BUILD_ROOT%{_sysconfdir}/vim/vimrc
371 mv -f $RPM_BUILD_ROOT%{_datadir}/vim/v*/gvimrc_example.vim $RPM_BUILD_ROOT%{_sysconfdir}/vim/gvimrc
372
373 ln -sf vim $RPM_BUILD_ROOT%{_bindir}/rvim
374 ln -sf vi  $RPM_BUILD_ROOT/bin/ex
375 ln -sf vi  $RPM_BUILD_ROOT/bin/view
376 ln -sf vi  $RPM_BUILD_ROOT/bin/rview
377
378 %{!?_without_athena:install src/gvim.athena     $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/gvim.athena}
379 %{!?_without_motif: install src/gvim.motif      $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/gvim.motif}
380 %{!?_without_gtk:   install src/gvim.gtk        $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/gvim.gtk}
381 %{!?_without_gnome: install src/gvim.gnome      $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/gvim.gnome}
382
383 %{!?_without_gtk:ln -sf gvim.gtk                $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/gvim}
384 %{!?_without_gtk:ln -sf gvim                    $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/rgvim}
385 %{!?_without_gtk:ln -sf gvim                    $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/gview}
386 %{!?_without_gtk:ln -sf gvim                    $RPM_BUILD_ROOT%{_prefix}/X11R6/bin/rgview}
387
388 %{!?_without_athena:install %{SOURCE3}          $RPM_BUILD_ROOT%{_applnkdir}/Development/Editors}
389 %{!?_without_motif: install %{SOURCE4}          $RPM_BUILD_ROOT%{_applnkdir}/Development/Editors}
390 %{!?_without_gtk:   install %{SOURCE5}          $RPM_BUILD_ROOT%{_applnkdir}/Development/Editors}
391 %{!?_without_gnome: install %{SOURCE6}          $RPM_BUILD_ROOT%{_applnkdir}/Development/Editors}
392
393 %clean
394 rm -rf $RPM_BUILD_ROOT
395
396 %files
397 %defattr(644,root,root,755)
398 %attr(755,root,root) %{_bindir}/vim
399 %attr(755,root,root) %{_bindir}/rvim
400
401 %files -n xxd
402 %defattr(644,root,root,755)
403 %attr(755,root,root) %{_bindir}/xxd
404 %{_mandir}/man1/xxd.1*
405
406 %files static
407 %defattr(644,root,root,755)
408 %attr(755,root,root) /bin/*
409
410 %{_mandir}/man1/vi.1*
411 %{_mandir}/man1/ex.1*
412 %{_mandir}/man1/view.1*
413 %{_mandir}/man1/rview.1*
414
415 %files rt
416 %defattr(644,root,root,755)
417 %attr(755,root,root) %{_bindir}/vimtutor
418 %dir %{_sysconfdir}/vim
419 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/vim/vimrc
420 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/vim/gvimrc
421
422 %dir %{_datadir}/vim
423 %dir %{_datadir}/vim/v*
424 %{_datadir}/vim/v*/doc
425 %{_datadir}/vim/v*/ftplugin
426 %{_datadir}/vim/v*/indent
427 %{_datadir}/vim/v*/keymap
428 %dir %{_datadir}/vim/v*/lang
429 %{_datadir}/vim/v*/lang/README*
430 %lang(af) %{_datadir}/vim/v*/lang/*af*
431 %lang(cs) %{_datadir}/vim/v*/lang/*cs*
432 %lang(de) %{_datadir}/vim/v*/lang/*de*
433 %lang(es) %{_datadir}/vim/v*/lang/es
434 %lang(es) %{_datadir}/vim/v*/lang/*es_es*
435 %lang(es) %{_datadir}/vim/v*/lang/*spanish*
436 %lang(fr) %{_datadir}/vim/v*/lang/*fr*
437 %lang(hu) %{_datadir}/vim/v*/lang/*hu*
438 %lang(nl) %{_datadir}/vim/v*/lang/*nl*
439 %lang(it) %{_datadir}/vim/v*/lang/*it*
440 %lang(ja) %{_datadir}/vim/v*/lang/*ja*
441 %lang(ko) %{_datadir}/vim/v*/lang/*ko*
442 %lang(pl) %{_datadir}/vim/v*/lang/*pl*
443 %lang(zh_TW) %{_datadir}/vim/v*/lang/*zh*
444 %{_datadir}/vim/v*/macros
445 %{_datadir}/vim/v*/plugin
446 %{_datadir}/vim/v*/syntax
447 %{_datadir}/vim/v*/tutor
448 %{_datadir}/vim/v*/colors
449 %{_datadir}/vim/v*/compiler
450 %{_datadir}/vim/v*/*.vim
451 %{_datadir}/vim/v*/*.ps
452
453 %{_mandir}/man1/vim.*
454 %{_mandir}/man1/rvim.*
455
456 %if %{!?_without_athena:1}%{?_without_athena:0}
457 %files -n gvim-athena
458 %defattr(644,root,root,755)
459 %attr(755,root,root) %{_prefix}/X11R6/bin/gvim.athena
460 %{_applnkdir}/Development/Editors/gvim-athena.desktop
461 %endif
462
463 %if %{!?_without_motif:1}%{?_without_motif:0}
464 %files -n gvim-motif
465 %defattr(644,root,root,755)
466 %attr(755,root,root) %{_prefix}/X11R6/bin/gvim.motif
467 %{_applnkdir}/Development/Editors/gvim-motif.desktop
468 %endif
469
470 %if %{!?_without_gtk:1}%{?_without_gtk:0}
471 %files -n gvim-gtk
472 %defattr(644,root,root,755)
473 %attr(755,root,root) %{_prefix}/X11R6/bin/gvim.gtk
474 %attr(755,root,root) %{_prefix}/X11R6/bin/rgvim
475 %attr(755,root,root) %{_prefix}/X11R6/bin/rgview
476 %attr(755,root,root) %verify(not link) %{_prefix}/X11R6/bin/gvim
477 %{_applnkdir}/Development/Editors/gvim-gtk.desktop
478 %endif
479
480 %if %{!?_without_gnome:1}%{?_without_gnome:0}
481 %files -n gvim-gnome
482 %defattr(644,root,root,755)
483 %attr(755,root,root) %{_prefix}/X11R6/bin/gvim.gnome
484 %{_applnkdir}/Development/Editors/gvim-gnome.desktop
485 %endif
This page took 0.05881 seconds and 2 git commands to generate.