Search code examples
c++ubuntuwindows-subsystem-for-linuxio-uringproxygen

Error Building Proxygen (Networking Library) on Ubuntu 22.04.4, WSL


I'm following the instructions on Proxygen's github repository to build and install it. They say to just run ./build.sh in the proxygen directory. Once proxygen builds, I get errors that all say undefined reference to folly::AsyncIoUringSocket. There is something going on with the liburing library.

When I first tried to build proxygen, I got compiler errors relating to function calls in proxygen to liburing functions that didn't exist. proxygen was clearly using a different version of liburing than what was installed, so I removed and reinstalled the liburing-dev package, reran ./build.sh, and those errors were fixed. But now I'm getting these aforementioned linking errors.

While building, this warning comes up if it means anything: "The package name passed to find_package_handle_standard_args (LIBURING) does not match the name of the calling package (LibUring)." But I get the same type of CMake warning with every other dependency, and those all build fine.

I'm on Windows 10, using WSL and Ubuntu 22.04.4. I have GCC 11.4. They've only tested proxygen on Ubuntu 18.04 but say "it should work on many other platforms." I've tried installing proxygen with vcpkg and linuxbrew, and got build errors both times. Please have mercy, I've been using Windows and Visual Studio all my life and am completely new to CMake tools and Linux. If there's more info I should give, please ask.

Thank you very much in advance


Solution

  • I found the problem. Turns out Ubuntu didn't have the latest version of liburing installed. I reinstalled it but that didn't work, it still installed the old version. So I had to remove liburing, clone the liburing git repo, build it, and install it with sudo make install. What a joke.

    But after I built the library, I was running out of memory. I gave WSL 14 GB of memory in my .wslconfig file, and that didn't work either. So I ran the script with -j 1 to limit the # of processes, and FINALLY that worked.