]> git.pld-linux.org Git - packages/mc.git/blob - mc.spec
0c7894800e674755cd9b9da1abbb68039b5b497b
[packages/mc.git] / mc.spec
1 #
2 # Conditional build:
3 %bcond_with     ext2undel       # with ext2 undelete fs
4 %bcond_without  perl_vfs        # without perl depending vfs'es -- to avoid perl autoreq
5 %bcond_with     samba           # with SAMBA vfs support
6 %bcond_without  x               # without text edit in X support
7 #
8 Summary:        A user-friendly file manager and visual shell
9 Summary(de.UTF-8):      Visuelle Shell Midnight Commander
10 Summary(es.UTF-8):      Interpretador de comandos visual Midnight Commander
11 Summary(fr.UTF-8):      Un gestionnaire de fichiers puissant et agréable en mode console
12 Summary(hu.UTF-8):      Egy felhasználóbarát fájlkezelő és vizuális shell
13 Summary(ja.UTF-8):      使いやすいファイルマネージャとビジュアルシェル
14 Summary(pl.UTF-8):      Midnight Commander - powłoka wizualna
15 Summary(pt_BR.UTF-8):   Interpretador de comandos visual Midnight Commander
16 Summary(ru.UTF-8):      Диспетчер файлов Midnight Commander
17 Summary(tr.UTF-8):      Midnight Commander görsel kabuğu
18 Summary(uk.UTF-8):      Диспетчер файлів Midnight Commander
19 Summary(zh_CN.UTF-8):   一个方便实用的文件管理器和虚拟Shell
20 Name:           mc
21 Version:        4.8.26
22 Release:        1
23 Epoch:          1
24 License:        GPL v3+
25 Group:          Applications/Shells
26 Source0:        http://ftp.midnight-commander.org/%{name}-%{version}.tar.xz
27 # Source0-md5:  3c1f77b71dba1f4eeeedc4276627fed7
28 Source3:        http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2
29 # Source3-md5:  17d7b574e1b85ad6f8ddceda9e841f19
30 Source7:        %{name}.desktop
31 Source8:        %{name}.png
32 Patch2:         %{name}-no-ws-visible.patch
33 Patch3:         %{name}-noperl-vfs.patch
34 # at now syntax highligthing for PLD-update-TODO and CVSROOT/users
35 Patch4:         %{name}-pld-developerfriendly.patch
36 Patch5:         ebook-ext.patcch
37 URL:            http://www.midnight-commander.org/
38 BuildRequires:  autoconf >= 2.60
39 BuildRequires:  automake >= 1.5
40 %{?with_ext2undel:BuildRequires:        e2fsprogs-devel}
41 BuildRequires:  gettext-tools >= 0.18.1
42 BuildRequires:  glib2-devel >= 1:2.30.0
43 %ifnarch s390 s390x
44 BuildRequires:  gpm-devel
45 %endif
46 BuildRequires:  libssh2-devel >= 1.2.5
47 BuildRequires:  libtool >= 2:2
48 BuildRequires:  pam-devel
49 BuildRequires:  pcre-devel
50 BuildRequires:  pkgconfig
51 BuildRequires:  rpm-pythonprov
52 BuildRequires:  rpmbuild(macros) >= 1.268
53 BuildRequires:  sed >= 4.0
54 BuildRequires:  slang-devel >= 2.2.1
55 %{?with_x:BuildRequires:        xorg-lib-libX11-devel}
56 Requires:       file
57 Requires:       glib2 >= 1:2.30.0
58 Requires:       libssh2 >= 1.2.5
59 Requires:       pam >= 0.77.3
60 Requires:       sed
61 Requires:       setup >= 2.4.6-2
62 Suggests:       bzip2
63 Suggests:       cabextract
64 Suggests:       cdrtools-utils
65 Suggests:       cpio
66 Suggests:       dvi2tty
67 Suggests:       enca
68 Suggests:       file
69 Suggests:       ghostscript
70 Suggests:       groff
71 Suggests:       gzip
72 Suggests:       lha
73 Suggests:       links
74 Suggests:       lynx
75 Suggests:       lzma
76 Suggests:       odt2txt
77 Suggests:       p7zip-standalone
78 Suggests:       perl-tools-pod
79 Suggests:       rar
80 Suggests:       rpm-utils
81 Suggests:       tar
82 Suggests:       unarj
83 Suggests:       unzip
84 Suggests:       xdg-utils
85 Suggests:       xpdf-tools
86 Suggests:       xz
87 Suggests:       zoo
88 Obsoletes:      mc46
89 Obsoletes:      mc46serv
90 Obsoletes:      mcserv
91 Obsoletes:      tkmc
92 Conflicts:      bash < 2.05b
93 Conflicts:      rpm < 4.0
94 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
95
96 %define         specflags_ia32  -fomit-frame-pointer
97
98 %description
99 Midnight Commander is a visual shell much like a file manager, only
100 with way more features. It is text mode, but also includes mouse
101 support if you are running GPM. Its coolest feature is the ability to
102 FTP, view tar, zip files, and poke into RPMs for specific files. :-)
103
104 %description -l de.UTF-8
105 Midnight Commander ist ein Visual-Shell, ähnlich einem Dateimanager,
106 aber mit zusätzlichen Funktionen. Es läuft im Textmodus, kann jedoch
107 eine Maus unterstützen, wenn GPM betrieben wird. Seine coolsten
108 Fähigkeiten sind die FTP-Option, das Einsehen von tar- und zip-Dateien
109 und das Herausfischen von spezifischen Dateien aus RPMs.
110
111 %description -l es.UTF-8
112 Midnight Commander es un interpretador de comandos visual que más
113 parece un administrador de archivos, solamente con varias
114 características a más. Es un programa en modo texto, pero incluye
115 soporte para ratón, si estuviera ejecutando GPM o en una ventana
116 xterm. Su característica más genial es la habilidad de cotillear en
117 RPMs buscando archivos específicos. :-)
118
119 %description -l fr.UTF-8
120 Midnight Commander est une interface pour la ligne de commande qui
121 tient beaucoup du gestionnaire de fichiers, mais est bien plus
122 puissant. Il fonctionne en mode console (texte), mais peut être
123 contrôlé à la souris si GPM est présent. Ses caractéristiques les plus
124 remarquables sont la possibilité de se connecter à un serveur FTP, de
125 visualiser des archives tar, de compresser des fichiers avec zip, de
126 récupérer des fichiers dans les packages RPM, et tout ceci simplement.
127
128 %description -l hu.UTF-8
129 Midnight Commander egy vizuális shell, lényegében egy fájlkezelő
130 sok-sok lehetőséggel. Szöveges módú, de az egeret is támogatja, ha fut
131 a GPM. A legjobb lehetőség az FTP elérése, tar, zip és RPM fájlok
132 kezelése.
133
134 %description -l ja.UTF-8
135 Midnight Commander はいろいろな機能を持ったファイルマネージャ兼
136 ビジュアルシェルです。これはテキストモードのアプリケーションですが、
137 GPM を使っている場合、マウスが使えます。 Midnight Commander には、 FTP
138 に接続できたり、 tar や zip や RPM の中が見えるなど、クールな機能
139 があります。
140
141 %description -l pl.UTF-8
142 Midnight Commander jest wizualną powłoką podobną do Norton Commandera.
143 Pracuje w trybie tekstowym, ale ma także obsługę myszki. Jest super ;)
144 MC ma wbudowanego klienta FTP, może zaglądać do skompresowanych
145 archiwów tar i zip, a także oglądać pliki w pakietach RPM.
146
147 %description -l pt_BR.UTF-8
148 Midnight Commander é um interpretador de comandos visual que mais
149 parece um gerenciador de arquivos, somente com várias características
150 a mais. Ele é um programa de modo texto, mas inclui suporte para mouse
151 se você estiver rodando GPM ou em uma janela xterm. Sua característica
152 mais legal é a habilidade de bisbilhotar em RPMs procurando arquivos
153 específicos. :-)
154
155 %description -l tr.UTF-8
156 Midnight Commander bir dosya yöneticisine çok benzeyen ancak daha
157 yetenekli bir görsel kabuktur. Metin ekranda çalışır ve GPM
158 çalışıyorsa fare desteği vardır. En hoş özellikleri FTP yapabilmesi,
159 tar, zip ve RPM dosyalarının içeriklerini gösterebilmesidir.
160
161 %prep
162 %setup -q -a3
163 %patch2 -p1
164 %{!?with_perl_vfs:%patch3 -p1}
165 %patch4 -p1
166 %patch5 -p1
167
168 %{__rm} po/stamp-po
169
170 %{__sed} -i 's:|hxx|:|hxx|tcc|:' misc/syntax/Syntax.in
171
172 sed -E -i -e '1s,#!\s*/usr/bin/env\s+python2(\s|$),#!%{__python}\1,' -e '1s,#!\s*/usr/bin/env\s+python(\s|$),#!%{__python}\1,' -e '1s,#!\s*/usr/bin/python(\s|$),#!%{__python}\1,' \
173       src/vfs/extfs/helpers/uc1541
174
175 %build
176 %{__gettextize}
177 %{__libtoolize}
178 %{__aclocal} -I m4
179 %{__autoconf}
180 %{__automake}
181
182 export X11_WWW="xdg-open"
183 %configure \
184         PYTHON=%{_bindir}/python3 \
185         %{?with_ext2undel:--enable-vfs-undelfs} \
186         %{?with_samba:--enable-vfs-smb} \
187         --with-smb-configdir=/etc/samba \
188         --with-smb-codepagedir=/etc/samba/codepages \
189         --with%{!?with_x:out}-x \
190         --with-gpm-mouse \
191         --with-pcre \
192         --with-screen=slang \
193         --disable-silent-rules
194
195 %{__make}
196
197 %install
198 rm -rf $RPM_BUILD_ROOT
199 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_pixmapsdir},%{_desktopdir}} \
200         $RPM_BUILD_ROOT/etc/{rc.d/init.d,pam.d,shrc.d,sysconfig} \
201         $RPM_BUILD_ROOT%{_mandir}/man8
202
203 %{__make} install \
204         DESTDIR=$RPM_BUILD_ROOT
205
206 install %{SOURCE7} $RPM_BUILD_ROOT%{_desktopdir}
207 install %{SOURCE8} $RPM_BUILD_ROOT%{_pixmapsdir}
208
209 for a in es pl ; do
210         for b in man1 man8 ; do
211                 install -d $RPM_BUILD_ROOT%{_mandir}/{$a,$a/$b}
212                 for c in man/$a/$b/* ; do
213                         install $c $RPM_BUILD_ROOT%{_mandir}/$a/$b
214                 done
215         done
216 done
217
218 install contrib/{mc.sh,mc.csh} $RPM_BUILD_ROOT/etc/shrc.d
219
220 %{__rm} $RPM_BUILD_ROOT%{_mandir}/*/man8/mcserv.8
221
222 # just a copy of sv
223 %{__rm} $RPM_BUILD_ROOT%{_datadir}/mc/hints/mc.hint.sv_SE
224 # another variant of it
225 %{__rm} $RPM_BUILD_ROOT%{_datadir}/mc/hints/mc.hint.it_IT
226 # enhanced version
227 %{__mv} $RPM_BUILD_ROOT%{_datadir}/mc/hints/mc.hint.{zh,zh_CN}
228
229 %find_lang %{name}
230
231 %clean
232 rm -rf $RPM_BUILD_ROOT
233
234 %files -f %{name}.lang
235 %defattr(644,root,root,755)
236 %doc NEWS README
237 %config /etc/shrc.d/mc.*
238 %attr(755,root,root) %{_bindir}/mc*
239 %dir %{_libexecdir}/mc
240 %attr(755,root,root) %{_libexecdir}/mc/cons.saver
241 %attr(755,root,root) %{_libexecdir}/mc/*.sh
242 %attr(755,root,root) %{_libexecdir}/mc/*.csh
243 %dir %{_datadir}/mc
244
245 %{_datadir}/mc/mc.*
246 %{_datadir}/mc/skins
247 %{_datadir}/mc/syntax
248
249 %dir %{_datadir}/mc/examples
250 %dir %{_datadir}/mc/examples/macros.d
251 %{_datadir}/mc/examples/macros.d/*
252
253 %dir %{_datadir}/mc/help
254 %{_datadir}/mc/help/mc.hlp
255 %lang(es) %{_datadir}/mc/help/mc.hlp.es
256 %lang(hu) %{_datadir}/mc/help/mc.hlp.hu
257 %lang(it) %{_datadir}/mc/help/mc.hlp.it
258 %lang(pl) %{_datadir}/mc/help/mc.hlp.pl
259 %lang(ru) %{_datadir}/mc/help/mc.hlp.ru
260 %lang(sr) %{_datadir}/mc/help/mc.hlp.sr
261 %dir %{_datadir}/mc/hints
262 %{_datadir}/mc/hints/mc.hint
263 # disabled hint files contain only English messages (as for 4.8.26)
264 %lang(be) %{_datadir}/mc/hints/mc.hint.be
265 %lang(bg) %{_datadir}/mc/hints/mc.hint.bg
266 %lang(ca) %{_datadir}/mc/hints/mc.hint.ca
267 %lang(cs) %{_datadir}/mc/hints/mc.hint.cs
268 %lang(da) %{_datadir}/mc/hints/mc.hint.da
269 %lang(de) %{_datadir}/mc/hints/mc.hint.de
270 #%lang(de_CH) %{_datadir}/mc/hints/mc.hint.de_CH
271 %lang(el) %{_datadir}/mc/hints/mc.hint.el
272 %lang(en_GB) %{_datadir}/mc/hints/mc.hint.en_GB
273 %lang(eo) %{_datadir}/mc/hints/mc.hint.eo
274 %lang(es) %{_datadir}/mc/hints/mc.hint.es
275 %lang(et) %{_datadir}/mc/hints/mc.hint.et
276 %lang(eu) %{_datadir}/mc/hints/mc.hint.eu
277 %lang(fa) %{_datadir}/mc/hints/mc.hint.fa
278 %lang(fr) %{_datadir}/mc/hints/mc.hint.fr
279 #%lang(fr_CA) %{_datadir}/mc/hints/mc.hint.fr_CA
280 %lang(ga) %{_datadir}/mc/hints/mc.hint.ga
281 %lang(gl) %{_datadir}/mc/hints/mc.hint.gl
282 %lang(hu) %{_datadir}/mc/hints/mc.hint.hu
283 %lang(id) %{_datadir}/mc/hints/mc.hint.id
284 %lang(it) %{_datadir}/mc/hints/mc.hint.it
285 %lang(ja) %{_datadir}/mc/hints/mc.hint.ja
286 %lang(ko) %{_datadir}/mc/hints/mc.hint.ko
287 %lang(lt) %{_datadir}/mc/hints/mc.hint.lt
288 %lang(nb) %{_datadir}/mc/hints/mc.hint.nb
289 %lang(nl) %{_datadir}/mc/hints/mc.hint.nl
290 %lang(pl) %{_datadir}/mc/hints/mc.hint.pl
291 %lang(pt) %{_datadir}/mc/hints/mc.hint.pt
292 %lang(pt_BR) %{_datadir}/mc/hints/mc.hint.pt_BR
293 %lang(ro) %{_datadir}/mc/hints/mc.hint.ro
294 %lang(ru) %{_datadir}/mc/hints/mc.hint.ru
295 %lang(sk) %{_datadir}/mc/hints/mc.hint.sk
296 %lang(sr) %{_datadir}/mc/hints/mc.hint.sr
297 %lang(sv) %{_datadir}/mc/hints/mc.hint.sv
298 %lang(tr) %{_datadir}/mc/hints/mc.hint.tr
299 %lang(uk) %{_datadir}/mc/hints/mc.hint.uk
300 %lang(zh_CN) %{_datadir}/mc/hints/mc.hint.zh_CN
301 %lang(zh_TW) %{_datadir}/mc/hints/mc.hint.zh_TW
302
303 %dir %{_libexecdir}/mc/ext.d
304 %attr(755,root,root) %{_libexecdir}/mc/ext.d/archive.sh
305 %attr(755,root,root) %{_libexecdir}/mc/ext.d/doc.sh
306 %attr(755,root,root) %{_libexecdir}/mc/ext.d/image.sh
307 %attr(755,root,root) %{_libexecdir}/mc/ext.d/misc.sh
308 %attr(755,root,root) %{_libexecdir}/mc/ext.d/package.sh
309 %attr(755,root,root) %{_libexecdir}/mc/ext.d/sound.sh
310 %attr(755,root,root) %{_libexecdir}/mc/ext.d/text.sh
311 %attr(755,root,root) %{_libexecdir}/mc/ext.d/video.sh
312 %attr(755,root,root) %{_libexecdir}/mc/ext.d/web.sh
313
314 %dir %{_libexecdir}/mc/extfs.d
315 %{_libexecdir}/mc/extfs.d/README*
316 %if %{with perl_vfs}
317 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/a+
318 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/apt+
319 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/deb*
320 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/dpkg+
321 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/mailfs
322 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/patchfs
323 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/rpms+
324 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/ulib
325 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uzip
326 %endif
327 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/audio
328 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/bpp
329 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/changesetfs
330 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/gitfs+
331 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/hp48+
332 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/iso9660
333 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/lslR
334 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/patchsetfs
335 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/rpm
336 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/s3+
337 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/trpm
338 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/u7z
339 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uace
340 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/ualz
341 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uar*
342 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uc1541
343 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/ucab
344 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uha
345 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/ulha
346 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/unar
347 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/urar
348 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uwim
349 %attr(755,root,root) %{_libexecdir}/mc/extfs.d/uzoo
350 %dir %{_libexecdir}/mc/fish
351 %{_libexecdir}/mc/fish/README.fish
352 %attr(755,root,root) %{_libexecdir}/mc/fish/[a-z]*
353 %{_desktopdir}/mc.desktop
354 %{_pixmapsdir}/mc.png
355
356 %{_mandir}/man1/mc.1*
357 %{_mandir}/man1/mcedit.1*
358 %{_mandir}/man1/mcview.1*
359 %lang(es) %{_mandir}/es/man1/*
360 %lang(hu) %{_mandir}/hu/man1/*
361 %lang(it) %{_mandir}/it/man1/*
362 %lang(pl) %{_mandir}/pl/man1/*
363 %lang(ru) %{_mandir}/ru/man1/*
364 %lang(sr) %{_mandir}/sr/man1/*
365
366 %dir %{_sysconfdir}/mc
367 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mc/*.*
This page took 0.116481 seconds and 3 git commands to generate.