]> git.pld-linux.org Git - packages/mc.git/blame - mc.spec
- rel 0.3; switch to slang library; ncurses lack some features (or mc is not ready...
[packages/mc.git] / mc.spec
CommitLineData
d78cba00 1# TODO:
d78cba00 2# - check spec-syntax,mo patches
5a0ca66d 3# - update ancient X11_WWW (or drop if it's no longer used)
afbb79ff
JB
4#
5# Conditional build:
69d23796 6%bcond_with ext2undel # with ext2 undelete fs
26aa770b 7%bcond_without perl_vfs # without perl depending vfs'es -- to avoid perl autoreq
69d23796 8%bcond_with samba # with SAMBA vfs support
4341efe2 9%bcond_without x # without text edit in X support
afbb79ff 10#
db2935bf 11%define snap pre2
9ef7c013 12Summary: A user-friendly file manager and visual shell
7defc305
ER
13Summary(de.UTF-8): Visuelle Shell Midnight Commander
14Summary(es.UTF-8): Interpretador de comandos visual Midnight Commander
15Summary(fr.UTF-8): Un gestionnaire de fichiers puissant et agréable en mode console
16Summary(ja.UTF-8): 使いやすいファイルマネージャとビジュアルシェル
17Summary(pl.UTF-8): Midnight Commander - powłoka wizualna
18Summary(pt_BR.UTF-8): Interpretador de comandos visual Midnight Commander
19Summary(ru.UTF-8): Диспетчер файлов Midnight Commander
20Summary(tr.UTF-8): Midnight Commander görsel kabuğu
21Summary(uk.UTF-8): Диспетчер файлів Midnight Commander
22Summary(zh_CN.UTF-8): 一个方便实用的文件管理器和虚拟Shell
06df6411 23Name: mc
db2935bf 24Version: 4.7.0
e573ba19 25Release: 0.3
5a0ca66d 26License: GPL v2+
51719b27 27Group: Applications/Shells
db2935bf
AM
28Source0: http://www.midnight-commander.org/downloads/%{name}-%{version}-%{snap}.tar.bz2
29# Source0-md5: 347d0144709ed342302787e314146eef
51719b27 30Source1: %{name}serv.pamd
31Source2: %{name}serv.init
f187cfbf 32Source3: http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2
4f279a49 33# Source3-md5: 17d7b574e1b85ad6f8ddceda9e841f19
a825a165 34Source6: %{name}serv.sysconfig
0f5143bd 35Source7: %{name}.desktop
36Source8: %{name}.png
6dabce9f 37Patch0: %{name}-rpmfs.patch
81132514
JB
38Patch4: %{name}-home_etc2.patch
39Patch5: %{name}-pl.patch
82a31d0b 40Patch6: %{name}-no-ws-visible.patch
60ec3264 41Patch11: %{name}-noperl-vfs.patch
317fa76e 42# at now syntax highligthing for PLD-update-TODO and CVSROOT/users
60ec3264 43Patch12: %{name}-pld-developerfriendly.patch
60ec3264 44Patch17: %{name}-nolibs.patch
3b4a4e18 45Patch24: %{name}-find_options.patch
1835a686 46Patch25: %{name}-verilog-syntax.patch
2a79da2b 47URL: http://www.midnight-commander.org/
2ce65b42
TP
48BuildRequires: autoconf
49BuildRequires: automake
8585e26d 50BuildRequires: gettext-devel
482746f5 51BuildRequires: glib2-devel
2ce65b42 52BuildRequires: indent
e573ba19 53BuildRequires: slang-devel >= 2.2.1
2ce65b42 54BuildRequires: pam-devel
07a90788 55BuildRequires: pkgconfig
1b8659cb 56BuildRequires: rpm-perlprov
67463a8b 57BuildRequires: rpmbuild(macros) >= 1.268
27d0a08b 58BuildRequires: sed >= 4.0
8585e26d 59%ifnarch s390 s390x
76d8dd60 60BuildRequires: gpm-devel
8585e26d 61%endif
ea305648 62# Needed? %%{?with_perl_vfs:Requires: perl-base}
fa581339 63%{?with_x:BuildRequires: xorg-lib-libX11-devel}
ea305648 64%{?with_ext2undel:BuildRequires: e2fsprogs-devel}
cebe333f 65Requires: file
867710f4 66Requires: pam >= 0.77.3
ec507259 67Requires: sed
189df32c 68Requires: setup >= 2.4.6-2
18364489
PG
69Suggests: bzip2
70Suggests: gzip
71Suggests: lynx
b3305301 72Suggests: p7zip-standalone
3c997af2 73Suggests: rpm-utils
18364489
PG
74Suggests: tar
75Suggests: unzip
a2a8cff1 76Obsoletes: tkmc
1ca427de 77Conflicts: bash < 2.05b
0f5143bd 78Conflicts: rpm < 4.0
67463a8b 79BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
014925d9 80
7c054d29 81%define specflags_ia32 -fomit-frame-pointer
abb760dd 82
b225fe80 83%description
a82605d4 84Midnight Commander is a visual shell much like a file manager, only
85with way more features. It is text mode, but also includes mouse
86support if you are running GPM. Its coolest feature is the ability to
8f20bffe 87FTP, view tar, zip files, and poke into RPMs for specific files. :-)
06df6411 88
b1356c1b
JR
89%description -l de.UTF-8
90Midnight Commander ist ein Visual-Shell, ähnlich einem Dateimanager,
91aber mit zusätzlichen Funktionen. Es läuft im Textmodus, kann jedoch
92eine Maus unterstützen, wenn GPM betrieben wird. Seine coolsten
93Fähigkeiten sind die FTP-Option, das Einsehen von tar- und zip-Dateien
a82605d4 94und das Herausfischen von spezifischen Dateien aus RPMs.
b225fe80 95
b1356c1b
JR
96%description -l es.UTF-8
97Midnight Commander es un interpretador de comandos visual que más
97677aa5 98parece un administrador de archivos, solamente con varias
b1356c1b
JR
99características a más. Es un programa en modo texto, pero incluye
100soporte para ratón, si estuviera ejecutando GPM o en una ventana
101xterm. Su característica más genial es la habilidad de cotillear en
102RPMs buscando archivos específicos. :-)
97677aa5 103
b1356c1b 104%description -l fr.UTF-8
a82605d4 105Midnight Commander est une interface pour la ligne de commande qui
106tient beaucoup du gestionnaire de fichiers, mais est bien plus
b1356c1b
JR
107puissant. Il fonctionne en mode console (texte), mais peut être
108contrôlé à la souris si GPM est présent. Ses caractéristiques les plus
109remarquables sont la possibilité de se connecter à un serveur FTP, de
a82605d4 110visualiser des archives tar, de compresser des fichiers avec zip, de
b1356c1b 111récupérer des fichiers dans les packages RPM, et tout ceci simplement.
b225fe80 112
b1356c1b
JR
113%description -l ja.UTF-8
114Midnight Commander はいろいろな機能を持ったファイルマネージャ兼
115ビジュアルシェルです。これはテキストモードのアプリケーションですが、
116GPM を使っている場合、マウスが使えます。 Midnight Commander には、 FTP
117に接続できたり、 tar や zip や RPM の中が見えるなど、クールな機能
118があります。
97677aa5 119
b1356c1b
JR
120%description -l pl.UTF-8
121Midnight Commander jest wizualną powłoką podobną do Norton Commandera.
122Pracuje w trybie tekstowym, ale ma także obsługę myszki. Jest super ;)
123MC ma wbudowanego klienta FTP, może zaglądać do skompresowanych
124archiwów tar i zip, a także oglądać pliki w pakietach RPM.
dadc2ff7 125
b1356c1b
JR
126%description -l pt_BR.UTF-8
127Midnight Commander é um interpretador de comandos visual que mais
128parece um gerenciador de arquivos, somente com várias características
129a mais. Ele é um programa de modo texto, mas inclui suporte para mouse
130se você estiver rodando GPM ou em uma janela xterm. Sua característica
131mais legal é a habilidade de bisbilhotar em RPMs procurando arquivos
132específicos. :-)
97677aa5 133
b1356c1b
JR
134%description -l tr.UTF-8
135Midnight Commander bir dosya yöneticisine çok benzeyen ancak daha
136yetenekli bir görsel kabuktur. Metin ekranda çalışır ve GPM
137çalışıyorsa fare desteği vardır. En hoş özellikleri FTP yapabilmesi,
138tar, zip ve RPM dosyalarının içeriklerini gösterebilmesidir.
0107cf03 139
a2a8cff1 140%package -n mcserv
9ef7c013 141Summary: Server for the Midnight Commander network file management system
7defc305
ER
142Summary(de.UTF-8): Midnight Commander File-Server
143Summary(es.UTF-8): Servidor de archivos del Midnight Commander
144Summary(fr.UTF-8): Serveur réseau pour le gestionnaire de fichiers Midnight Commander
145Summary(ja.UTF-8): Midnight Commander でネットワークファイルマネージメントを行うサーバ
146Summary(pl.UTF-8): Serwer plików Midnight Commandera
147Summary(pt_BR.UTF-8): Servidor de arquivos do Midnight Commander
148Summary(ru.UTF-8): Midnight Commander файл-сервер
149Summary(tr.UTF-8): Midnight Commander dosya sunucusu
150Summary(uk.UTF-8): Midnight Commander файл-сервер
151Summary(zh_CN.UTF-8): mc 网络文件管理系统的服务器。
e84de3cd 152Group: Daemons
91c76ea7 153Requires(post,preun): /sbin/chkconfig
6f032019 154Requires: pam >= 0.99.7.1-1
d4c2fefe 155Requires: portmap
f1a94985 156Requires: rc-scripts >= 0.4.1.5
b225fe80 157
158%description -n mcserv
a82605d4 159The Midnight Commander file management system will allow you to
160manipulate the files on a remote machine as if they were local. This
161is only possible if the remote machine is running the mcserv server
162program. Mcserv provides clients running Midnight Commander with
163access to the host's file systems.
b225fe80 164
b1356c1b
JR
165%description -n mcserv -l de.UTF-8
166mcserv ist das Server-Programm für das Netzwerkdateisystem Midnight
167Commander. Es ermöglicht den Zugriff auf das Host-Dateisystem für
168Clients, die das Midnight-Dateisystem ausführen (z.Zt. nur Midnight
a82605d4 169Commander file manager).
b225fe80 170
b1356c1b 171%description -n mcserv -l es.UTF-8
97677aa5 172Mcserv es un servidor para el sistema de archivos en red del Midnight
173Commander. Permite que clientes usando el mc accedan remotamente al
b1356c1b 174sistema de archivos de la máquina en que está ejecutando.
97677aa5 175
b1356c1b
JR
176%description -n mcserv -l fr.UTF-8
177Le système de gestion de fichier Midnight Commander vous permet de
178manipuler des fichiers sur une machine distante comme si ils étaient
a82605d4 179sur votre propre machine. Ceci est possible seulement si la machine
b1356c1b 180distante possède le programme mcserv et que celui-ci est activé.
a82605d4 181Mcserv apporte aux machines clientes qui font tourner Midnight
b1356c1b 182Commander un accès aux fichiers situés sur l'hôte.
b225fe80 183
b1356c1b 184%description -n mcserv -l ja.UTF-8
97677aa5 185Midnight Commander
b1356c1b
JR
186のファイル管理システムは、リモートマシンにあるファイルを
187ローカルにあるかのように扱うことができます。この機能は mcserv
188プログラムを 実行しているリモートマシンに対してのみ働きます。 Mcserv
189は Midnight Commander
190クライアントに対して、このホストのファイルシステムを提供します。
97677aa5 191
b1356c1b
JR
192%description -n mcserv -l pl.UTF-8
193Mcserv jest aplikacją dla sieciowego systemu plików Midnight
194Commandera. Pozwala na dostęp do systemu plików dla klienta
195pracującego pod MC i używającego jego systemu plików.
014925d9 196
b1356c1b
JR
197%description -n mcserv -l pt_BR.UTF-8
198Mcserv é um servidor para o sistema de arquivos em rede do Midnight
97677aa5 199Commander. Ele permite que clientes usando o mc acessem remotamente o
b1356c1b 200sistema de arquivos da máquina em que está rodando.
97677aa5 201
b1356c1b
JR
202%description -n mcserv -l ru.UTF-8
203mcserv - это серверная программа для сетевой файловой системы Midnight
204Commander. Она обеспечивает доступ к удаленной файловой системе
205клиентам, поддерживающим файловую систему Midnight Commander (в
206настоящее время только собственно Midnight Commander).
a7c418f5 207
b1356c1b
JR
208%description -n mcserv -l tr.UTF-8
209mcserv, Midnight Commander ağ dosya sisteminin sunucu programıdır.
210Midnight dosya sistemini çalıştıran istemcilerin sunucu dosya
211sistemine erişimini sağlar.
a2a8cff1 212
b1356c1b
JR
213%description -n mcserv -l uk.UTF-8
214mcserv - це серверна програма для мережевої файлової системи Midnight
215Commander. Вона забезпечує доступ до віддаленої файлової системи
216клієнтам, що підтримують файлову систему Midnight Commander (наразі
217тільки власне Midnight Commander).
a7c418f5 218
b225fe80 219%prep
db2935bf 220%setup -q -a3 -n %{name}-%{version}-%{snap}
38b8997f 221%patch0 -p1
6dabce9f 222cp -f vfs/extfs/{rpm,srpm}
db2935bf
AM
223# doesn't apply
224#%patch4 -p1
225# doesn't apply
226#%patch5 -p1
82a31d0b 227%patch6 -p1
60ec3264 228%{!?with_perl_vfs:%patch11 -p1}
48e9798a 229%patch12 -p1
6f1e2805 230%patch17 -p1
3b4a4e18 231%if "%{pld_release}" == "ti"
232%patch24 -p1
233%endif
fb51bf83 234%patch25 -p1
69d23796 235
5a0ca66d 236rm -f po/stamp-po
b225fe80 237
1835a686 238sed -i 's:|hxx|:|hh|hpp|hxx|tcc|:' syntax/Syntax
27d0a08b 239
b225fe80 240%build
ebf0d7d4 241%{__gettextize}
8a749106 242%{__aclocal} -I m4
569ca9b0 243%{__autoconf}
244%{__automake}
6ea21e8b 245X11_WWW="
60c59db8
TP
246if [ -f /usr/bin/iceweasel ]; then
247 iceweasel;
6ea21e8b 248else
e6bd752d 249 if [ -f /usr/bin/galeon ]; then
a7c418f5 250 galeon
251 else
e6bd752d 252 if [ -f /usr/bin/mozilla ]; then
a7c418f5 253 mozilla
254 else
255 xterm -c lynx
256 fi;
257 fi;
6ea21e8b 258fi"
bf80beca 259
014925d9 260%configure \
60c59db8 261 --enable-dependency-tracking \
b0067d79 262 --enable-charset \
e6bd752d 263 --with%{!?debug:out}-debug \
69d23796
JB
264 --with%{!?with_ext2undel:out}-ext2undel \
265 --with%{!?with_x:out}-x \
aa82b622 266 --with-vfs \
8664ffe1
AM
267 --enable-vfs-mcfs \
268 --enable-mcserver \
69d23796 269 %{?with_samba:--with-samba} \
e6bd752d
AM
270 --with-configdir=/etc/samba \
271 --with-codepagedir=/etc/samba/codepages \
272 --with-gpm-mouse \
e573ba19 273 --with-screen=slang \
e6bd752d
AM
274 --with-edit
275
276%{__make}
b225fe80 277
b225fe80 278%install
279rm -rf $RPM_BUILD_ROOT
ee7810f9 280install -d $RPM_BUILD_ROOT{%{_sbindir},%{_pixmapsdir},%{_desktopdir}} \
189df32c 281 $RPM_BUILD_ROOT/etc/{rc.d/init.d,pam.d,shrc.d,sysconfig} \
ee7810f9 282 $RPM_BUILD_ROOT%{_mandir}/man8
c2b7cdae 283
aaabaa35 284%{__make} install \
c2b7cdae 285 DESTDIR=$RPM_BUILD_ROOT
06df6411 286
a2a8cff1 287install %{SOURCE1} $RPM_BUILD_ROOT/etc/pam.d/mcserv
288install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/mcserv
a825a165 289install %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/mcserv
9869577c 290install %{SOURCE7} $RPM_BUILD_ROOT%{_desktopdir}
0f5143bd 291install %{SOURCE8} $RPM_BUILD_ROOT%{_pixmapsdir}
a2a8cff1 292
99de6f42 293for a in es pl ; do
267b57f9 294 for b in man1 man8 ; do
295 install -d $RPM_BUILD_ROOT%{_mandir}/{$a,$a/$b}
296 for c in man/$a/$b/* ; do
297 install $c $RPM_BUILD_ROOT%{_mandir}/$a/$b
99de6f42 298 done
299 done
300done
301
db2935bf 302install contrib/{mc.sh,mc.csh} $RPM_BUILD_ROOT/etc/shrc.d
b225fe80 303
875f991f 304%find_lang %{name}
305
a2a8cff1 306%clean
307rm -rf $RPM_BUILD_ROOT
b225fe80 308
06df6411 309%post -n mcserv
767ab68a 310/sbin/chkconfig --add mcserv
67463a8b 311%service mcserv restart "mcserv daemon"
b225fe80 312
06df6411 313%preun -n mcserv
767ab68a 314if [ "$1" = "0" ]; then
67463a8b 315 %service mcserv stop
767ab68a 316 /sbin/chkconfig --del mcserv
317fi
b225fe80 318
875f991f 319%files -f %{name}.lang
06df6411 320%defattr(644,root,root,755)
db2935bf 321%doc NEWS README
aa82b622 322%attr(755,root,root) %{_bindir}/mc*
f0858a92 323%config /etc/shrc.d/*
8714df24 324%attr(755,root,root) %{_libdir}/mc/cons.saver
325%dir %{_libdir}/mc
db2935bf
AM
326%attr(755,root,root) %{_libdir}/mc/*.sh
327%attr(755,root,root) %{_libdir}/mc/*.csh
8714df24 328%dir %{_datadir}/mc
e6bd752d 329
8714df24 330%{_datadir}/mc/syntax
8714df24 331
e6bd752d 332%{_datadir}/mc/mc.hlp
e6bd752d 333%lang(es) %{_datadir}/mc/mc.hlp.es
f0fc3ecc 334%lang(hu) %{_datadir}/mc/mc.hlp.hu
e6bd752d
AM
335%lang(it) %{_datadir}/mc/mc.hlp.it
336%lang(pl) %{_datadir}/mc/mc.hlp.pl
337%lang(ru) %{_datadir}/mc/mc.hlp.ru
4341efe2 338%lang(sr) %{_datadir}/mc/mc.hlp.sr
4341efe2 339%lang(sr) %{_datadir}/mc/mc.menu.sr
e6bd752d
AM
340%{_datadir}/mc/mc.hint
341%lang(cs) %{_datadir}/mc/mc.hint.cs
342%lang(es) %{_datadir}/mc/mc.hint.es
343%lang(hu) %{_datadir}/mc/mc.hint.hu
344%lang(it) %{_datadir}/mc/mc.hint.it
345%lang(nl) %{_datadir}/mc/mc.hint.nl
346%lang(pl) %{_datadir}/mc/mc.hint.pl
347%lang(ru) %{_datadir}/mc/mc.hint.ru
4341efe2 348%lang(sr) %{_datadir}/mc/mc.hint.sr
e6bd752d
AM
349%lang(uk) %{_datadir}/mc/mc.hint.uk
350%lang(zh) %{_datadir}/mc/mc.hint.zh
351
8714df24 352%dir %{_datadir}/mc/extfs
e6bd752d 353%{_datadir}/mc/extfs/README
26aa770b 354%if %{with perl_vfs}
e6bd752d
AM
355%attr(755,root,root) %{_datadir}/mc/extfs/a
356%attr(755,root,root) %{_datadir}/mc/extfs/apt
e6bd752d
AM
357%attr(755,root,root) %{_datadir}/mc/extfs/deb*
358%attr(755,root,root) %{_datadir}/mc/extfs/dpkg
e6bd752d
AM
359%attr(755,root,root) %{_datadir}/mc/extfs/mailfs
360%attr(755,root,root) %{_datadir}/mc/extfs/patchfs
26aa770b 361%attr(755,root,root) %{_datadir}/mc/extfs/rpms
26aa770b 362%attr(755,root,root) %{_datadir}/mc/extfs/uzip
363%endif
364%attr(755,root,root) %{_datadir}/mc/extfs/audio
365%attr(755,root,root) %{_datadir}/mc/extfs/bpp
366%attr(755,root,root) %{_datadir}/mc/extfs/hp48
4341efe2 367%attr(755,root,root) %{_datadir}/mc/extfs/iso9660
26aa770b 368%attr(755,root,root) %{_datadir}/mc/extfs/lslR
369%attr(755,root,root) %{_datadir}/mc/extfs/rpm
e6bd752d 370%attr(755,root,root) %{_datadir}/mc/extfs/trpm
54a28285
AM
371%attr(755,root,root) %{_datadir}/mc/extfs/u7z
372%attr(755,root,root) %{_datadir}/mc/extfs/ualz
e6bd752d 373%attr(755,root,root) %{_datadir}/mc/extfs/uar*
db2935bf
AM
374%attr(755,root,root) %{_datadir}/mc/extfs/uace
375%attr(755,root,root) %{_datadir}/mc/extfs/uc1541
e6bd752d
AM
376%attr(755,root,root) %{_datadir}/mc/extfs/uha
377%attr(755,root,root) %{_datadir}/mc/extfs/ulha
378%attr(755,root,root) %{_datadir}/mc/extfs/urar
e6bd752d
AM
379%attr(755,root,root) %{_datadir}/mc/extfs/uzoo
380%attr(755,root,root) %{_datadir}/mc/extfs/srpm
c3652360 381%{_desktopdir}/mc.desktop
382%{_pixmapsdir}/mc.png
06df6411 383
fb0aa8ab 384%{_mandir}/man1/*
99de6f42 385%lang(es) %{_mandir}/es/man1/*
e6bd752d
AM
386%lang(hu) %{_mandir}/hu/man1/*
387%lang(it) %{_mandir}/it/man1/*
f0fc3ecc 388%lang(pl) %{_mandir}/pl/man1/*
e6bd752d 389%lang(ru) %{_mandir}/ru/man1/*
4341efe2 390%lang(sr) %{_mandir}/sr/man1/*
3f46a95e 391
db2935bf 392%dir %{_sysconfdir}/mc
5f3be722
AM
393%config(noreplace) %verify(not md5 mtime size) /etc/mc/Syntax
394%config(noreplace) %verify(not md5 mtime size) /etc/mc/*.*
db2935bf 395%dir %{_sysconfdir}/mc/extfs
5f3be722 396%config(noreplace) %verify(not md5 mtime size) /etc/mc/extfs/*.*
db2935bf 397
b225fe80 398%files -n mcserv
06df6411 399%defattr(644,root,root,755)
eb4f600d 400%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/*
a825a165 401%attr(754,root,root) /etc/rc.d/init.d/mcserv
10f51416 402%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/mcserv
fb0aa8ab 403%{_mandir}/man8/mcserv.8*
99de6f42 404%lang(es) %{_mandir}/es/man8/mcserv.8*
3f46a95e 405%lang(pl) %{_mandir}/pl/man8/mcserv.8*
4341efe2 406%lang(sr) %{_mandir}/sr/man8/mcserv.8*
c2b7cdae 407%attr(755,root,root) %{_sbindir}/mcserv
This page took 1.452176 seconds and 4 git commands to generate.