-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
[3.12] gh-122544: Change OS image in GitHub Actions to Ubuntu 24.04 (#122566) #126621
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
ff4a33e
gh-122544: Change OS image in GitHub Actions to Ubuntu 24.04 (#122566)
Damien-Chen fb52fc4
remove wasi
Damien-Chen bfc7fcc
Add lib for nis module in ubuntu-24.04
Damien-Chen 7e9e463
Modify as reviewer suggest
Damien-Chen a823caa
Merge branch '3.12' into 3.12
hugovk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
name: Reusable WASI | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
config_hash: | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
build_wasi_reusable: | ||
name: 'build and test' | ||
timeout-minutes: 60 | ||
runs-on: ubuntu-24.04 | ||
env: | ||
WASMTIME_VERSION: 22.0.0 | ||
WASI_SDK_VERSION: 24 | ||
WASI_SDK_PATH: /opt/wasi-sdk | ||
CROSS_BUILD_PYTHON: cross-build/build | ||
CROSS_BUILD_WASI: cross-build/wasm32-wasi | ||
steps: | ||
- uses: actions/checkout@v4 | ||
# No problem resolver registered as one doesn't currently exist for Clang. | ||
- name: "Install wasmtime" | ||
uses: bytecodealliance/actions/wasmtime/setup@v1 | ||
with: | ||
version: ${{ env.WASMTIME_VERSION }} | ||
- name: "Restore WASI SDK" | ||
id: cache-wasi-sdk | ||
uses: actions/cache@v4 | ||
with: | ||
path: ${{ env.WASI_SDK_PATH }} | ||
key: ${{ runner.os }}-wasi-sdk-${{ env.WASI_SDK_VERSION }} | ||
- name: "Install WASI SDK" | ||
if: steps.cache-wasi-sdk.outputs.cache-hit != 'true' | ||
run: | | ||
mkdir ${{ env.WASI_SDK_PATH }} && \ | ||
curl -s -S --location https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-${{ env.WASI_SDK_VERSION }}/wasi-sdk-${{ env.WASI_SDK_VERSION }}.0-x86_64-linux.tar.gz | \ | ||
tar --strip-components 1 --directory ${{ env.WASI_SDK_PATH }} --extract --gunzip | ||
- name: "Configure ccache action" | ||
uses: hendrikmuhs/ccache-action@v1.2 | ||
with: | ||
save: ${{ github.event_name == 'push' }} | ||
max-size: "200M" | ||
- name: "Add ccache to PATH" | ||
run: echo "PATH=/usr/lib/ccache:$PATH" >> "$GITHUB_ENV" | ||
- name: "Install Python" | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.x' | ||
- name: "Restore Python build config.cache" | ||
uses: actions/cache@v4 | ||
with: | ||
path: ${{ env.CROSS_BUILD_PYTHON }}/config.cache | ||
# Include env.pythonLocation in key to avoid changes in environment when setup-python updates Python. | ||
# Include the hash of `Tools/wasm/wasi.py` as it may change the environment variables. | ||
# (Make sure to keep the key in sync with the other config.cache step below.) | ||
key: ${{ github.job }}-${{ runner.os }}-${{ env.IMAGE_VERSION }}-${{ env.WASI_SDK_VERSION }}-${{ env.WASMTIME_VERSION }}-${{ inputs.config_hash }}-${{ hashFiles('Tools/wasm/wasi.py') }}-${{ env.pythonLocation }} | ||
- name: "Configure build Python" | ||
run: python3 Tools/wasm/wasi.py configure-build-python -- --config-cache --with-pydebug | ||
- name: "Make build Python" | ||
run: python3 Tools/wasm/wasi.py make-build-python | ||
- name: "Restore host config.cache" | ||
uses: actions/cache@v4 | ||
with: | ||
path: ${{ env.CROSS_BUILD_WASI }}/config.cache | ||
# Should be kept in sync with the other config.cache step above. | ||
key: ${{ github.job }}-${{ runner.os }}-${{ env.IMAGE_VERSION }}-${{ env.WASI_SDK_VERSION }}-${{ env.WASMTIME_VERSION }}-${{ inputs.config_hash }}-${{ hashFiles('Tools/wasm/wasi.py') }}-${{ env.pythonLocation }} | ||
- name: "Configure host" | ||
# `--with-pydebug` inferred from configure-build-python | ||
run: python3 Tools/wasm/wasi.py configure-host -- --config-cache | ||
- name: "Make host" | ||
run: python3 Tools/wasm/wasi.py make-host | ||
- name: "Display build info" | ||
run: make --directory ${{ env.CROSS_BUILD_WASI }} pythoninfo | ||
- name: "Test" | ||
run: make --directory ${{ env.CROSS_BUILD_WASI }} test |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.