Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 68037 - midnight commander support for .7z archives
Summary: midnight commander support for .7z archives
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High enhancement (vote)
Assignee: Heinrich Wendel (RETIRED)
URL: http://sgh.nightmail.ru/files/u7z/
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks:
 
Reported: 2004-10-18 10:27 UTC by Alexandru Toma
Modified: 2005-06-10 12:28 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
mc-4.6.0-r11.ebuild.patch (mc-4.6.0-r11.ebuild.patch,1.32 KB, patch)
2004-10-25 04:13 UTC, Alexandru Toma
Details | Diff
mc-4.6.0-7zip.patch (mc-4.6.0-7zip.patch,739 bytes, patch)
2004-10-25 04:14 UTC, Alexandru Toma
Details | Diff
mc-4.6.0-r11.ebuild.patch (mc-4.6.0-r11.ebuild.patch,1.64 KB, patch)
2004-11-06 11:13 UTC, Alexandru Toma
Details | Diff
mc-4.6.0-r13.ebuild.patch (mc-4.6.0-r13.ebuild.patch,2.24 KB, patch)
2005-04-18 01:45 UTC, Alexandru Toma
Details | Diff
test.7z (test.7z,14.27 KB, application/octet-stream)
2005-06-08 03:22 UTC, Heinrich Wendel (RETIRED)
Details
mc-4.6.0-7zip.patch (mc-4.6.0-7zip.patch,619 bytes, patch)
2005-06-10 10:34 UTC, Alexandru Toma
Details | Diff
mc.ini (mc.ini,43 bytes, text/plain)
2005-06-10 11:44 UTC, Alexandru Toma
Details
mc.ext (mc.ext,12.00 KB, text/plain)
2005-06-10 11:46 UTC, Alexandru Toma
Details
mc-4.6.0-7zip.patch (mc-4.6.0-7zip.patch,631 bytes, patch)
2005-06-10 12:01 UTC, Alexandru Toma
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandru Toma 2004-10-18 10:27:06 UTC
Someone on the p7zip forums wrote a script that can be used to add support fot 7z to mc. Maybe it could be added as a use flag (since it would also require app-arch/p7zip)

http://sourceforge.net/forum/forum.php?thread_id=1118009&forum_id=383043

Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Comment 1 Heinrich Wendel (RETIRED) gentoo-dev 2004-10-23 15:18:22 UTC
maybe you can post a patch to the ebuild to include the script?
Comment 2 Alexandru Toma 2004-10-25 04:13:05 UTC
Created attachment 42552 [details, diff]
mc-4.6.0-r11.ebuild.patch

This is completly untested but it should work. The only problem is that, in
order to download the u7z.zip from the forum post I mentioned, a download
script is used which makes it impossible to include the URL in the ebuild.
Therefore, the u7z.zip should be mirrored on the gentoo mirrors and the "7zip?
( Gentoo Mirror )" line from the patch should be corrected to include the
correct URL. The file should probably also be renamed to reflect its version
(0.2 in this case).

The u7z script also depends on which and gawk but I did not include these in
the dependencies since they are already depended on by the system profile.
Comment 3 Alexandru Toma 2004-10-25 04:14:38 UTC
Created attachment 42553 [details, diff]
mc-4.6.0-7zip.patch

mc-4.6.0-vfs.patch should probably be re-created since this patch breaks it (I
think)
Comment 4 Alexandru Toma 2004-10-25 04:16:10 UTC
As I said above, these patches are untested (since I can't do that at the moment), but they should work.
Comment 5 Heinrich Wendel (RETIRED) gentoo-dev 2004-11-06 07:59:56 UTC
i couldn't get this working
Comment 6 Alexandru Toma 2004-11-06 10:56:58 UTC
Yeah... I finally got a chance to test it and, indeed, the script seems to not work the way it's supposed to... What errors did you get?

I'll try emailing the author.
Comment 7 Heinrich Wendel (RETIRED) gentoo-dev 2004-11-06 11:06:01 UTC
if i try to enter the zip file, it shows the content as ascii
Comment 8 Alexandru Toma 2004-11-06 11:13:25 UTC
Created attachment 43422 [details, diff]
mc-4.6.0-r11.ebuild.patch

I remade the patch a little, moving the order of the patches so you don't have
ro remake the vfs patch.

I get a different error... Something like this:
php_books.7z:52: warning [p 2, 9.0i]: can't break line
php_books.7z:56: warning [p 2, 9.5i]: cannot adjust line
php_books.7z:59: warning [p 2, 9.8i]: cannot adjust line
php_books.7z:59: warning [p 2, 10.0i]: can't break line
php_books.7z:60: warning [p 2, 10.2i]: cannot adjust line
php_books.7z:60: warning [p 2, 10.3i]: can't break line
php_books.7z:62: warning [p 2, 10.5i]: cannot adjust line
php_books.7z:62: warning [p 2, 10.7i]: can't break line
php_books.7z:62: warning [p 2, 10.8i]: can't break line
php_books.7z:62: warning [p 3, 0.0i]: can't break line
php_books.7z:63: warning [p 3, 0.2i]: cannot adjust line
php_books.7z:63: warning [p 3, 0.3i]: can't break line
php_books.7z:66: warning [p 3, 0.7i]: cannot adjust line
php_books.7z:69: warning [p 3, 1.0i]: cannot adjust line
php_books.7z:69: warning [p 3, 1.2i]: cannot adjust line
php_books.7z:70: warning [p 3, 1.3i]: cannot adjust line
php_books.7z:70: warning [p 3, 1.5i]: cannot adjust line
php_books.7z:70: warning [p 3, 1.7i]: can't break line
php_books.7z:70: warning [p 3, 1.8i]: can't break line
php_books.7z:70: translation to \troff: Failed assertion at line 122, file
`errarg.cc'.
grotty:<standard input>:14001:warning: no final `x stop' command
groff: troff: Aborted
Comment 9 Heinrich Wendel (RETIRED) gentoo-dev 2005-02-19 12:03:09 UTC
until you can post a working patch
Comment 10 Alexandru Toma 2005-04-18 01:33:41 UTC
I finally had time to update the patch to the latest version of mc available in portage. I have exchanged quite a few emails with the author of u7z and all of the bugs I could find (as well as others) were fixed. It works quite well actually...
Comment 11 Alexandru Toma 2005-04-18 01:45:49 UTC
Created attachment 56563 [details, diff]
mc-4.6.0-r13.ebuild.patch

Sorry for taking so long to post an updated and working patch
Comment 12 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-07 05:51:16 UTC
sorry, i still get only ascii output 
Comment 13 Alexandru Toma 2005-06-07 22:54:30 UTC
I would really like to help solve this problem but I need some information first:
- Could you post the output of `ll /usr/share/mc/extfs/` and the version of
p7zip that you are using?

- Does mc emerge fine with the patches I have supplied? Do the patches apply
cleanly?

- Did you notice the einfo at the end of the ebuild: "You need to remove
~/.mc/bindings...."? Did you do that?

- Could you also attach a sample archive that doesn't work for you (or sent it
to me by email)?
Comment 14 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-08 03:19:26 UTC
heino@heino ~ $ ls -l /usr/share/mc/extfs/ 
total 172 
-rwxr-xr-x  1 root root  2885 Jun  6 14:13 a 
-rwxr-xr-x  1 root root  9443 Jun  6 14:13 apt 
-rwxr-xr-x  1 root root  1308 Jun  6 14:13 audio 
-rwxr-xr-x  1 root root  1205 Jun  6 14:13 bpp 
-rwxr-xr-x  1 root root  4853 Jun  6 14:13 deb 
-rwxr-xr-x  1 root root  4373 Jun  6 14:13 deba 
-rwxr-xr-x  1 root root 10144 Jun  6 14:13 debd 
-rwxr-xr-x  1 root root  8823 Jun  6 14:13 dpkg 
-rw-r--r--  1 root root   829 Jun  6 14:13 extfs.ini 
-rwxr-xr-x  1 root root  2521 Jun  6 14:13 hp48 
-rwxr-xr-x  1 root root  1005 Jun  6 14:13 lslR 
-rwxr-xr-x  1 root root  3441 Jun  6 14:13 mailfs 
-rwxr-xr-x  1 root root  6459 Jun  6 14:13 patchfs 
-rw-r--r--  1 root root  7458 Jun  6 14:13 README 
-rwxr-xr-x  1 root root  8551 Jun  6 14:13 rpm 
-rwxr-xr-x  1 root root  1509 Jun  6 14:13 rpms 
-rw-r--r--  1 root root   649 Jun  6 14:13 sfs.ini 
-rwxr-xr-x  1 root root  6866 Jun  6 14:13 trpm 
-rwxr-xr-x  1 root root  4137 Jun  6 14:13 u7z 
-rwxr-xr-x  1 root root   823 Jun  6 14:13 uar 
-rwxr-xr-x  1 root root  1639 Jun  6 14:13 uarj 
-rwxr-xr-x  1 root root   961 Jun  6 14:13 uha 
-rwxr-xr-x  1 root root  3846 Jun  6 14:13 ulha 
-rwxr-xr-x  1 root root  2581 Jun  6 14:13 urar 
-rwxr-xr-x  1 root root 12872 Jun  6 14:13 uzip 
-rwxr-xr-x  1 root root  1417 Jun  6 14:13 uzoo 
 
Yes, everything applies cleanly. 
 
Yeah, i removed my .mc directory and the global bindings file has 7z in it. 
Comment 15 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-08 03:22:29 UTC
Created attachment 60830 [details]
test.7z

