Accepting request 720212 from Base:System

OBS-URL: https://build.opensuse.org/request/show/720212
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/mc?expand=0&rev=77
This commit is contained in:
Dominique Leuenberger 2019-08-07 11:57:14 +00:00 committed by Git OBS Bridge
commit 5c67985fd9
8 changed files with 85 additions and 62 deletions

View File

@ -1,2 +0,0 @@
8d9f1c75369967adfd317a05fef9861444ed049b033e4debaeaafc6df218b431 mc-4.8.22.tar.bz2
ee7868d7ba0498cf2cccefe107d7efee7f2571098806bba2aed5a159db801318 mc-4.8.22.tar.xz

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ee7868d7ba0498cf2cccefe107d7efee7f2571098806bba2aed5a159db801318
size 2538524

2
mc-4.8.23.sha256 Normal file
View File

@ -0,0 +1,2 @@
238c4552545dcf3065359bd50753abbb150c1b22ec5a36eaa02c82808293267d mc-4.8.23.tar.bz2
dd7f7ce74183307b0df25b5c3e60ad3293fd3d3d27d2f37dd7a10efce13dff1c mc-4.8.23.tar.xz

3
mc-4.8.23.tar.xz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:dd7f7ce74183307b0df25b5c3e60ad3293fd3d3d27d2f37dd7a10efce13dff1c
size 2552944

View File

@ -4,11 +4,11 @@ http://www.midnight-commander.org/ticket/287
lib/tty/tty-slang.h | 1 + lib/tty/tty-slang.h | 1 +
2 files changed, 16 insertions(+), 2 deletions(-) 2 files changed, 16 insertions(+), 2 deletions(-)
Index: mc-4.8.11/lib/tty/key.c Index: mc-4.8.23/lib/tty/key.c
=================================================================== ===================================================================
--- mc-4.8.11.orig/lib/tty/key.c 2014-01-01 19:47:50.000000000 +0000 --- mc-4.8.23.orig/lib/tty/key.c
+++ mc-4.8.11/lib/tty/key.c 2014-01-01 19:47:50.000000000 +0000 +++ mc-4.8.23/lib/tty/key.c
@@ -1029,10 +1029,13 @@ correct_key_code (int code) @@ -1050,10 +1050,13 @@ correct_key_code (int code)
mod = KEY_M_SHIFT; mod = KEY_M_SHIFT;
} }
@ -23,9 +23,9 @@ Index: mc-4.8.11/lib/tty/key.c
/* /*
* We are not interested if Ctrl was pressed when entering control * We are not interested if Ctrl was pressed when entering control
* characters, so assume that it was. When checking for such keys, * characters, so assume that it was. When checking for such keys,
@@ -1118,6 +1121,16 @@ correct_key_code (int code) @@ -1126,6 +1129,16 @@ correct_key_code (int code)
if (c >= KEY_F (1) && c <= KEY_F (20))
mod &= ~KEY_M_SHIFT; mod &= ~KEY_M_SHIFT;
}
+ /* + /*
+ * Numerals may require modifilers with some keymaps or on obscure + * Numerals may require modifilers with some keymaps or on obscure
@ -40,7 +40,7 @@ Index: mc-4.8.11/lib/tty/key.c
if (!mc_global.tty.alternate_plus_minus) if (!mc_global.tty.alternate_plus_minus)
switch (c) switch (c)
{ {
@@ -1923,7 +1936,7 @@ get_key_code (int no_delay) @@ -1909,7 +1922,7 @@ get_key_code (int no_delay)
{ {
/* Convert escape-digits to F-keys */ /* Convert escape-digits to F-keys */
if (g_ascii_isdigit (c)) if (g_ascii_isdigit (c))
@ -49,10 +49,10 @@ Index: mc-4.8.11/lib/tty/key.c
else if (c == ' ') else if (c == ' ')
c = ESC_CHAR; c = ESC_CHAR;
else else
Index: mc-4.8.11/lib/tty/tty-slang.h Index: mc-4.8.23/lib/tty/tty-slang.h
=================================================================== ===================================================================
--- mc-4.8.11.orig/lib/tty/tty-slang.h 2013-04-10 21:04:31.000000000 +0100 --- mc-4.8.23.orig/lib/tty/tty-slang.h
+++ mc-4.8.11/lib/tty/tty-slang.h 2014-01-01 19:47:50.000000000 +0000 +++ mc-4.8.23/lib/tty/tty-slang.h
@@ -11,6 +11,7 @@ @@ -11,6 +11,7 @@
/*** typedefs(not structures) and defined constants **********************************************/ /*** typedefs(not structures) and defined constants **********************************************/

