luau-lang / luau

A fast, small, safe, gradually typed embeddable scripting language derived from Lua
https://luau-lang.org
MIT License
3.8k stars 352 forks source link

Build fails with `LUAU_BUILD_CLI OFF` in 0.618 #1208

Closed snaulX closed 3 months ago

snaulX commented 3 months ago

I'm using luau in my game using CPM - wrapper around CMake's FetchContent.

CPMAddPackage(
    NAME Luau
    GIT_TAG 0.617
    GITHUB_REPOSITORY luau-lang/luau
    OPTIONS
    "LUAU_BUILD_CLI OFF"
    "LUAU_BUILD_TESTS OFF"
    "LUAU_BUILD_WEB OFF"
)

When I updated luau to 0.618 it gets me error:

CMake Error at build/release/_deps/luau-src/CMakeLists.txt:26 (add_library):
  No SOURCES given to target: Luau.CLI.lib

When I set option LUAU_BUILD_CLI to ON - it compiles successful.
Is LUAU_BUILD_CLI still valid after 0.617?

edunad commented 3 months ago

Encountering the same issue with version 0.618 , also using CPM

[cmake] CMake Error at .cache/cpm/luau/5a36f1405dd4de49bd1dfe272cad26d52096480f/CMakeLists.txt:26 (add_library):
[cmake]   No SOURCES given to target: Luau.CLI.lib

Luau.Ast tries to link Luau.CLI.lib even if not available https://github.com/luau-lang/luau/commit/c1830d8b813bbd79b2b3d94efa978a257bfb41b0#diff-1e7de1ae2d059d21e1dd75d5812d5a34b0222cef273b7c3a2af62eb747f9d20aR74

vegorov-rbx commented 3 months ago

Should be fixed!