mirror of
https://github.com/saymrwulf/cryptography.git
synced 2026-05-14 20:37:55 +00:00
pointlessly optimize our ossl custom builds (#8432)
This commit is contained in:
parent
e2d09e269e
commit
10b861206c
2 changed files with 10 additions and 2 deletions
8
.github/workflows/build_openssl.sh
vendored
8
.github/workflows/build_openssl.sh
vendored
|
|
@ -41,6 +41,8 @@ if [[ "${TYPE}" == "openssl" ]]; then
|
|||
# avoid installing the docs (for performance)
|
||||
# https://github.com/openssl/openssl/issues/6685#issuecomment-403838728
|
||||
make install_sw install_ssldirs
|
||||
# delete binaries we don't need
|
||||
rm -rf "${OSSL_PATH}/bin"
|
||||
# For OpenSSL 3.0.0 set up the FIPS config. This does not activate it by
|
||||
# default, but allows programmatic activation at runtime
|
||||
if [[ "${VERSION}" =~ ^3. && "${CONFIG_FLAGS}" =~ enable-fips ]]; then
|
||||
|
|
@ -61,6 +63,10 @@ elif [[ "${TYPE}" == "libressl" ]]; then
|
|||
./config -Wl -Wl,-Bsymbolic-functions -fPIC shared --prefix="${OSSL_PATH}"
|
||||
shlib_sed
|
||||
make -j"$(nproc)" install
|
||||
# delete binaries, libtls, and docs we don't need. can't skip install/compile sadly
|
||||
rm -rf "${OSSL_PATH}/bin"
|
||||
rm -rf "${OSSL_PATH}/share"
|
||||
rm -rf "${OSSL_PATH}/lib/libtls*"
|
||||
popd
|
||||
elif [[ "${TYPE}" == "boringssl" ]]; then
|
||||
git clone https://boringssl.googlesource.com/boringssl
|
||||
|
|
@ -72,6 +78,8 @@ elif [[ "${TYPE}" == "boringssl" ]]; then
|
|||
cmake .. -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DRUST_BINDINGS="$(rustc -V --verbose | grep 'host: ' | sed 's/host: //')" -DCMAKE_INSTALL_PREFIX="${OSSL_PATH}"
|
||||
make -j"$(nproc)"
|
||||
make install
|
||||
# delete binaries we don't need
|
||||
rm -rf "${OSSL_PATH}/bin"
|
||||
popd
|
||||
popd
|
||||
fi
|
||||
|
|
|
|||
4
.github/workflows/ci.yml
vendored
4
.github/workflows/ci.yml
vendored
|
|
@ -83,12 +83,12 @@ jobs:
|
|||
- name: Load OpenSSL cache
|
||||
uses: actions/cache@v3.2.6
|
||||
id: ossl-cache
|
||||
timeout-minutes: 5
|
||||
timeout-minutes: 2
|
||||
with:
|
||||
path: ${{ github.workspace }}/osslcache
|
||||
# When altering the openssl build process you may need to increment the value on the end of this cache key
|
||||
# so that you can prevent it from fetching the cache and skipping the build step.
|
||||
key: ${{ matrix.PYTHON.OPENSSL.TYPE }}-${{ matrix.PYTHON.OPENSSL.VERSION }}-${{ env.CONFIG_HASH }}-6
|
||||
key: ${{ matrix.PYTHON.OPENSSL.TYPE }}-${{ matrix.PYTHON.OPENSSL.VERSION }}-${{ env.CONFIG_HASH }}-8
|
||||
if: matrix.PYTHON.OPENSSL
|
||||
- name: Build custom OpenSSL/LibreSSL
|
||||
run: .github/workflows/build_openssl.sh
|
||||
|
|
|
|||
Loading…
Reference in a new issue