Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37038123
en ru br
Репозитории ALT
S:4.8.30-alt3
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 

Патч: mc-4.7.5.3-alt3.patch
Скачать


 .../tags/46d492bd32096d0489ad468849ccf07f267c77ed  |   13 ++
 .../tags/f6eb4ec26eb2fba18dfc54d03342cc8125de3d3e  |   13 --
 .gear/tags/list                                    |    2 +-
 ...-cc0257cd5a34261439152f331b8d93014109cbff.patch |   34 ++++
 ...-e4961563c4019892d8965779c6979c38c2f68017.patch |  203 ++++++++++++++++++++
 alt-files/mc.zsh                                   |    3 +
 alt-patches/mc-4.7.0.10-alt-extfs-udar.patch       |  140 --------------
 alt-patches/mc-4.7.5.3-alt-extfs-udar.patch        |  140 ++++++++++++++
 mc.spec                                            |   29 +++-
 9 files changed, 417 insertions(+), 160 deletions(-)
diff --git a/.gear/tags/46d492bd32096d0489ad468849ccf07f267c77ed b/.gear/tags/46d492bd32096d0489ad468849ccf07f267c77ed
new file mode 100644
index 0000000..e554a38
--- /dev/null
+++ b/.gear/tags/46d492bd32096d0489ad468849ccf07f267c77ed
@@ -0,0 +1,13 @@
+object 1918b095faede10222ae6cf6a1ab1ac0901a1e78
+type commit
+tag 4.7.5.3
+tagger Sergey Y. Afonin <asy@altlinux.org> 1312824639 +0400
+
+4.7.5.3
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.11 (GNU/Linux)
+
+iEYEABECAAYFAk5AHT8ACgkQ9lmILNBvYft4LwCghmF1ApcJSL/a9PV9caUFMD/R
+Na8AoI4xbVqCYRQzbIeejeL8i1VUi630
+=8KWN
+-----END PGP SIGNATURE-----
diff --git a/.gear/tags/f6eb4ec26eb2fba18dfc54d03342cc8125de3d3e b/.gear/tags/f6eb4ec26eb2fba18dfc54d03342cc8125de3d3e
deleted file mode 100644
index 1c826d4..0000000
--- a/.gear/tags/f6eb4ec26eb2fba18dfc54d03342cc8125de3d3e
+++ /dev/null
@@ -1,13 +0,0 @@
-object c74af57ad51b19b5fde283c03333cc15c693684d
-type commit
-tag 4.7.5.1
-tagger Sergey Y. Afonin <asy@altlinux.org> 1297082596 +0300
-
-4.7.5.1
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.11 (GNU/Linux)
-
-iEYEABECAAYFAk1P6OQACgkQ9lmILNBvYfvNlwCffRZA8kSyhqtT6BOcoxD2BXNJ
-5u8An04+mOz7plIYbvldEqKbZtBVoAZk
-=zhS1
------END PGP SIGNATURE-----
diff --git a/.gear/tags/list b/.gear/tags/list
index 71c1cca..43a190c 100644
--- a/.gear/tags/list
+++ b/.gear/tags/list
@@ -1 +1 @@
-f6eb4ec26eb2fba18dfc54d03342cc8125de3d3e 4.7.5.1
+46d492bd32096d0489ad468849ccf07f267c77ed 4.7.5.3
diff --git a/alt-files/mc.git-cc0257cd5a34261439152f331b8d93014109cbff.patch b/alt-files/mc.git-cc0257cd5a34261439152f331b8d93014109cbff.patch
new file mode 100644
index 0000000..be14e09
--- /dev/null
+++ b/alt-files/mc.git-cc0257cd5a34261439152f331b8d93014109cbff.patch
@@ -0,0 +1,34 @@
+From cc0257cd5a34261439152f331b8d93014109cbff Mon Sep 17 00:00:00 2001
+From: Slava Zanko <slavazanko@gmail.com>
+Date: Wed, 13 Jul 2011 12:49:34 +0300
+Subject: [PATCH] Ticket #81: Fixup of extfs.
+
+Signed-off-by: Slava Zanko <slavazanko@gmail.com>
+---
+ lib/vfs/mc-vfs/extfs.c |    3 +--
+ 1 files changed, 1 insertions(+), 2 deletions(-)
+
+diff --git a/lib/vfs/mc-vfs/extfs.c b/lib/vfs/mc-vfs/extfs.c
+index 368a4fc..12c0eeb 100644
+--- a/lib/vfs/mc-vfs/extfs.c
++++ b/lib/vfs/mc-vfs/extfs.c
+@@ -474,7 +474,6 @@ extfs_read_archive (int fstype, const char *name, struct archive **pparc)
+     char *buffer;
+     struct archive *current_archive;
+     char *current_file_name, *current_link_name;
+-    size_t filepos = 0;
+ 
+     info = &g_array_index (extfs_plugins, extfs_plugin_info_t, fstype);
+ 
+@@ -492,7 +491,7 @@ extfs_read_archive (int fstype, const char *name, struct archive **pparc)
+         struct stat hstat;
+ 
+         current_link_name = NULL;
+-        if (vfs_parse_ls_lga (buffer, &hstat, &current_file_name, &current_link_name, &filepos))
++        if (vfs_parse_ls_lga (buffer, &hstat, &current_file_name, &current_link_name, NULL))
+         {
+             struct entry *entry, *pent;
+             struct inode *inode;
+-- 
+1.7.3.3
+
diff --git a/alt-files/mc.git-e4961563c4019892d8965779c6979c38c2f68017.patch b/alt-files/mc.git-e4961563c4019892d8965779c6979c38c2f68017.patch
new file mode 100644
index 0000000..38efc5e
--- /dev/null
+++ b/alt-files/mc.git-e4961563c4019892d8965779c6979c38c2f68017.patch
@@ -0,0 +1,203 @@
+From e4961563c4019892d8965779c6979c38c2f68017 Mon Sep 17 00:00:00 2001
+From: Slava Zanko <slavazanko@gmail.com>
+Date: Tue, 19 Jul 2011 11:30:20 +0300
+Subject: [PATCH] Ticket #81: savannah: can't access files on ftp starting with space
+
+files starting with space can't be acessed by mc through ftp - it
+shows the file as not having the leading space and attempts to
+access it produce 'permission denied' errors.
+
+Signed-off-by: Slava Zanko <slavazanko@gmail.com>
+---
+ lib/vfs/mc-vfs/direntry.c  |   25 +++++++++++++++++++++++++
+ lib/vfs/mc-vfs/extfs.c     |    3 ++-
+ lib/vfs/mc-vfs/ftpfs.c     |    6 +++++-
+ lib/vfs/mc-vfs/utilvfs.c   |   19 ++++++++++++++-----
+ lib/vfs/mc-vfs/utilvfs.h   |    2 +-
+ lib/vfs/mc-vfs/xdirentry.h |    9 +++++++++
+ 6 files changed, 56 insertions(+), 8 deletions(-)
+
+diff --git a/lib/vfs/mc-vfs/direntry.c b/lib/vfs/mc-vfs/direntry.c
+index 314696b..959f8ca 100644
+--- a/lib/vfs/mc-vfs/direntry.c
++++ b/lib/vfs/mc-vfs/direntry.c
+@@ -1468,3 +1468,28 @@ vfs_s_get_line_interruptible (struct vfs_class *me, char *buffer, int size, int
+ #endif /* ENABLE_VFS_NET */
+ 
+ /* --------------------------------------------------------------------------------------------- */
++
++/**
++ * Normalize filenames start position
++ */
++
++void
++vfs_s_normalize_filename_pos (struct vfs_s_inode *root_inode, size_t final_filepos)
++{
++    struct vfs_s_entry *entry;
++
++    for (entry = root_inode->subdir; entry != NULL; entry = entry->next)
++    {
++        if ((size_t) entry->ino->data_offset > final_filepos)
++        {
++            char *source_name = entry->name;
++            char *spacer = g_strnfill (entry->ino->data_offset - final_filepos, ' ');
++            entry->name = g_strdup_printf ("%s%s", spacer, source_name);
++            g_free (spacer);
++            g_free (source_name);
++        }
++        entry->ino->data_offset = -1;
++    }
++}
++
++/* --------------------------------------------------------------------------------------------- */
+diff --git a/lib/vfs/mc-vfs/extfs.c b/lib/vfs/mc-vfs/extfs.c
+index cb1475c..368a4fc 100644
+--- a/lib/vfs/mc-vfs/extfs.c
++++ b/lib/vfs/mc-vfs/extfs.c
+@@ -474,6 +474,7 @@ extfs_read_archive (int fstype, const char *name, struct archive **pparc)
+     char *buffer;
+     struct archive *current_archive;
+     char *current_file_name, *current_link_name;
++    size_t filepos = 0;
+ 
+     info = &g_array_index (extfs_plugins, extfs_plugin_info_t, fstype);
+ 
+@@ -491,7 +492,7 @@ extfs_read_archive (int fstype, const char *name, struct archive **pparc)
+         struct stat hstat;
+ 
+         current_link_name = NULL;
+-        if (vfs_parse_ls_lga (buffer, &hstat, &current_file_name, &current_link_name))
++        if (vfs_parse_ls_lga (buffer, &hstat, &current_file_name, &current_link_name, &filepos))
+         {
+             struct entry *entry, *pent;
+             struct inode *inode;
+diff --git a/lib/vfs/mc-vfs/ftpfs.c b/lib/vfs/mc-vfs/ftpfs.c
+index 9ed3b3a..47c9b9e 100644
+--- a/lib/vfs/mc-vfs/ftpfs.c
++++ b/lib/vfs/mc-vfs/ftpfs.c
+@@ -1644,6 +1644,7 @@ ftpfs_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path
+     int sock, num_entries = 0;
+     char lc_buffer[BUF_8K];
+     int cd_first;
++    size_t filepos = 0;
+ 
+     cd_first = ftpfs_first_cd_then_ls || (SUP.strict == RFC_STRICT)
+         || (strchr (remote_path, ' ') != NULL);
+@@ -1714,13 +1715,14 @@ ftpfs_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path
+ 
+         ent = vfs_s_generate_entry (me, NULL, dir, 0);
+         i = ent->ino->st.st_nlink;
+-        if (!vfs_parse_ls_lga (lc_buffer, &ent->ino->st, &ent->name, &ent->ino->linkname))
++        if (!vfs_parse_ls_lga (lc_buffer, &ent->ino->st, &ent->name, &ent->ino->linkname, &filepos))
+         {
+             vfs_s_free_entry (me, ent);
+             continue;
+         }
+         ent->ino->st.st_nlink = i;      /* Ouch, we need to preserve our counts :-( */
+         num_entries++;
++        vfs_s_store_filename_pos (ent, filepos);
+         vfs_s_insert_entry (me, dir, ent);
+     }
+ 
+@@ -1745,6 +1747,8 @@ ftpfs_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path
+         goto again;
+     }
+ 
++    vfs_s_normalize_filename_pos (dir, filepos);
++
+     if (SUP.strict == RFC_AUTODETECT)
+         SUP.strict = RFC_DARING;
+ 
+diff --git a/lib/vfs/mc-vfs/utilvfs.c b/lib/vfs/mc-vfs/utilvfs.c
+index ab4cbdf..df57bce 100644
+--- a/lib/vfs/mc-vfs/utilvfs.c
++++ b/lib/vfs/mc-vfs/utilvfs.c
+@@ -929,8 +929,9 @@ vfs_parse_filedate (int idx, time_t * t)
+ 
+ /* --------------------------------------------------------------------------------------------- */
+ 
+-int
+-vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linkname)
++gboolean
++vfs_parse_ls_lga (const char *p, struct stat * s, char **filename, char **linkname,
++                  size_t * filename_pos)
+ {
+     int idx, idx2, num_cols;
+     int i;
+@@ -940,7 +941,7 @@ vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linknam
+     size_t skipped;
+ 
+     if (strncmp (p, "total", 5) == 0)
+-        return 0;
++        return FALSE;
+ 
+     if (!vfs_parse_filetype (p, &skipped, &s->st_mode))
+         goto error;
+@@ -1058,6 +1059,14 @@ vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linknam
+     s->st_blocks = (s->st_size + 511) / 512;
+ #endif
+ 
++    if (filename_pos != NULL)
++    {
++        if ((*filename_pos == 0) || (*filename_pos > (size_t) column_ptr[idx]))
++            *filename_pos = column_ptr[idx];
++        else
++            column_ptr[idx] = *filename_pos;
++    }
++
+     for (i = idx + 1, idx2 = 0; i < num_cols; i++)
+         if (strcmp (columns[i], "->") == 0)
+         {
+@@ -1107,7 +1116,7 @@ vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linknam
+     }
+ 
+     g_free (p_copy);
+-    return 1;
++    return TRUE;
+ 
+   error:
+     {
+@@ -1122,7 +1131,7 @@ vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linknam
+     }
+ 
+     g_free (p_copy);
+-    return 0;
++    return FALSE;
+ }
+ 
+ /* --------------------------------------------------------------------------------------------- */
+diff --git a/lib/vfs/mc-vfs/utilvfs.h b/lib/vfs/mc-vfs/utilvfs.h
+index 0c1159d..7967daf 100644
+--- a/lib/vfs/mc-vfs/utilvfs.h
++++ b/lib/vfs/mc-vfs/utilvfs.h
+@@ -52,7 +52,7 @@ gboolean vfs_parse_fileperms (const char *s, size_t * ret_skipped, mode_t * ret_
+ gboolean vfs_parse_filemode (const char *s, size_t * ret_skipped, mode_t * ret_mode);
+ gboolean vfs_parse_raw_filemode (const char *s, size_t * ret_skipped, mode_t * ret_mode);
+ 
+-int vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linkname);
++gboolean vfs_parse_ls_lga (const char *p, struct stat *s, char **filename, char **linkname, size_t *filename_pos);
+ int vfs_parse_filedate (int idx, time_t * t);
+ 
+ /*** inline functions ****************************************************************************/
+diff --git a/lib/vfs/mc-vfs/xdirentry.h b/lib/vfs/mc-vfs/xdirentry.h
+index 9e87f1f..0d43743 100644
+--- a/lib/vfs/mc-vfs/xdirentry.h
++++ b/lib/vfs/mc-vfs/xdirentry.h
+@@ -249,5 +249,14 @@ int vfs_s_get_line_interruptible (struct vfs_class *me, char *buffer, int size,
+ /* misc */
+ int vfs_s_retrieve_file (struct vfs_class *me, struct vfs_s_inode *ino);
+ 
++void vfs_s_normalize_filename_pos (struct vfs_s_inode *root_inode, size_t final_filepos);
++
+ /*** inline functions ****************************************************************************/
++
++static inline void
++vfs_s_store_filename_pos (struct vfs_s_entry *entry, size_t position)
++{
++    entry->ino->data_offset = (off_t) position;
++}
++
+ #endif
+-- 
+1.7.3.3
+
diff --git a/alt-files/mc.zsh b/alt-files/mc.zsh
new file mode 100644
index 0000000..33a68e9
--- /dev/null
+++ b/alt-files/mc.zsh
@@ -0,0 +1,3 @@
+# define aliases for zsh
+[ -n "${ZSH_VERSION}" ] || return 0
+alias mc='. /usr/lib/mc/mc-wrapper.sh'
diff --git a/alt-patches/mc-4.7.0.10-alt-extfs-udar.patch b/alt-patches/mc-4.7.0.10-alt-extfs-udar.patch
deleted file mode 100644
index b806911..0000000
--- a/alt-patches/mc-4.7.0.10-alt-extfs-udar.patch
+++ /dev/null
@@ -1,140 +0,0 @@
-diff --git a/lib/vfs/mc-vfs/extfs/Makefile.am b/lib/vfs/mc-vfs/extfs/Makefile.am
-index d955a2c..963b8ea 100644
---- a/lib/vfs/mc-vfs/extfs/Makefile.am
-+++ b/lib/vfs/mc-vfs/extfs/Makefile.am
-@@ -6,7 +6,7 @@ EXTFSCONFFILES = extfs.ini sfs.ini
- EXTFS_MISC  = README
- 
- # Scripts hat don't need adaptation to the local system
--EXTFS_CONST = bpp rpm trpm u7z ucab
-+EXTFS_CONST = bpp rpm trpm u7z ucab udar
- 
- # Scripts that need adaptation to the local system - source files
- EXTFS_IN    = 			\
-diff --git a/lib/vfs/mc-vfs/extfs/udar b/lib/vfs/mc-vfs/extfs/udar
-new file mode 100644
-index 0000000..3103f82
---- /dev/null
-+++ b/lib/vfs/mc-vfs/extfs/udar
-@@ -0,0 +1,105 @@
-+#!/bin/sh
-+
-+# This is a parser for Dar archives in Midnight Commander. You need
-+# the GPL dar program (version >= 2.3.0) written by Denis Corbin.
-+
-+# Author: Guus Jansman
-+
-+# Limitations:
-+# - The archive file can not be changed
-+# - Symbolic and hard links are not handled properly
-+# - Block and character special files are not handled
-+# - Files not stored in (differential) backups are not handled
-+# - Dar files in archives are not handled (due filename restriction)
-+
-+DAR=dar
-+
-+# dar expects the basename (without number and extension)
-+BASENAME="`echo "$2" | sed -e 's/\.[0-9]*\.[Dd][Aa][Rr]$//'`"
-+
-+mcdarfs_list ()
-+{
-+$DAR -l "$BASENAME" -N -Q -as 2>/dev/null | gawk -v uuid=${UID-0} '
-+BEGIN { flag=0 }
-+/^-------/ { flag++; if (flag > 1) exit 0; next }
-+/^$/ { next }
-+{
-+    if (flag == 0) next
-+    line=$0
-+    split(line, record, " ")
-+
-+    # Do not display removed files
-+    if (record[1] == "[" && record[2] == "REMOVED")
-+    {
-+        next
-+    }
-+
-+    # We want "line" to start with permutation
-+    # TODO: better algorithm
-+    while (length(record[1]) != 10 || match(substr(record[1], 2, 1), "[r-]") == 0)
-+    {
-+        # line without real contents
-+        if (length(line) == 0) {
-+            next
-+        }
-+        line=substr(line, length(record[1])+1)
-+        while (length(line) != 0 && substr(line, 1, 1) != " ")
-+        {
-+            line=substr(line, 2)
-+        }
-+        split(line, record, " ")
-+    }
-+
-+    perm=record[1]
-+    # Block and character special files not supported
-+    # Change [bc] to [bcl] if symbolic links should not show up either
-+    if (match(substr(perm, 1, 1), "[bc]") != 0)
-+    {
-+        next
-+    }
-+    uid=record[2]
-+    if (match(uid, "^[0-9]*$") != 0)
-+    {
-+        uid=sprintf("%-8d", uid)
-+    }
-+    gid=record[3]
-+    if (match(gid, "^[0-9]*$") != 0)
-+    {
-+        gid=sprintf("%-8d", gid)
-+    }
-+    size=record[4]
-+    month=record[6]
-+    day=record[7]
-+    tm=substr(record[8], 1, 5)
-+    year=record[9]
-+    name=substr(line, index(line, sprintf("%s:", tm))+14)
-+    # TODO: find symbolic link target (probably the link has to be extracted)
-+    printf "%s    1 %s %s %8d %3s %02d %04d %s %s\n", perm, uid, gid, size, month, day, year, tm, name
-+}'
-+}
-+
-+mcdarfs_copyout ()
-+{
-+    # Dummy directory necessary since dar cannot output to stdout or named file
-+    mkdir "$3.dir.tmp"
-+    chmod 700 "$3.dir.tmp"
-+    if [ ! -d "$3.dir.tmp" ]; then exit 1; fi
-+    $DAR -x "$BASENAME" -N -O -Q -wa -g "$2" -R "$3.dir.tmp" >/dev/null 2>&1
-+    if [ -e "$3.dir.tmp/$2" ]; then
-+        mv "$3.dir.tmp/$2" "$3"
-+        rm -rf "$3.dir.tmp"
-+    else
-+        rm -rf "$3.dir.tmp"
-+        exit 1
-+    fi
-+}
-+
-+umask 077
-+cmd="$1"
-+shift
-+case "$cmd" in
-+    list)    mcdarfs_list    "$@" ;;
-+    copyout) mcdarfs_copyout "$@" ;;
-+    *)       exit 1 ;;
-+esac
-+exit 0
-diff --git a/misc/mc.ext.in b/misc/mc.ext.in
-index 4860c95..04f9873 100644
---- a/misc/mc.ext.in
-+++ b/misc/mc.ext.in
-@@ -654,6 +654,11 @@ regex/\.xz$
- 	View=%view{ascii} xz -dc %f 2>/dev/null
- 
- 
-+# dar
-+regex/\.[0-9]*\.[Dd][Aa][Rr]$
-+	Open=%cd %p#udar
-+	View=%view{ascii} dar -l `echo %f | sed 's/\.[0-9]*\.[Dd][Aa][Rr]$//'` -N
-+
- ### Default ###
- 
- # Default target for anything not described above
diff --git a/alt-patches/mc-4.7.5.3-alt-extfs-udar.patch b/alt-patches/mc-4.7.5.3-alt-extfs-udar.patch
new file mode 100644
index 0000000..6987df3
--- /dev/null
+++ b/alt-patches/mc-4.7.5.3-alt-extfs-udar.patch
@@ -0,0 +1,140 @@
+diff --git a/lib/vfs/mc-vfs/extfs/Makefile.am b/lib/vfs/mc-vfs/extfs/Makefile.am
+index d955a2c..963b8ea 100644
+--- a/lib/vfs/mc-vfs/extfs/Makefile.am
++++ b/lib/vfs/mc-vfs/extfs/Makefile.am
+@@ -6,7 +6,7 @@ EXTFSCONFFILES = extfs.ini sfs.ini
+ EXTFS_MISC  = README
+ 
+ # Scripts hat don't need adaptation to the local system
+-EXTFS_CONST = bpp rpm trpm u7z
++EXTFS_CONST = bpp rpm trpm u7z udar
+ 
+ # Scripts that need adaptation to the local system - source files
+ EXTFS_IN    = 			\
+diff --git a/lib/vfs/mc-vfs/extfs/udar b/lib/vfs/mc-vfs/extfs/udar
+new file mode 100644
+index 0000000..3103f82
+--- /dev/null
++++ b/lib/vfs/mc-vfs/extfs/udar
+@@ -0,0 +1,105 @@
++#!/bin/sh
++
++# This is a parser for Dar archives in Midnight Commander. You need
++# the GPL dar program (version >= 2.3.0) written by Denis Corbin.
++
++# Author: Guus Jansman
++
++# Limitations:
++# - The archive file can not be changed
++# - Symbolic and hard links are not handled properly
++# - Block and character special files are not handled
++# - Files not stored in (differential) backups are not handled
++# - Dar files in archives are not handled (due filename restriction)
++
++DAR=dar
++
++# dar expects the basename (without number and extension)
++BASENAME="`echo "$2" | sed -e 's/\.[0-9]*\.[Dd][Aa][Rr]$//'`"
++
++mcdarfs_list ()
++{
++$DAR -l "$BASENAME" -N -Q -as 2>/dev/null | gawk -v uuid=${UID-0} '
++BEGIN { flag=0 }
++/^-------/ { flag++; if (flag > 1) exit 0; next }
++/^$/ { next }
++{
++    if (flag == 0) next
++    line=$0
++    split(line, record, " ")
++
++    # Do not display removed files
++    if (record[1] == "[" && record[2] == "REMOVED")
++    {
++        next
++    }
++
++    # We want "line" to start with permutation
++    # TODO: better algorithm
++    while (length(record[1]) != 10 || match(substr(record[1], 2, 1), "[r-]") == 0)
++    {
++        # line without real contents
++        if (length(line) == 0) {
++            next
++        }
++        line=substr(line, length(record[1])+1)
++        while (length(line) != 0 && substr(line, 1, 1) != " ")
++        {
++            line=substr(line, 2)
++        }
++        split(line, record, " ")
++    }
++
++    perm=record[1]
++    # Block and character special files not supported
++    # Change [bc] to [bcl] if symbolic links should not show up either
++    if (match(substr(perm, 1, 1), "[bc]") != 0)
++    {
++        next
++    }
++    uid=record[2]
++    if (match(uid, "^[0-9]*$") != 0)
++    {
++        uid=sprintf("%-8d", uid)
++    }
++    gid=record[3]
++    if (match(gid, "^[0-9]*$") != 0)
++    {
++        gid=sprintf("%-8d", gid)
++    }
++    size=record[4]
++    month=record[6]
++    day=record[7]
++    tm=substr(record[8], 1, 5)
++    year=record[9]
++    name=substr(line, index(line, sprintf("%s:", tm))+14)
++    # TODO: find symbolic link target (probably the link has to be extracted)
++    printf "%s    1 %s %s %8d %3s %02d %04d %s %s\n", perm, uid, gid, size, month, day, year, tm, name
++}'
++}
++
++mcdarfs_copyout ()
++{
++    # Dummy directory necessary since dar cannot output to stdout or named file
++    mkdir "$3.dir.tmp"
++    chmod 700 "$3.dir.tmp"
++    if [ ! -d "$3.dir.tmp" ]; then exit 1; fi
++    $DAR -x "$BASENAME" -N -O -Q -wa -g "$2" -R "$3.dir.tmp" >/dev/null 2>&1
++    if [ -e "$3.dir.tmp/$2" ]; then
++        mv "$3.dir.tmp/$2" "$3"
++        rm -rf "$3.dir.tmp"
++    else
++        rm -rf "$3.dir.tmp"
++        exit 1
++    fi
++}
++
++umask 077
++cmd="$1"
++shift
++case "$cmd" in
++    list)    mcdarfs_list    "$@" ;;
++    copyout) mcdarfs_copyout "$@" ;;
++    *)       exit 1 ;;
++esac
++exit 0
+diff --git a/misc/mc.ext.in b/misc/mc.ext.in
+index 4860c95..04f9873 100644
+--- a/misc/mc.ext.in
++++ b/misc/mc.ext.in
+@@ -654,6 +654,11 @@ regex/\.xz$
+ 	View=%view{ascii} xz -dc %f 2>/dev/null
+ 
+ 
++# dar
++regex/\.[0-9]*\.[Dd][Aa][Rr]$
++	Open=%cd %p#udar
++	View=%view{ascii} dar -l `echo %f | sed 's/\.[0-9]*\.[Dd][Aa][Rr]$//'` -N
++
+ ### Default ###
+ 
+ # Default target for anything not described above
diff --git a/mc.spec b/mc.spec
index 292ecc5..a7be624 100644
--- a/mc.spec
+++ b/mc.spec
@@ -1,6 +1,6 @@
 Name: mc
