LuaLS / LuaLS/lua-language-server

Mingw64 on MSYS2

未关闭
#3,240 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
Lua
星标
4.4k
派生
442
PR 合并指标
30 天内没有已合并 PR

描述

How are you using the lua-language-server?

Other

Which OS are you using?

Windows

What is the issue affecting?

Other

Expected Behaviour

$ make.sh
should detect mingw64

Actual Behaviour

.it detects platform windows

Reproduction steps
  1. Go to '...'
  2. Click '...'
  3. See error '...'
Additional Notes

No response

Log File

/c/software/lua-server/lua-language-server/3rd/luamake /c/software/lua-server/lua-language-server
ninja: no work to do.
/c/software/lua-server/lua-language-server
Plataforma detectada: windows
[0/2] Run test: 3rd/bee.lua/test/test.lua.OS: mingw64 10.0.19045
Arch: x86_64
Compiler: GCC 14.2.0
CRT: libstdc++ 20240801
DEBUG: false
............F...........F......FF...F......F...............................
.............................F..
Failed tests:

  1. filesystem.test_absolute_relative
    3rd/bee.lua/test/test_filesystem.lua:121: expected: true, actual: false
    stack traceback:
    3rd/bee.lua/test/test_filesystem.lua:121: in local 'assertIsAbsolute'
    3rd/bee.lua/test/test_filesystem.lua:128: in upvalue 'filesystem.test_absolute_relative'

  2. filesystem.test_exists
    3rd/bee.lua/test/test_filesystem.lua:321: expected: false, actual: true
    stack traceback:
    3rd/bee.lua/test/test_filesystem.lua:321: in local 'is_exists'
    3rd/bee.lua/test/test_filesystem.lua:331: in upvalue 'filesystem.test_exists'

  3. filesystem.test_rename
    rename: "temp1", "temp2": (generic:13)Permission denied
    stack traceback:
    3rd/bee.lua/test/test_filesystem.lua:474: in local 'rename_ok'
    3rd/bee.lua/test/test_filesystem.lua:504: in upvalue 'filesystem.test_rename'

  4. filesystem.test_current_path
    3rd/bee.lua/test/test_filesystem.lua:516: expected: userdata:/tmp/test_bee, actual: <userdata:C:/m
    sys64/tmp/test_bee>
    stack traceback:
    3rd/bee.lua/test/test_filesystem.lua:516: in upvalue 'filesystem.test_current_path'

  5. filesystem.test_copy_dir
    copy: "temp", "temp1": (generic:17)File exists
    stack traceback:
    3rd/bee.lua/test/test_filesystem.lua:697: in upvalue 'filesystem.test_copy_dir'

  6. filesystem.test_symlink
    create_symlink: "temp.txt", "temp.link": (generic:40)Function not implemented
    stack traceback:
    3rd/bee.lua/test/test_filesystem.lua:831: in local 'test_create'
    3rd/bee.lua/test/test_filesystem.lua:858: in upvalue 'filesystem.test_symlink'

  7. filewatch.test_symlink
    create_symlink: "C:/msys64/tmp/test_bee/temp/test1", "C:/msys64/tmp/test_bee/temp/test1": (generic:4
    0)Function not implemented
    stack traceback:
    3rd/bee.lua/test/test_filewatch.lua:89: in upvalue 'filewatch.test_symlink'

Ran 107 tests in 1.373 seconds, 100 successes, 7 failures

FAILED: build/_/bee-test
build/bin/lua-language-server.exe 3rd/bee.lua/test/test.lua
ninja: build stopped: subcommand failed.

In file code_format.lua just modified --victor line to avoid using utf-8 flag

local lm = require 'luamake'

lm.c = lm.compiler == 'msvc' and 'c89' or 'c11'
lm.cxx = 'c++17'

lm:source_set 'code_format' {
    rootdir = '../3rd/EmmyLuaCodeStyle',
    includes = {
        "Util/include",
        "CodeFormatCore/include",
        "LuaParser/include",
        "../bee.lua/3rd/lua",
        "3rd/wildcards/include"
    },
    sources = {
        -- codeFormatLib
        "CodeFormatLib/src/*.cpp",
        -- LuaParser
        "LuaParser/src/**/*.cpp",
        -- Util
        "Util/src/StringUtil.cpp",
        "Util/src/Utf8.cpp",
        "Util/src/SymSpell/*.cpp",
        "Util/src/InfoTree/*.cpp",
        --CodeService
        "CodeFormatCore/src/**/*.cpp",
    },
    windows = {
        --flags = "/utf-8", --victor
    },
    macos = {
        flags = "-Wall -Werror",
    },
    linux = {
        flags = "-Wall -Werror"
    }
}

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从 make.sh 及其针对 MSYS2 Mingw64 环境的平台检测路径开始。重现构建,并检查 3rd/bee.lua/test/test_filesystem.lua 和 test_filewatch.lua 中列出的失败,尤其是路径、重命名、复制和 symlink 相关的情况。完成的标准是正确检测到 Mingw64,并且受影响测试的行为已得到解决或有明确记录。

由索引模型根据 Issue 内容生成。

评估

技术栈
lua, shell
领域
build-system, operating-systems
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。