[Seeking Volunteers] Add new builds to CacheLib
Hi, we're looking for volunteers to add support for newer build platforms such as Ubuntu 24.04 and Debian 12.
You will need to add support for new platforms in https://github.com/facebook/CacheLib/tree/main/contrib
For example, prerequisite for ubuntu 22 is the same as ubuntu 18 (https://github.com/facebook/CacheLib/blob/main/contrib/build.sh#L166), which is specified by https://github.com/facebook/CacheLib/blob/main/contrib/prerequisites-ubuntu18.sh.
Hi! I would like to help as best as I can. Do you have a list of all the platforms planned to support CacheLib?
Hi @vaavaav thanks for reaching out. We hope we can have support for ubuntu 24 and the latest Fedora at least. The expectation would be you can create a script like this (https://github.com/facebook/CacheLib/blob/main/contrib/prerequisites-ubuntu18.sh), and wire it up into the main build script (https://github.com/facebook/CacheLib/blob/main/contrib/build.sh).
Then cachelib team will create a github action to run it.
@haowu14
I wanted to share my findings and get an opinion regarding a compatibility issue.
I successfully built CacheLib (using the most stable release, v20240320_stable) on Ubuntu 24.04 and 22.04. However, building on Ubuntu 18.04 and 20.04 fails due to a dependency issue with Folly.
I gathered that Folly requires at least g++-11 to compile: https://github.com/facebook/folly/issues/1444#issuecomment-2492668230 (be aware that this might not be completely true). Unfortunately, on Ubuntu 18.04 and 20.04, there isn't a straightforward way to install g++-11 using standard methods (e.g., a simple apt-get install).
The workaround I found involves:
# Ensure software-properties-common is installed
sudo apt-get update
sudo apt-get install -y software-properties-common
# Add the required repository for newer GCC versions
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
# Install g++-11
sudo apt-get install -y g++-11
# Update the alternatives to use g++-11
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 100
sudo update-alternatives --config g++
Is this approach too intrusive to include directly in prerequisites-ubuntu18.sh?
@vaavaav We are now using 'getdeps' to sync stuff across OSS projects. We would love for you to volunteer to improve out builds. I will close this for now as I clean up our open issues. We can continue discussing in a new thread if you want. Thank you!