-Version: 4.7.5.1
-Release: alt2
+Version: 4.7.5.3
+Release: alt3
 
 License: %gpllgpl2plus
 Summary: An user-friendly file manager and visual shell
@@ -13,6 +13,7 @@ Source2: mc-dnlike.color
 Source3: mc-dark.color
 Source4: mc-16.png
 Source5: mc-32.png
+Source6: mc.zsh
 
 Patch0: %name-%version-%release.patch
 
@@ -24,7 +25,7 @@ Patch7: mc-4.7.0-alt-po.patch
 Patch8: mc-4.7.0.2-alt-syntax-mak.patch
 Patch9: mc-4.7.5.1-alt-defaults.patch
 Patch10: mc-4.7.0.2-alt-menu.patch
-Patch11: mc-4.7.0.10-alt-extfs-udar.patch
+Patch11: mc-4.7.5.3-alt-extfs-udar.patch
 
 # Debian
 Patch51: mc-4.7.0-debian-mc.ext-use-arj.patch
@@ -34,7 +35,8 @@ Patch51: mc-4.7.0-debian-mc.ext-use-arj.patch
 Patch101: mc-4.7.0.2-savannah-edit-homekey.patch
 
 # Errata
-Patch500: mc-4.7.5.1-find_content_enable_by_default.patch
+Patch500: mc.git-cc0257cd5a34261439152f331b8d93014109cbff.patch
+Patch501: mc.git-e4961563c4019892d8965779c6979c38c2f68017.patch
 
 BuildRequires(pre): rpm-build-licenses
 
