Files
eifrah-awsandGitHub 162e824edc Fix Lua Module Build For MacOS Compatibility (#3123)
This PR fixes various issues with Lua module built on macOS using CMake
/ Apple Clang.

## Summary of changes

The Lua module build configuration has been updated to support macOS in
addition to Linux. Two key changes were made to resolve build issues on
Apple platforms.

First, the valkeylua shared library now explicitly includes `sha1.c` and
`rand.c` source files and links against the fpconv library, ensuring all
required symbols are available at link time.

Second, the --disable-new-dtags linker flag is now conditionally applied
only on Unix systems excluding macOS, since this flag is not supported
by the Apple linker.

In addition, enable position independent code compilation for the fpconv
static library by setting the `POSITION_INDEPENDENT_CODE` property. This
allows the library to be linked into shared libraries and
position-independent executables.

Last, the Lua library filename definition was previously hardcoded to
use the `.so` extension for all platforms. This change conditionally
sets the library name based on the target platform: `.so` for Linux/Unix
systems and `.dylib` for macOS (and other non-Linux Unix systems). This
ensures that the correct dynamic library extension is used when loading
the Lua module at runtime.

** Generated by CodeLite. **

Signed-off-by: Eran Ifrah <[email protected]>
2026-01-29 22:39:59 +01:00
..

libfpconv


Fast and accurate double to string conversion based on Florian Loitsch's Grisu-algorithm[1].

This port contains a subset of the 'C' version of Fast and accurate double to string conversion based on Florian Loitsch's Grisu-algorithm available at github.com/night-shift/fpconv).

[1] https://www.cs.tufts.edu/~nr/cs257/archive/florian-loitsch/printf.pdf