LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-02-2023, 01:21 AM   #1
giomat
Member
 
Registered: Jul 2017
Posts: 339

Rep: Reputation: 239Reputation: 239Reputation: 239
mpv in -current after lua addition


When lua was added in slackware my mpv build stopped working. I then discovered that it needs to be built with a lower version of lua (5.1 in slackbuilds), so I had to replace the slackware package with the old lua.
I wonder if there's a way to build this old lua in a way that can coexist with other versions, I think it is since in slackbuilds there's lua52 and lua53 recipes which have no conflict with other lua installed.
Since a lot of people seem to use mpv maybe someone has already come up with a solution.
 
Old 09-02-2023, 01:53 AM   #2
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,124

Rep: Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198Reputation: 4198
I'm looking into it to backport a lua51 script and a lua (version 5.4.x) also to the SBo 15.0 repository but it will take some time because there are hundreds of scripts depending on lua and I'm a bit overloaded by other stuff ATM...

note that, last time I tried, I seem to recall that you can avoid building mpv with lua as you can use for the scope also luajit (that you can build and install regardless of any other version of lua installed in the system).

Last edited by ponce; 09-02-2023 at 08:15 AM.
 
Old 09-02-2023, 03:30 AM   #3
giomat
Member
 
Registered: Jul 2017
Posts: 339

Original Poster
Rep: Reputation: 239Reputation: 239Reputation: 239
mille grazie ponce!
I'll modify my queue file and try with luajit then
 
Old 09-02-2023, 06:25 PM   #4
USUARIONUEVO
Senior Member
 
Registered: Apr 2015
Posts: 2,344

Rep: Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942
luajit
Just-in-time compiler and drop-in replacement for Lua 5.1

Then probably can upgrade lua on sbo to same as -current and change dependencies when no support to lua 5.4 and put luajit instead.

But this is a lot of work.
 
Old 09-09-2023, 05:04 AM   #5
fulalas
Member
 
Registered: Jun 2017
Posts: 150

Rep: Reputation: 34
Quote:
Originally Posted by ponce View Post
you can avoid building mpv with lua as you can use for the scope also luajit (that you can build and install regardless of any other version of lua installed in the system).
If you build mpv without Lua it won't enable some features, like statistics about the currently playing file (when pressing 'i'), for instance. Not to mention the support to users scripts. So I guess it's not an option. And there's a reason why mpv won't support newer Lua versions: https://github.com/mpv-player/mpv/wi...ua-53-or-newer

I noticed that in Lua Makefile there's this parameter -DLUA_COMPAT_5_3, so I wondered if adding -DLUA_COMPAT_5_2 and -DLUA_COMPAT_5_1 would fix mpv complaining about Lua being too new, but the build process complained anyway, so I tried to remove the checking and compiled again, then an error in a check during runtime, which I removed and recompiled mpv, but then it gives me this runtime error:

Code:
[osc] 
[osc] stack traceback:
[osc] 	[C]: in function 'mp.input_set_section_mouse_area'
[osc] 	mp.defaults:133: in function 'mp.set_mouse_area'
[osc] 	@osc.lua:191: in function 'set_virt_mouse_area'
[osc] 	@osc.lua:2943: in main chunk
[osc] 	[C]: in ?
[osc] 	[C]: in function 'require'
[osc] 	[string "require '@osc.lua'"]:1: in main chunk
[osc] 	[C]: in ?
[osc] 	[C]: in ?
[osc] Lua error: mp.defaults:133: bad argument #2 to 'input_set_section_mouse_area' (number has no integer representation)
This issue will affect basically all Linux users (not just Slackware) who have mpv and the recent rpm 4.18.1 package.

EDIT: I wasn't expect that but USUARIONUEVO is right: by just installing luajit we can have mpv building/running even when newer lua (e.g. 5.4.6) is present.

Last edited by fulalas; 09-09-2023 at 08:14 AM.
 
Old 09-09-2023, 04:38 PM   #6
DryFalls
Member
 
Registered: Apr 2021
Posts: 44

Rep: Reputation: Disabled
I use a lua-compat package with libraries from lua5.1, 5.2 and 5.3 and with the binaries from 5.3 (extracted from SBo packages) and mpv and conky work fine. The package is only 392k if size is a concern.
 
Old 09-09-2023, 04:58 PM   #7
USUARIONUEVO
Senior Member
 
Registered: Apr 2015
Posts: 2,344

Rep: Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942Reputation: 942
Quote:
Originally Posted by DryFalls View Post
I use a lua-compat package with libraries from lua5.1, 5.2 and 5.3 and with the binaries from 5.3 (extracted from SBo packages) and mpv and conky work fine. The package is only 392k if size is a concern.
overwritten files from original slackware packages ... best ides ever .../ironic off

The way is luajit for packages no want lua up to 5.1.

Archlinux have mpv under luajit and modern code with lua 5.4
 
Old 09-09-2023, 09:42 PM   #8
glorsplitz
Senior Member
 
Registered: Dec 2002
Distribution: slackware!
Posts: 1,314

Rep: Reputation: 368Reputation: 368Reputation: 368Reputation: 368
Quote:
Originally Posted by USUARIONUEVO View Post
Archlinux have mpv under luajit and modern code with lua 5.4
mpv SBo maintainer needs to be let know? I prefer mpv to vlc.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mpv - How to automatically slow down 𝑜𝑛𝑙𝑦 25fps videos to 24fps? autospeed.lua is doing nothing despite other lua scripts working NM64 Linux - Software 11 04-27-2023 04:49 AM
[SOLVED] [INF] Still recommending mpv-0.27 after new mpv release and -current update 1337_powerslacker Slackware 16 12-31-2017 01:17 AM
mkinitrd warnings after kmod addition in current. GazL Slackware 3 06-30-2012 04:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 09:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration