Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix(CMakeList): Set LUA_STATIC default to "ON" #216

Merged
merged 3 commits into from
Jan 14, 2025

Conversation

iThorgrim
Copy link

Update CMakeLists by setting the LUA_STATIC option to “ON”. This is useful for generating the necessary files.

iThorgrim and others added 3 commits January 9, 2025 17:05
### Eluna Module Updates: Lua Version and Static Linking Support

Recent updates to the **Eluna** module in **AzerothCore** introduce new configuration options to manage Lua versions and static linking:

- **`-DLUA_VERSION=luajit/lua52/lua53/lua54`**: Select the Lua version for the module, supporting LuaJIT, Lua 5.2, 5.3, or 5.4.
- **`-DLUA_STATIC=on/off`**: Configure whether Lua should be linked statically or dynamically.

These options allow flexible Lua integration, building on Eluna's existing capabilities to handle different Lua versions. The changes also improve compatibility and performance by enabling static linking where needed.

#### Integration with Eluna

This functionality extends Eluna's existing support for Lua compatibility, mainly in **ElunaCompat.cpp**, which handles Lua version-specific interactions. These updates enhance Eluna’s adaptability for various Lua configurations in **AzerothCore**.
Copy link
Member

@55Honey 55Honey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

@55Honey 55Honey merged commit 7c8bbb5 into azerothcore:master Jan 14, 2025
1 check passed
@kissingers
Copy link

Thanks, but after fix, the liunx seem use STATIC OFF mode, I use flow parameter to bulid server
cmake ../ -DCMAKE_INSTALL_PREFIX=/root/wow2/ -DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DWITH_WARNINGS=1 -DTOOLS=0 -DSCRIPTS=static -DMODULES=static

image

@kissingers
Copy link

I deleted the include and lib directories, and also removed lua52_interpreter and lua52_compiler from the bin directory. Then test can still work normally, but I don't understand why the extra .h files and liblua52.a, lua52_interpreter, lua52_compiler files are also automatically generated on the server side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants