Open MrBlaise opened 2 months ago
Update:
I've tried building it against the main branch. This time the build finished successfully, so this issue must have been fixed since the latest release. However when I try to build it with FLASH support it fails, so now it becomes a FLASH issue.
The following error occurs:
CC cache/lru_cache.o
cache/lru_cache.cc:98:12: error: variable 'count' set but not used [-Werror,-Wunused-but-set-variable]
uint32_t count = 0;
^
1 error generated.
make[3]: *** [cache/lru_cache.o] Error 1
make[2]: *** [rocksdb] Error 2
We were able to work around it by running the make command like so:
make ENABLE_FLASH=yes CFLAGS="-Wno-unused-but-set-variable -I/opt/homebrew/opt/openssl/include" LDFLAGS="-L/opt/homebrew/opt/openssl/lib" KEYDB_LDFLAGS="-L/opt/homebrew/opt/zstd/lib -L/opt/homebrew/opt/lz4/lib -L/opt/homebrew/opt/snappy/lib"
The error in my latest comment was solved by adding: -Wno-unused-but-set-variable
. On top of that we had to manually set all the libs required for FLASH as on macOS they aren't resolved automatically. We also needed to add LDFLAGS=“-L/opt/homebrew/opt/openssl/lib”
specifically for hiredis.
This seems to work for both the latest stable release (6.3.4) and the main branch.
UPDATE: See my comment. The issue seems to be solved on the latest commit, but building with FLASH support is still broken.
Describe the bug
I am trying to build KeyDB from source as the binary available through homebrew was not built with Flash support enabled. The build fails with the following error:
To reproduce Doesn't matter whether I build with ENABLE_FLASH or not the issue is the same, so it is probably not connected to FLASH support at all.
git clone git@github.com:Snapchat/KeyDB.git
git checkout v6.3.4
git submodule init && git submodule update
make
Expected behavior
KeyDB should be built on MacOS
Additional information
MacOS Sonoma Version 14.4.1 - M1 Apple Silicon (ARM)