Skip to content

fix: switch to lua5.4 and link against libdisplay-info3 - #13

Merged
Zeno-sole merged 1 commit into
deepin-community:masterfrom
add-uos:fix-display-info-lua54
Nov 5, 2026
Merged

Zeno-sole merged 1 commit into
deepin-community:masterfrom
add-uos:fix-display-info-lua54

Conversation

@add-uos

@add-uos add-uos commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

目的

  1. 链接 libdisplay-info3:按当前 libdisplay-info-dev (0.3.0) 标准链接,mpv/libmpv2 运行时依赖从旧的 libdisplay-info1 (0.1.1) 切换到 libdisplay-info3。mpv 用到的 9 个 di_* 符号及全部结构体在 0.3.0 中 API/ABI 均兼容,无需改动源码。
  2. Lua 从 5.2 切换到 5.4(源码改动以 quilt patch debian/patches/0006-add-lua5.4-support.patch 提交):
    • meson.build / meson.options 依赖探测列表增加 lua54 / lua5.4 / lua-5.4,debian/rules 传 -Dlua=lua5.4;
    • player/lua.c 运行时版本检查放宽为 5.1–5.4;
    • 保留 Lua 5.1/5.2 的宽松 luaL_checkinteger 行为(非整浮点截断而非报错),否则 osc.lua 的 set_virt_mouse_area 会因 "number has no integer representation" 报错失效。

验证

  • dpkg-buildpackage -us -uc -b 构建通过(quilt patch 正常应用/撤销);
  • 生成的 mpv / libmpv2 NEEDED 为 libdisplay-info.so.3 和 liblua5.4.so.0,deb 依赖为 libdisplay-info3 + liblua5.4-0;
  • 实际播放测试(--vo=null --ao=null):osc.lua、ytdl_hook 等内置脚本加载运行无 Lua 报错。

变更依赖

mpv / libmpv2 运行时依赖:libdisplay-info1 → libdisplay-info3,liblua5.2-0 → liblua5.4-0。

@github-actions

github-actions Bot commented Nov 5, 2026

Copy link
Copy Markdown

TAG Bot

TAG: 0.40.0-3+deb13u1deepin3
EXISTED: no
DISTRIBUTION: unstable

@deepin-ci-robot

Copy link
Copy Markdown
Contributor

Hi @add-uos. Thanks for your PR.

I'm waiting for a deepin-community member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@add-uos
add-uos force-pushed the fix-display-info-lua54 branch from feb958e to 718983d Compare November 5, 2026 07:12
@add-uos add-uos changed the title fix: use system-preinstalled libdisplay-info1 and switch to lua5.4 fix: switch to lua5.4 and link against libdisplay-info3 Nov 5, 2026
Log:
- Build against libdisplay-info-dev (0.3.0) normally, so mpv links
  libdisplay-info.so.3 and depends on libdisplay-info3 instead of the
  old libdisplay-info1 soname.
- Switch the Lua scripting engine from lua5.2 to lua5.4 via a quilt
  patch (0006-add-lua5.4-support.patch): probe lua54/lua5.4/lua-5.4 in
  meson.build/meson.options, configure the build with -Dlua=lua5.4,
  and relax the runtime version check in player/lua.c to accept 5.3
  and 5.4.
- The patch also keeps Lua 5.1/5.2's permissive luaL_checkinteger
  behavior (truncate non-integral floats instead of raising "number
  has no integer representation") so scripts like osc.lua keep
  working on 5.4.

Influence: mpv/libmpv2 runtime dependencies change from
libdisplay-info1 to libdisplay-info3 and from liblua5.2-0 to
liblua5.4-0.
@add-uos
add-uos force-pushed the fix-display-info-lua54 branch from 718983d to 3c1e1b4 Compare November 5, 2026 07:25
@deepin-ci-robot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: lzwind
Once this PR has been reviewed and has the lgtm label, please assign liujianqiang-niu for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@Zeno-sole

Copy link
Copy Markdown

/test all

@deepin-ci-robot

Copy link
Copy Markdown
Contributor

/hold
因为该quilt包的上游版本号变更,详情见: deepin-community/infra-settings#134

@Zeno-sole
Zeno-sole merged commit ae841a5 into deepin-community:master Nov 5, 2026
5 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants