DarkEnergyProcessor / livesim2_async

Love Live! School Idol Festival Live Simulator
https://discord.gg/NgUgnWB
zlib License
95 stars 13 forks source link

macOS Automated Builds #35

Open MikuAuahDark opened 1 year ago

MikuAuahDark commented 1 year ago

Starting from bb3bd9c503bbf8a0ac0ecd942c0ec60d1c2f7455 (master branch) and 22e51889c32d5a1888a57cbfa4e95495ba4468f1 (over_the_rainbow branch), GitHub Actions automatically creates build of the game on each commit.

However, it only build Windows binaries and Linux AppImages for now (and Android coming soon; all of them 64-bit only). LOVE itself has automated macOS build however LS2 needs certain libraries to work optimally hence the macOS workflow steps is commented out.

If anyone has experience dealing with macOS, please let me know so we can discuss things further.

louy2 commented 1 year ago

would like to help

MikuAuahDark commented 1 year ago

Sure, feel free to submit PR for it.

louy2 commented 10 months ago

As a beginning, building ls2x with CMake generated Xcode project gives a ls2xlib.so. Putting that ls2xlib.so in the simulator directory, and love . to run the simulator, runs fine and gives no "ls2xlib module not found" error. Will go on to try to build ls2x on Github Action macOS runner.

MikuAuahDark commented 10 months ago

What about putting ls2xlib.so in the LS2 save directory?

louy2 commented 10 months ago

Love2D has a default list of directories it searches for .so files, listed on launch, shown below. If ls2xlib.so is put in the LS2 save directory, I need to find a way to tell Love2D how to find it. Where is the LS2 save directory btw?

warning: no features.
module 'ls2xlib' not found:
    no field package.preload['ls2xlib']
    no 'ls2xlib' in LOVE game directories.
    no file 'ls2xlib' in LOVE paths.
    no file './ls2xlib.lua'
    no file '/usr/local/share/luajit-2.1/ls2xlib.lua'
    no file '/usr/local/share/lua/5.1/ls2xlib.lua'
    no file '/usr/local/share/lua/5.1/ls2xlib/init.lua'
    no file './ls2xlib.so'
    no file '/usr/local/lib/lua/5.1/ls2xlib.so'
    no file '/usr/local/lib/lua/5.1/loadall.so'
MikuAuahDark commented 10 months ago

The save directory can be found in Settings -> System Information -> R/W Directory. LOVE itself also has its own C module loader with its own search paths controlled using love.filesystem.get/setCRequirePath.

louy2 commented 10 months ago

I see.

I also had misunderstandings. I thought zipping up the repo with the ls2xlib.so file would work, but it seems './ls2xlib.so' is relative to pwd not to the root directory, because the warning still shows when I love livesim2.love.

That said, when I try Autoplaying some beatmaps it does not seem affected. What exactly does ls2x do? Are there test cases I can run to cover more ground?

MikuAuahDark commented 10 months ago

ls2x is required to export your beatmap to video.