@@ -98,11 +100,14 @@ needed for working all components (some vfs for example)
 %patch101 -p1
 
 #Errata
-%patch500 -p1
+# rollback fix for Ticket #81: new problem described in
+# https://www.midnight-commander.org/ticket/2594
+%patch500 -p1 -R
+%patch501 -p1 -R
 
 cat <<EOF > version.h
 #ifndef MC_CURRENT_VERSION
-#define MC_CURRENT_VERSION "4.7.5.1"
+#define MC_CURRENT_VERSION "4.7.5.3"
 #endif
 EOF
 
@@ -127,6 +132,7 @@ rm -rf lib/vfs/mc-vfs/samba/
 install -d %buildroot%_sysconfdir/{profile.d,bashrc.d}
 mv %buildroot%_libexecdir/mc/mc.csh %buildroot%_sysconfdir/profile.d/
 mv %buildroot%_libexecdir/mc/mc.sh %buildroot%_sysconfdir/bashrc.d/
+install -m755 %SOURCE6 %buildroot%_sysconfdir/profile.d/mc.sh
 # Install DosNavigator color scheme
 install -m644 %SOURCE2 .
 # Install Dark color scheme
@@ -189,6 +195,17 @@ install -pD -m644 %SOURCE5 %buildroot%_niconsdir/%name.png
 %files full
 
 %changelog
+* Tue Aug 23 2011 Sergey Y. Afonin <asy@altlinux.ru> 4.7.5.3-alt3
+- moved mc.sh back to bashrc.d (ALT #25703/c#3)
+- added alias definition for zsh in profile.d (ALT #25703)
+- rollback fix for Ticket #81 (new problem described in Ticket #2594)
+
+* Tue Aug 09 2011 Sergey Y. Afonin <asy@altlinux.ru> 4.7.5.3-alt2
+- moved mc.sh from bashrc.d to profile.d (ALT #25703)
+
+* Mon Aug 08 2011 Sergey Y. Afonin <asy@altlinux.ru> 4.7.5.3-alt1
+- 4.7.5.3
+
 * Sat Feb 12 2011 Sergey Y. Afonin <asy@altlinux.ru> 4.7.5.1-alt2
 - adopted for 4.7.5.1 and reenabled patches:
     mc-4.7.5.1-alt-forceexec.patch
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin