Midnight commander and Python3 support

Lefteris

New Member


Messages: 13

Hi, I have seen a lot of ports changes in the latest port tree of FreeBSD v12.0 a few days ago and just about all Python port dependencies I have switched to Python3 except midnight commander. Are there any known plans to do so for MC as well? I didn't see any options to build it manually using python3 (is there a way to do that?) but I would rather use the binary updates.

Lefteris
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 8,444
Messages: 32,483

I have seen a lot of ports changes in the latest port tree of FreeBSD v12.0 a few days ago
Nothing more than the usual churn. I'm betting you're looking at a lot of changes because the quarterly branch was updated from Q2 to Q3.

just about all Python port dependencies I have switched to Python3
The default Python changed several months ago. I'm not entirely sure if that happened before or after the Q2 branching.

Are there any known plans to do so for MC as well?
Eventually all ports will need to switch as Python 2.7 will be end-of-life.


I didn't see any options to build it manually using python3
There's no option for it, it's pretty much "hard-coded":
Code:
USES= gmake gnome libtool perl5 pkgconfig python:2.7,run shebangfix tar:xz
(is there a way to do that?)
You can try removing the 2.7 from the USES line but I'm betting it's not going to work (or else this would have been done already).
 
OP
OP
L

Lefteris

New Member


Messages: 13

I saw that and was thinking of switching the 2.7 to 3.6 but I thought it was there for a reason. Thank you
 
OP
OP
L

Lefteris

New Member


Messages: 13

I tried it a few times actually and I would prefer it over MC as it is lighter indeed but I had a few issues. Adjusting terminal size for example would core dump. Colors were not that great either.
 

_martin

Aspiring Daemon

Reaction score: 171
Messages: 818

was thinking of switching the 2.7 to 3.6
Lefteris That's exactly what I did. I use mc heavily but I don't want to deal with the py27 mess. Manually editing Makefile and keeping that in mind for future updates will be painful but lesser of two evils.
According to this: #3936 there's no dependency on python in mc. ldd output proves that too.
I guess some plugins may depend on it. Never used any, so hard to say.
But I haven't encountered any issues with mc so far.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 8,444
Messages: 32,483

Those two plugins are installed by default and appear to be the only two files that require python. The uc1541 plugin allows browsing C64/C128 D64 disk images. The s3+ plugin allows browsing Amazon's S3 storage. I can test the uc1541 plugin, I have a rather large collection of C64 disks. I'm not able to test S3 though.
 

_martin

Aspiring Daemon

Reaction score: 171
Messages: 818

As SirDice mentioned there there are two python plugins in mc by default. They are under /usr/local/libexec/mc/extfs.d. Both of them are python3 scripts. Beats me why port requires python2. It may be an error.
I've contacted the port maintainer to check if this is an error or not.

EDIT: Eh, while script has python3 header it's python2 code. I guess this is a result of manual edit of Makefile. I don't care about these plugins but it's a pitty I didn't check this before contacting maintainer.
 

woodsb02

Active Member

Reaction score: 69
Messages: 165

Hi folks, the misc/mc port maintainer here... sorry I have been non-responsive on this thread until now - life has been busy.

Status update as of today, looking at the 2 upstream bugs for the 2 mc plugins that depend on python:
  • #3936 uc1541 - plugin has been fixed for the upcoming mc 4.8.24 release
  • #3904 s3+ - plugin currently broken anyway
Given this, when I update the port to 4.8.24 (after it is released), I will change the dependency to python3.
 
Top