Репозиторий Sisyphus
Последнее обновление: 24 сентября 2022 | Пакетов: 17655 | Посещений: 25033851
en ru br
Репозитории ALT
S:4.8.28-alt1
5.1: 4.8.11-alt0.M51.1
4.1: 4.6.2-alt7.pre1
4.0: 4.6.1r-alt9
3.0: 4.6.1r-alt3
www.altlinux.org/Changes

Группа :: Работа с файлами
Пакет: mc

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

%define basever 4.6.1

%ifdef cvsver
%define ver %basever-%cvsver
%else
%define ver %basever
%endif

Name: mc
Version: %{ver}r
Release: alt3

License: GPL
Summary: A user-friendly file manager and visual shell
Group: File tools
URL: http://www.ibiblio.org/mc/

Source:  ftp://ftp.ibiblio.org/pub/Linux/utils/file/managers/mc/mc-%ver.tar.bz2
Source1: synce-mcfs.tar.gz
Source5: mc-dnlike.color
Source6: mc-dark.color
Source11: mc-16.png
Source12: mc-32.png

PreReq: chkconfig

Patch:  mc-4.6.1-alt-Eterm.patch
Patch1: mc-4.6.1-alt-charsets.patch
Patch2: mc-4.6.1-alt-wrapper.patch
Patch3: mc-4.5.55-language.patch
Patch4: mc-4.6.1-alt-m4_configure.patch
Patch5: mc-4.6.1-alt-extfs.patch
Patch6: mc-4.6.1-alt-syntax.patch
Patch7: mc-4.6.1-alt-vfs.patch
Patch8: mc-4.6.0-vfs-date_parse-alt.patch
Patch9: mc-4.6.1-alt-forceexec.patch
Patch10: mc-4.6.1a-alt-po.patch
Patch11: mc-4.6.1-alt-u7z.patch

# RH

Patch101: mc-4.6.1a-rh-64bit.patch
Patch102: mc-4.6.1a-rh-fish-upload.patch
Patch103: mc-4.6.1a-rh-promptfix.patch
Patch104: mc-4.6.1a-rh-uglydir.patch

# UTF8

Patch201: mc-4.6.1-rh-alt-utf8.patch

# Contributed

Patch301: mc-4.6.1-xs-file-highlight.patch.bz2

Requires: libslang >= 1.4.9

BuildRequires: glib2-devel libe2fs-devel libgpm-devel libslang-devel
BuildRequires: pkgconfig cvs groff-base

%description
Midnight Commander is a visual shell much like a file manager, only with way
more features.  It is text mode, but also includes mouse support if you are
running GPM.  Its coolest feature is the ability to ftp, view tar, zip
files, and poke into RPMs for specific files.  :-)

%prep
%setup -q -n %name-%ver -a1
# ALT
%patch  -p1 -b .Eterm
%patch1 -p1 -b .charsets
%patch2 -p1 -b .wrapper
%patch3 -p1 -b .language
%patch4 -p1 -b .m4_configure
%patch5 -p0 -b .extfs
%patch6 -p0 -b .syntax
%patch7 -p1 -b .vfs
# %path8 -p0 -b .vfs-date
%patch9 -p1 -b .fe
%patch10 -p1 -b .po_fix
%patch11 -p1 -b .u7z

# RH

%patch101 -p1 -b .64bit
%patch102 -p1 -b .fish
%patch103 -p1 -b .prompt
%patch104 -p1 -b .uglydir
# UTF8
%patch201 -p1 -b .utf8

# Contributed

%patch301 -p1 -b .ftype

%build
%configure --without-gnome \
   --without-debug \
   --with-screen=slang \
   --without-included-gettext \
   --enable-charset \
   --enable-largefile \
   --without-x

%make_build

%install
%__install -d %buildroot%_sysconfdir/{profile.d,bashrc.d}

%makeinstall

%__mv %buildroot%_datadir/mc/bin/mc.* %buildroot%_sysconfdir/profile.d
# Install DosNavigaor color scheme
%__install -m644 %SOURCE5 $RPM_BUILD_DIR/%name-%basever
# Install Dark color scheme
%__install -m644 %SOURCE6 $RPM_BUILD_DIR/%name-%basever
# Install SynCE VFS
%__install -m755 synce-mcfs/src/synce* %buildroot%_datadir/%name/extfs/
%__cat synce-mcfs/src/extfs.ini.add >> %buildroot%_datadir/%name/extfs/extfs.ini

# Add Russian and Ukrainian hints and help for CP1251 & UTF-8 locales

iconv -fkoi8-r -tcp1251 %buildroot%_datadir/mc/mc.hint.ru > %buildroot%_datadir/mc/mc.hint.ru_RU.CP1251
iconv -fkoi8-u -tcp1251 %buildroot%_datadir/mc/mc.hint.uk > %buildroot%_datadir/mc/mc.hint.uk_UA.CP1251
iconv -fkoi8-u -tcp1251 %buildroot%_datadir/mc/mc.hlp.ru >  %buildroot%_datadir/mc/mc.hlp.ru_RU.CP1251
iconv -fkoi8-r -tutf8   %buildroot%_datadir/mc/mc.hint.ru > %buildroot%_datadir/mc/mc.hint.ru_RU.UTF-8
iconv -fkoi8-u -tutf8   %buildroot%_datadir/mc/mc.hint.uk > %buildroot%_datadir/mc/mc.hint.uk_UA.UTF-8

# remove bash wrapper

# rm -f %buildroot%_datadir/mc/bin/mc-wrapper.sh

# Move mc.sh to proper path

%__mkdir_p %buildroot%_sysconfdir/bashrc.d
%__mv %buildroot%_sysconfdir/profile.d/mc.sh %buildroot%_sysconfdir/bashrc.d

# menu

%__cat <<__MENU__ >%name.menu
?package(%name): needs="text" section="Applications/File tools" \
title="Midnight Commander" longtitle="Midnight Commander" \
command="%_datadir/mc/bin/mc-wrapper.sh" \
icon=%name.png
__MENU__
%__install -pD -m644 %name.menu %buildroot%_menudir/%name
# icons
%__install -pD -m644 %SOURCE11 %buildroot%_miconsdir/%name.png
%__install -pD -m644 %SOURCE12 %buildroot%_iconsdir/%name.png

%find_lang %name

%post
%update_menus

%postun
%clean_menus

%files -f %name.lang
%doc FAQ NEWS README mc-dnlike.color mc-dark.color
%_bindir/mc
%_bindir/mcedit
%_bindir/mcview
%_bindir/mcmfmt
%_libdir/mc
%_datadir/mc
%_mandir/man1/*
%_menudir/%name
%_iconsdir/%name.png
%_miconsdir/%name.png
%config(noreplace) %_datadir/mc/mc.ext
%config(noreplace) %_sysconfdir/bashrc.d/*

%changelog

Полный changelog можно просмотреть здесь

 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin