Skip to content

Commit

Permalink
add missing openssl system dep to folly
Browse files Browse the repository at this point in the history
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
  • Loading branch information
ahornby committed Sep 27, 2023
1 parent 8384869 commit 5552ad2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 13 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/getdeps_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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
Expand Down
18 changes: 5 additions & 13 deletions build/fbcode_builder/manifests/folly
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 5552ad2

Please sign in to comment.