Skip to content

Commit

Permalink
build: prepare for 1.56
Browse files Browse the repository at this point in the history
  • Loading branch information
georgik committed Oct 21, 2021
1 parent 9f18cc3 commit bd3f1c2
Showing 1 changed file with 1 addition and 85 deletions.
86 changes: 1 addition & 85 deletions .github/workflows/build-rust-on-tag.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: build-rust-on-tag
name: create-rust-release

on:
push:
Expand All @@ -22,87 +22,3 @@ jobs:
release_name: Release ${{ github.ref }}
draft: false
prerelease: false

build-idf-rust:
name: Build Rust for ${{ matrix.os }}
needs: create_release
runs-on: ${{ matrix.os }}
strategy:
matrix:
#os: [macos-latest, self-hosted-macos-arm64, ubuntu-latest, windows-latest]
#os: [macos-latest, ubuntu-18.04 ]
#os: [macos-latest, ubuntu-18.04, windows-latest]
#os: [ubuntu-18.04]
#os: [windows-latest]
os: [macos-latest]
# os: [ [self-hosted, Windows, X64] ]
# os: [ [self-hosted, macOS, M1] ]
include:
- os: macos-latest
ARCH: ''
TARGET: macos-x64
ASSET_PATH: 'build/dist/rust-1.55.0-dev-x86_64-apple-darwin.tar.xz'
ASSET_NAME: 'rust-1.55.0-dev-x86_64-x86_64-apple-darwin.tar.xz'
ASSET_CONTENT_TYPE: 'application/x-tar'
#- os: ubuntu-18.04
# ARCH: ''
# TARGET: linux-x64
# ASSET_PATH: 'build/dist/rust-1.55.0-dev-x86_64-unknown-linux-gnu.tar.xz'
# ASSET_NAME: 'rust-1.55.0-dev-x86_64-unknown-linux-gnu.tar.xz'
# ASSET_CONTENT_TYPE: 'application/x-tar'
#- os: windows-latest
# ARCH: ''
# TARGET: win-x64
# ASSET_PATH: 'build/dist/esp.zip'
# ASSET_NAME: 'rust-1.55.0-dev-x86_64-pc-windows-msvc.zip'
# ASSET_CONTENT_TYPE: 'application/zip'
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
repository: esp-rs/rust
ref: esp-1.55.0
- name: Set up Python
if: ${{ matrix.os == 'macos-latest' || matrix.os == 'ubuntu-latest' || matrix.os == 'ubuntu-18.04' || matrix.os == 'windows-latest' }}
uses: actions/setup-python@v2
with:
python-version: '3.8'
- name: Setup Ninja
if: ${{ matrix.os == 'macos-latest' || matrix.os == 'ubuntu-latest' || matrix.os == 'ubuntu-18.04' || matrix.os == 'windows-latest' }}
uses: seanmiddleditch/gha-setup-ninja@master
- name: Prepare build
run: python3 src/bootstrap/configure.py --experimental-targets=Xtensa --enable-extended --tools=rustfmt --dist-compression-formats='xz'
- name: Build with x.py - only components
if: ${{ matrix.os == 'windows-latest' }}
run: |
python3 x.py build compiler/rustc src/tools/rustfmt library/std --stage 2
python3 x.py dist src --stage 2
- name: Build with x.py - dist packages
if: ${{ matrix.os == 'macos-latest' || matrix.os == 'ubuntu-latest' || matrix.os == 'ubuntu-18.04' }}
run: python3 x.py dist --stage 2
# Excluding src/doc breaks build of 1.55
#run: python3 x.py dist --stage 2 --exclude src/doc
- name: Dist bundle for Windows
if: ${{ matrix.os == 'windows-latest' }}
shell: bash
run: |
mkdir -p build/dist/esp
cp -r build/x86_64-pc-windows-msvc/stage2/* build/dist/esp
tar xf ../rust-src-1.55.0-dev.tar.xz
cp -r rust-src-1.55.0-dev/* build/dist/esp
cd build/dist
find . -name '*.pdb' -delete
zip -r esp.zip esp
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create_release.outputs.upload_url }}
asset_path: ${{ matrix.ASSET_PATH }}
asset_name: ${{ matrix.ASSET_NAME }}
# asset_path: build/dist/rust-1.55.0-dev-aarch64-apple-darwin.tar.xz
# asset_name: rust-1.55.0-dev-aarch64-apple-darwin.tar.xz
asset_content_type: ${{ matrix.ASSET_CONTENT_TYPE }}

0 comments on commit bd3f1c2

Please sign in to comment.