Skip to content

Commit

Permalink
vendor openssl for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
yihau committed Oct 8, 2024
1 parent 76335f6 commit ff77792
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 10 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/cargo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ jobs:
with:
version: "v0.8.1"

- name: Set Perl environment variables
if: runner.os == 'Windows'
run: |
echo "PERL=$((where.exe perl)[0])" | Out-File -FilePath $env:GITHUB_ENV -Append -Encoding utf8
echo "OPENSSL_SRC_PERL=$((where.exe perl)[0])" | Out-File -FilePath $env:GITHUB_ENV -Append -Encoding utf8
- shell: bash
run: |
source .github/scripts/install-all-deps.sh ${{ runner.os }}
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/release-artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,18 @@ jobs:
run: |
git checkout ${{ inputs.commit }}
- name: Set Perl environment variables
run: |
echo "PERL=$((where.exe perl)[0])" | Out-File -FilePath $env:GITHUB_ENV -Append -Encoding utf8
echo "OPENSSL_SRC_PERL=$((where.exe perl)[0])" | Out-File -FilePath $env:GITHUB_ENV -Append -Encoding utf8
- name: Build
id: build
shell: bash
run: |
# install all deps
source .github/scripts/install-all-deps.sh ${{ runner.os }}
source /tmp/env.sh
echo "tag=$CI_TAG" >> $GITHUB_OUTPUT
eval "$(ci/channel-info.sh)"
Expand Down
11 changes: 1 addition & 10 deletions storage-bigtable/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ http = { workspace = true }
hyper = { workspace = true }
hyper-proxy = { workspace = true }
log = { workspace = true }
openssl = { workspace = true, features = ["vendored"] }
prost = { workspace = true }
prost-types = { workspace = true }
serde = { workspace = true }
Expand All @@ -36,16 +37,6 @@ tokio = { workspace = true }
tonic = { workspace = true, features = ["tls", "transport"] }
zstd = { workspace = true }

# openssl is a dependency of the goauth and smpl_jwt crates, but explicitly
# declare it here as well to activate the "vendored" feature that builds OpenSSL
# statically...
[target."cfg(not(windows))".dependencies]
openssl = { workspace = true, features = ["vendored"] }
# ...except on Windows to avoid having to deal with getting CI past a build-time
# Perl dependency
[target."cfg(windows)".dependencies]
openssl = { workspace = true, features = [] }

[lib]
crate-type = ["lib"]
name = "solana_storage_bigtable"
Expand Down

0 comments on commit ff77792

Please sign in to comment.