View File

@ -1,3 +1,24 @@
-------------------------------------------------------------------
Thu Aug 1 07:21:35 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Use python3 instead of python as we do not need to depend on
python2
- Format with spec-cleaner
- update to 4.8.23:
* Modify "File exists" query dialog (#3935):
* Speed up of large directory structures delete (#3958)
* Support key binding for menu (#212)
* Syntax updates:
+ shell (#3981)
+ ebuild (#3988)
+ RPM spec (#3991)
* Code cleanup (#3955)
* Use Geeqie (a fork of GQview) as main image viewer, fallback to GQview (#3962)
* various small fixes
- Refresh patches:
* mc-multi-press-f-keys.patch
* sftp_interactive_password.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Jan 15 13:37:27 UTC 2019 - adam.majer@suse.de Tue Jan 15 13:37:27 UTC 2019 - adam.majer@suse.de

52
mc.spec
View File

@ -12,17 +12,17 @@
# license that conforms to the Open Source Definition (Version 1.9) # license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative. # published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/ # Please submit bugfixes or comments via https://bugs.opensuse.org/
# #
Name: mc Name: mc
Version: 4.8.23
Release: 0
Summary: Midnight Commander Summary: Midnight Commander
License: GPL-3.0-or-later License: GPL-3.0-or-later
Group: Productivity/File utilities Group: Productivity/File utilities
Url: http://midnight-commander.org/ URL: https://midnight-commander.org/
Version: 4.8.22
Release: 0
Source0: http://ftp.midnight-commander.org/mc-%{version}.tar.xz Source0: http://ftp.midnight-commander.org/mc-%{version}.tar.xz
Source1: x11_browser Source1: x11_browser
Source2: %{name}.desktop Source2: %{name}.desktop
@ -30,26 +30,17 @@ Source3: %{name}.png
Source4: cmake.syntax Source4: cmake.syntax
Source6: http://ftp.midnight-commander.org/%{name}-%{version}.sha256 Source6: http://ftp.midnight-commander.org/%{name}-%{version}.sha256
Patch0: mc-fix_lib_search_path.patch Patch0: mc-fix_lib_search_path.patch
Patch61: mc-extd-misc.patch
Patch62: mc-extd-video.patch
Patch63: mc-extd-doc.patch
Patch64: mc-extd-sound.patch
Patch69: mc-extd-xdg.patch
Patch71: mc-ext-audio.patch
Patch12: mc-wrapper.patch Patch12: mc-wrapper.patch
Patch16: mc-esc-seq.patch Patch16: mc-esc-seq.patch
Patch17: mc-rpm.patch Patch17: mc-rpm.patch
Patch20: mc-f-keys.patch Patch20: mc-f-keys.patch
Patch21: mc-extfs-helpers-deb.patch Patch21: mc-extfs-helpers-deb.patch
# add patch. bnc#856501 # add patch. bnc#856501
# http://www.midnight-commander.org/ticket/3128 # http://www.midnight-commander.org/ticket/3128
Patch22: mc-vfs-fish-deleted_source_file.patch Patch22: mc-vfs-fish-deleted_source_file.patch
# changed mc-extfs-iso9660-xorriso.patch # changed mc-extfs-iso9660-xorriso.patch
# to reflect upstream fix # to reflect upstream fix
Patch23: mc-extfs-iso9660-xorriso.patch Patch23: mc-extfs-iso9660-xorriso.patch
#Debian fixes #Debian fixes
Patch32: 20_wrong_path_to_wrappers.patch Patch32: 20_wrong_path_to_wrappers.patch
# PATCH-FIX-UPSTREAM mc-multi-press-f-keys.patch mc287 sbrabec@suse.cz - Fixed Esc + Numeral F-key emulation. # PATCH-FIX-UPSTREAM mc-multi-press-f-keys.patch mc287 sbrabec@suse.cz - Fixed Esc + Numeral F-key emulation.
@ -59,11 +50,14 @@ Patch41: mc-multi-press-f-keys.patch
Patch52: mc-pie.patch Patch52: mc-pie.patch
# mc-startup-timeout.patch mc3082 nadvornik@suse.cz - fix for long timeout on startup, bnc#824729 # mc-startup-timeout.patch mc3082 nadvornik@suse.cz - fix for long timeout on startup, bnc#824729
Patch60: mc-startup-timeout.patch Patch60: mc-startup-timeout.patch
Patch61: mc-extd-misc.patch
Patch62: mc-extd-video.patch
Patch63: mc-extd-doc.patch
Patch64: mc-extd-sound.patch
Patch69: mc-extd-xdg.patch
Patch71: mc-ext-audio.patch
Patch100: xls2csv_update.patch Patch100: xls2csv_update.patch
Patch101: sftp_interactive_password.patch Patch101: sftp_interactive_password.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: audiofile-devel BuildRequires: audiofile-devel
BuildRequires: e2fsprogs-devel BuildRequires: e2fsprogs-devel
BuildRequires: gettext >= 0.18.1 BuildRequires: gettext >= 0.18.1
@ -79,7 +73,8 @@ BuildRequires: xorg-x11-devel
BuildRequires: xz BuildRequires: xz
Requires(pre): permissions Requires(pre): permissions
Recommends: %{name}-lang = %{version} Recommends: %{name}-lang = %{version}
Recommends: mkisofs xorriso Recommends: mkisofs
Recommends: xorriso
%description %description
GNU Midnight Commander (also referred to as MC) is a user shell much GNU Midnight Commander (also referred to as MC) is a user shell much
@ -95,6 +90,7 @@ MC needs several other programs for its various extfs extensions, e.g.
isoinfo (from mkisofs) or xorriso for the iso:// extension. isoinfo (from mkisofs) or xorriso for the iso:// extension.
%lang_package %lang_package
%prep %prep
echo "`grep %{name}-%{version}.tar.xz %{SOURCE6} | head -n1 | cut -c1-64` %{SOURCE0}" | sha256sum -c echo "`grep %{name}-%{version}.tar.xz %{SOURCE6} | head -n1 | cut -c1-64` %{SOURCE0}" | sha256sum -c
%setup -q %setup -q
@ -111,7 +107,7 @@ echo "`grep %{name}-%{version}.tar.xz %{SOURCE6} | head -n1 | cut -c1-64` %{SOU
%patch20 %patch20
%patch21 %patch21
%patch22 -p1 %patch22 -p1
%patch23 -p0 %patch23
%patch32 %patch32
%patch41 -p1 %patch41 -p1
%patch52 -p1 %patch52 -p1
@ -120,14 +116,16 @@ echo "`grep %{name}-%{version}.tar.xz %{SOURCE6} | head -n1 | cut -c1-64` %{SOU
%patch101 -p1 %patch101 -p1
%build %build
autoreconf --force --install autoreconf -fvi
%define warn_flags -W -Wall -Wstrict-prototypes -Wpointer-arith -Wformat-security -Wno-unused-parameter %define warn_flags -W -Wall -Wstrict-prototypes -Wpointer-arith -Wformat-security -Wno-unused-parameter
export CFLAGS="$RPM_OPT_FLAGS %{warn_flags}" export CFLAGS="%{optflags} %{warn_flags}"
export X11_WWW="%{_datadir}/mc/x11_browser" export X11_WWW="%{_datadir}/mc/x11_browser"
export PYTHON=%{_bindir}/python3
%configure \ %configure \
--localstatedir=/var/lib \ --localstatedir=%{_localstatedir}/lib \
--enable-charset \ --enable-charset \
--enable-vfs-smb --with-smb-configdir=%{_sysconfdir}/samba \ --enable-vfs-smb --with-smb-configdir=%{_sysconfdir}/samba \
--disable-vfs-fish --disable-vfs-fish
@ -135,7 +133,7 @@ export X11_WWW="%{_datadir}/mc/x11_browser"
make %{?_smp_mflags} V=1 make %{?_smp_mflags} V=1
%install %install
make DESTDIR=%{buildroot} install %make_install
# clean up this setuid problem for now # clean up this setuid problem for now
chmod 755 %{buildroot}/%{_libexecdir}/mc/cons.saver chmod 755 %{buildroot}/%{_libexecdir}/mc/cons.saver
@ -147,8 +145,8 @@ mkdir -p %{buildroot}%{_sysconfdir}/profile.d
ln -fs -t %{buildroot}%{_sysconfdir}/profile.d %{_datadir}/mc/mc.{,c}sh ln -fs -t %{buildroot}%{_sysconfdir}/profile.d %{_datadir}/mc/mc.{,c}sh
#support script for calling available GUI webbrosers #support script for calling available GUI webbrosers
install -m 755 %{SOURCE1} %{buildroot}%{_datadir}/mc/ install -m 755 %{SOURCE1} %{buildroot}%{_datadir}/mc/
install -D -m 644 %{S:3} %{buildroot}%{_datadir}/pixmaps/%{name}.png install -D -m 644 %{SOURCE3} %{buildroot}%{_datadir}/pixmaps/%{name}.png
install -D -m 644 %{S:3} %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/%{name}.png install -D -m 644 %{SOURCE3} %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/%{name}.png
for f in ext.d/misc.sh ext.d/sound.sh ext.d/video.sh \ for f in ext.d/misc.sh ext.d/sound.sh ext.d/video.sh \
extfs.d/gitfs+ extfs.d/uace extfs.d/uarc ; extfs.d/gitfs+ extfs.d/uace extfs.d/uarc ;
@ -156,11 +154,11 @@ do
sed -i -e '1s@bin/sh@bin/bash@' "%{buildroot}%{_libexecdir}/mc/${f}" sed -i -e '1s@bin/sh@bin/bash@' "%{buildroot}%{_libexecdir}/mc/${f}"
done done
%suse_update_desktop_file -i %name System FileManager %suse_update_desktop_file -i %{name} System FileManager
# Remove not supported language # Remove not supported language
rm -rf %{buildroot}%{_datadir}/locale/be@tarask rm -rf %{buildroot}%{_datadir}/locale/be@tarask
%find_lang %name %find_lang %{name}
%post %post
%if 0%{?suse_version} >= 1140 %if 0%{?suse_version} >= 1140
@ -210,7 +208,7 @@ rm -rf %{buildroot}%{_datadir}/locale/be@tarask
%dir %{_datadir}/icons/hicolor/32x32/apps %dir %{_datadir}/icons/hicolor/32x32/apps
%{_datadir}/icons/hicolor/32x32/apps/%{name}.png %{_datadir}/icons/hicolor/32x32/apps/%{name}.png
%files lang -f %name.lang %files lang -f %{name}.lang
%if 0%{?suse_version} < 1140 || 0%{?sles_version} && 0%{?sles_version} <= 11 %if 0%{?suse_version} < 1140 || 0%{?sles_version} && 0%{?sles_version} <= 11
%lang(sv) %dir %{_datadir}/locale/sv_SE %lang(sv) %dir %{_datadir}/locale/sv_SE
%lang(sv) %dir %{_datadir}/locale/sv_SE/LC_MESSAGES %lang(sv) %dir %{_datadir}/locale/sv_SE/LC_MESSAGES

View File

@ -1,7 +1,4 @@
Upstream: https://midnight-commander.org/ticket/3921 commit 7910ef3ee50a847edf72d755381699f169d46278
Bugzilla: 1098235
commit 83e7624292232562639d13f76d84126e6779e54b
Author: Adam Majer <amajer@suse.de> Author: Adam Majer <amajer@suse.de>
Date: Mon Jun 25 15:06:38 2018 +0200 Date: Mon Jun 25 15:06:38 2018 +0200
@ -15,10 +12,10 @@ Date: Mon Jun 25 15:06:38 2018 +0200
Signed-off-by: Adam Majer <amajer@suse.de> Signed-off-by: Adam Majer <amajer@suse.de>
diff --git a/src/vfs/sftpfs/connection.c b/src/vfs/sftpfs/connection.c diff --git a/src/vfs/sftpfs/connection.c b/src/vfs/sftpfs/connection.c
index 537159129..19a49874f 100644 index 537159129..a6b7d1b2c 100644
--- a/src/vfs/sftpfs/connection.c --- a/src/vfs/sftpfs/connection.c
+++ b/src/vfs/sftpfs/connection.c +++ b/src/vfs/sftpfs/connection.c
@@ -292,6 +292,50 @@ sftpfs_open_connection_ssh_key (struct vfs_s_super *super, GError ** mcerror) @@ -292,6 +292,53 @@ sftpfs_open_connection_ssh_key (struct vfs_s_super *super, GError ** mcerror)
return ret_value; return ret_value;
} }
@ -41,7 +38,8 @@ index 537159129..19a49874f 100644
+ +
+static const char *kbi_passwd; +static const char *kbi_passwd;
+static const struct vfs_s_super *kbi_super; +static const struct vfs_s_super *kbi_super;
+static LIBSSH2_USERAUTH_KBDINT_RESPONSE_FUNC(keyboard_interactive_helper) +static
+LIBSSH2_USERAUTH_KBDINT_RESPONSE_FUNC (keyboard_interactive_helper)
+{ +{
+ int i; + int i;
+ int len; + int len;
@ -53,14 +51,16 @@ index 537159129..19a49874f 100644
+ if (!kbi_super || !kbi_passwd) + if (!kbi_super || !kbi_passwd)
+ return; + return;
+ +
+ if (strncmp(name, kbi_super->path_element->user, name_len) != 0) + if (strncmp (name, kbi_super->path_element->user, name_len) != 0)
+ return; + return;
+ +
+ // assume these are password prompts + // assume these are password prompts
+ len = strlen(kbi_passwd); + len = strlen (kbi_passwd);
+ for (i=0; i<num_prompts; ++i) { + for (i = 0; i < num_prompts; ++i)
+ if (strncmp(prompts[i].text, "Password: ", prompts[i].length) == 0) { + {
+ responses[i].text = strdup(kbi_passwd); + if (strncmp (prompts[i].text, "Password: ", prompts[i].length) == 0)
+ {
+ responses[i].text = strdup (kbi_passwd);
+ responses[i].length = len; + responses[i].length = len;
+ } + }
+ } + }
@ -69,15 +69,17 @@ index 537159129..19a49874f 100644
/* --------------------------------------------------------------------------------------------- */ /* --------------------------------------------------------------------------------------------- */
/** /**
* Open connection to host using password. * Open connection to host using password.
@@ -323,6 +367,16 @@ sftpfs_open_connection_ssh_password (struct vfs_s_super *super, GError ** mcerro @@ -323,6 +370,18 @@ sftpfs_open_connection_ssh_password (struct vfs_s_super *super, GError ** mcerro
LIBSSH2_ERROR_EAGAIN); LIBSSH2_ERROR_EAGAIN);
if (rc == 0) if (rc == 0)
return TRUE; return TRUE;
+ +
+ kbi_super = super; + kbi_super = super;
+ kbi_passwd = super->path_element->password; + kbi_passwd = super->path_element->password;
+ while ((rc = libssh2_userauth_keyboard_interactive (super_data->session, super->path_element->user, + while ((rc =
+ keyboard_interactive_helper)) == + libssh2_userauth_keyboard_interactive (sftpfs_super->session,
+ super->path_element->user,
+ keyboard_interactive_helper)) ==
+ LIBSSH2_ERROR_EAGAIN); + LIBSSH2_ERROR_EAGAIN);
+ kbi_super = NULL; + kbi_super = NULL;
+ kbi_passwd = NULL; + kbi_passwd = NULL;
@ -86,7 +88,7 @@ index 537159129..19a49874f 100644
} }
p = g_strdup_printf (_("sftp: Enter password for %s "), super->path_element->user); p = g_strdup_printf (_("sftp: Enter password for %s "), super->path_element->user);
@@ -337,6 +391,17 @@ sftpfs_open_connection_ssh_password (struct vfs_s_super *super, GError ** mcerro @@ -337,6 +396,19 @@ sftpfs_open_connection_ssh_password (struct vfs_s_super *super, GError ** mcerro
passwd)) == LIBSSH2_ERROR_EAGAIN) passwd)) == LIBSSH2_ERROR_EAGAIN)
; ;
@ -94,9 +96,11 @@ index 537159129..19a49874f 100644
+ { + {
+ kbi_super = super; + kbi_super = super;
+ kbi_passwd = passwd; + kbi_passwd = passwd;
+ while ((rc = libssh2_userauth_keyboard_interactive (super_data->session, super->path_element->user, + while ((rc =
+ keyboard_interactive_helper)) + libssh2_userauth_keyboard_interactive (sftpfs_super->session,
+ == LIBSSH2_ERROR_EAGAIN); + super->path_element->user,
+ keyboard_interactive_helper)) ==
+ LIBSSH2_ERROR_EAGAIN);
+ kbi_super = NULL; + kbi_super = NULL;
+ kbi_passwd = NULL; + kbi_passwd = NULL;
+ } + }