X Tutup
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions .github/actions/install-linux-deps/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# This action installs a few dependencies necessary to build RustPython on Linux.
# It can be configured depending on which libraries are needed:
#
# ```
# - uses: ./.github/actions/install-linux-deps
# with:
# gcc-multilib: true
# musl-tools: false
# ```
#
# See the `inputs` section for all options and their defaults. Note that you must checkout the
# repository before you can use this action.
#
# This action will only install dependencies when the current operating system is Linux. It will do
# nothing on any other OS (macOS, Windows).

name: Install Linux dependencies
description: Installs the dependencies necessary to build RustPython on Linux.
inputs:
gcc-multilib:
description: Install gcc-multilib (gcc-multilib)
required: false
default: "false"
musl-tools:
description: Install musl-tools (musl-tools)
required: false
default: "false"
gcc-aarch64-linux-gnu:
description: Install gcc-aarch64-linux-gnu (gcc-aarch64-linux-gnu)
required: false
default: "false"
clang:
description: Install clang (clang)
required: false
default: "false"
runs:
using: composite
steps:
- name: Install Linux dependencies
shell: bash
if: ${{ runner.os == 'Linux' }}
run: >
sudo apt-get update

sudo apt-get install
${{ fromJSON(inputs.gcc-multilib) && 'gcc-multilib' || '' }}
${{ fromJSON(inputs.musl-tools) && 'musl-tools' || '' }}
${{ fromJSON(inputs.clang) && 'clang' || '' }}
${{ fromJSON(inputs.gcc-aarch64-linux-gnu) && 'gcc-aarch64-linux-gnu' || '' }}
17 changes: 14 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,11 @@ jobs:
target: i686-unknown-linux-gnu

- name: Install gcc-multilib and musl-tools
run: sudo apt-get update && sudo apt-get install gcc-multilib musl-tools
uses: ./.github/actions/install-linux-deps
with:
gcc-multilib: true
musl-tools: true

- name: Check compilation for x86 32bit
run: cargo check --target i686-unknown-linux-gnu ${{ env.CARGO_ARGS_NO_SSL }}

Expand All @@ -244,7 +248,10 @@ jobs:
target: aarch64-unknown-linux-gnu

- name: Install gcc-aarch64-linux-gnu
run: sudo apt install gcc-aarch64-linux-gnu
uses: ./.github/actions/install-linux-deps
with:
gcc-aarch64-linux-gnu: true

- name: Check compilation for aarch64 linux gnu
run: cargo check --target aarch64-unknown-linux-gnu ${{ env.CARGO_ARGS_NO_SSL }}

Expand Down Expand Up @@ -597,8 +604,12 @@ jobs:
- uses: Swatinem/rust-cache@v2
- name: Setup Wasmer
uses: wasmerio/setup-wasmer@v3

- name: Install clang
run: sudo apt-get update && sudo apt-get install clang -y
uses: ./.github/actions/install-linux-deps
with:
clang: true

- name: build rustpython
run: cargo build --release --target wasm32-wasip1 --features freeze-stdlib,stdlib --verbose
- name: run snippets
Expand Down
Loading
X Tutup