i am using p7zip-4.16
Comment 16 Alexandru Toma 2005-06-08 23:05:21 UTC
I didn't have time to try recompilling mc to see if I have any problems,
however, the archive you provided works just fine for me. What is this global
bindings file and where is it located? Could you try renaming or temporarily
moving it someplace else to see if you still have the same problem? If you do,
could you also post a picture of the ascii output you get. I will also ask the
author to take a look at this bug... he might suggest something.
Comment 17 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-10 03:33:58 UTC
i just commited the ebuild i used as mc-4.6.0-r14, please test it, it does not 
work for me 
Comment 18 Jakub Moc (RETIRED) gentoo-dev 2005-06-10 05:49:10 UTC
Does not work here, spits out a lot of garbage on the screen.
Comment 19 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-10 06:13:45 UTC
i have the same problem, so where is the bug? (you have to enable the 7zip 
useflag) 
Comment 20 Jakub Moc (RETIRED) gentoo-dev 2005-06-10 06:15:27 UTC
(In reply to comment #19)
> (you have to enable the 7zip useflag) 

I generally suck on Fridays but I
Comment 21 Jakub Moc (RETIRED) gentoo-dev 2005-06-10 06:15:27 UTC
(In reply to comment #19)
> (you have to enable the 7zip useflag) 

I generally suck on Fridays but I´m pretty sure I did. ;-)
Comment 22 Alexandru Toma 2005-06-10 06:44:09 UTC
I'm at work right now so I can't check to see if it works for me. I'll do that 
in the evening or maybe tomorrow. It's a good thing that I have the ebuild you 
used. Hopefully, I'll track the problem down.
Comment 23 Alexandru Toma 2005-06-10 10:34:30 UTC
Created attachment 61004 [details, diff]
mc-4.6.0-7zip.patch

Sorry about that. I was using a newer patch locally and forgot to update the
one from bugzilla. It should work with this patch.
Comment 24 Alexandru Toma 2005-06-10 10:36:31 UTC
Also, please add the einfo from mc-4.6.0-r13.ebuild.patch back in. It is
important and would prevent possible erroneous bug reports in the future.
Comment 25 Jakub Moc (RETIRED) gentoo-dev 2005-06-10 11:18:49 UTC
(In reply to comment #22)
> Sorry about that. I was using a newer patch locally and forgot to update the
> one from bugzilla. It should work with this patch.

Well, maybe it
Comment 26 Jakub Moc (RETIRED) gentoo-dev 2005-06-10 11:18:49 UTC
(In reply to comment #22)
> Sorry about that. I was using a newer patch locally and forgot to update the
> one from bugzilla. It should work with this patch.

Well, maybe it´s just me but it does not make much difference..

<snip>
test.7z:29: warning [p 2, 2.2i]: cannot adjust line
test.7z:29: warning [p 2, 2.3i]: can't break line
test.7z:29: warning [p 2, 2.5i]: cannot adjust line
test.7z:29: warning [p 2, 2.7i]: can't break line
test.7z:30: warning [p 2, 2.8i]: can't break line

...

test.7z:38: `F' is an invalid argument to \O
test.7z:39: warning [p 2, 6.5i]: cannot adjust line
test.7z:39: warning [p 2, 6.7i]: can't break line

...

grotty:<standard input>:12517: missing argument
grotty:<standard input>:12518: X command without `tty:' tag ignored
</snip>
Comment 27 Alexandru Toma 2005-06-10 11:42:26 UTC
Did you remove your ~/.mc/bindings file or edited it accordingly. The first
patch I posted here didn't work. You were right and I'm sorry about that.
However, the second should work. I have tested it using the ebuild Heinrich
added to portage and it works just fine. I had been using this patch locally and
it also worked in the past.
Comment 28 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-10 11:44:05 UTC
this patch works for me, commited 
Comment 29 Alexandru Toma 2005-06-10 11:44:37 UTC
Created attachment 61009 [details]
mc.ini

Try placing this in /usr/share/mc and see if it works.
Comment 30 Alexandru Toma 2005-06-10 11:46:29 UTC
Created attachment 61011 [details]
mc.ext

Sorry about that, I uploaded the wrong file :)
Comment 31 Alexandru Toma 2005-06-10 12:01:43 UTC
Created attachment 61018 [details, diff]
mc-4.6.0-7zip.patch

Heinrich, could you please update the patch to match this one. Sorry about this
but this is the syntax recommended by the author in newer versions and I forgot
to update the patch.
Comment 32 Heinrich Wendel (RETIRED) gentoo-dev 2005-06-10 12:06:55 UTC
i replaced the patch, but i don't see a reason to add the einfo, having 
a .mc/bindings file as user does not seem to be very common to me 
Comment 33 Alexandru Toma 2005-06-10 12:16:22 UTC
Well, the reason I added that einfo was because I had a ~/.mc/bindings file and
the patch didn't work for me because of that. The author of u7z told me to
remove the file and then it started working. However, that file was not created
by me... somehow it was automatically created. If you say this is not common
then OK you don't have to add the einfo, but I didn't know how common or
uncommon it was... I thought that everyone has one of those. :)
Comment 34 Jakub Moc (RETIRED) gentoo-dev 2005-06-10 12:28:10 UTC
(In reply to comment #29)
> # 7-Zip, Needs to be before manual page definitions

Duh! Works now. Thanks for patience. ;-)

(In reply to comment #31)
> I thought that everyone has one of those. :)

Never had any such thing there...