From 5552ad2cd27c1402b100da0357215b1379b02f81 Mon Sep 17 00:00:00 2001 From: Alex Hornby Date: Tue, 19 Sep 2023 20:16:41 +0100 Subject: [PATCH] add missing openssl system dep to folly folly is is missing a linux system dep for openssl. Add one so that install-system-deps knows to install openssl rpms/debs. openssl getdeps manifest already relies on system openssl on linux so its ok for folly to depend on it Test plan: run on a fresh ubuntu 20.04 toolbox which doesn't have openssl already: ``` ./build/fbcode_builder/getdeps.py --allow-system-packages install-system-deps --recursive folly ./build/fbcode_builder/getdeps.py --allow-system-packages build --no-tests --src-dir=. folly ``` Before, error ``` CMake Error at /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message): Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) (Required is at least version "1.1.1") Call Stack (most recent call first): /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE) /usr/share/cmake-3.16/Modules/FindOpenSSL.cmake:447 (find_package_handle_standard_args) CMake/folly-deps.cmake:81 (find_package) CMakeLists.txt:144 (include) ``` After, works --- .github/workflows/getdeps_linux.yml | 4 ++++ build/fbcode_builder/manifests/folly | 18 +++++------------- 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/.github/workflows/getdeps_linux.yml b/.github/workflows/getdeps_linux.yml index 9b76f839966..ca75b6f941a 100644 --- a/.github/workflows/getdeps_linux.yml +++ b/.github/workflows/getdeps_linux.yml @@ -27,6 +27,8 @@ jobs: run: sudo python3 build/fbcode_builder/getdeps.py --allow-system-packages install-system-deps --recursive folly - name: Fetch boost run: python3 build/fbcode_builder/getdeps.py --allow-system-packages fetch --no-tests boost + - name: Fetch openssl + run: python3 build/fbcode_builder/getdeps.py --allow-system-packages fetch --no-tests openssl - name: Fetch ninja run: python3 build/fbcode_builder/getdeps.py --allow-system-packages fetch --no-tests ninja - name: Fetch cmake @@ -61,6 +63,8 @@ jobs: run: python3 build/fbcode_builder/getdeps.py --allow-system-packages fetch --no-tests xz - name: Build boost run: python3 build/fbcode_builder/getdeps.py --allow-system-packages build --free-up-disk --no-tests boost + - name: Build openssl + run: python3 build/fbcode_builder/getdeps.py --allow-system-packages build --free-up-disk --no-tests openssl - name: Build ninja run: python3 build/fbcode_builder/getdeps.py --allow-system-packages build --free-up-disk --no-tests ninja - name: Build cmake diff --git a/build/fbcode_builder/manifests/folly b/build/fbcode_builder/manifests/folly index 3c17c184e05..a760a329bec 100644 --- a/build/fbcode_builder/manifests/folly +++ b/build/fbcode_builder/manifests/folly @@ -21,25 +21,17 @@ libsodium double-conversion fmt lz4 +openssl snappy zstd -# no openssl or zlib in the linux case, why? +# no zlib in the linux case, why? # these are usually installed on the system # and are the easiest system deps to pull in. -# In the future we want to be able to express -# that a system dep is sufficient in the manifest -# for eg: openssl and zlib, but for now we don't -# have it. - -# macOS doesn't expose the openssl api so we need -# to build our own. -[dependencies.os=darwin] -openssl +# In the future we want zlib manifest to handle +# this for us like the openssl one already does -# Windows has neither openssl nor zlib, so we get -# to provide both +# Windows no zlib, provide it [dependencies.os=windows] -openssl zlib # xz depends on autoconf which does not build on