Skip to content

Commit ab7697c

Browse files
authored
Avoid doctests in cross-compile CI (#855)
1 parent bdbf6d1 commit ab7697c

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.github/workflows/cross.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,9 +75,15 @@ jobs:
7575
run: |
7676
echo 'AWS_LC_SYS_EXTERNAL_BINDGEN=0' >> "$GITHUB_ENV"
7777
- if: ${{ matrix.target[0] == 'x86_64-unknown-illumos' }}
78-
# TODO: Restructure the build options
7978
run: |
8079
echo 'CROSS_TEST_EXTRA_FLAG=--no-run' >> "$GITHUB_ENV"
80+
- if: ${{ matrix.target[0] != 'x86_64-unknown-illumos' }}
81+
# Since Rust 1.89, doctests run by default.
82+
# When cross-compiling, doctests do not have the environment setup properly to link to shared libraries.
83+
# Per documentation:
84+
# --all-targets Test all targets (does not include doctests)
85+
run: |
86+
echo 'CROSS_TEST_EXTRA_FLAG=--all-targets' >> "$GITHUB_ENV"
8187
- name: Cross-compilation (test release)
8288
run: cross test -p aws-lc-rs --release "${CROSS_TEST_EXTRA_FLAG}" --features unstable --target ${{ matrix.target[0] }}
8389
- if: ${{ matrix.target[1] == 1 }}

0 commit comments

Comments
 (0)