Skip to content

Create Release

Create Release #3

name: Create Release
on:
workflow_dispatch:
inputs:
release_tag:
required: true
type: string
jobs:
release:
permissions:
# Necessary permissions to create a release.
contents: write
env:
BUILD_DIR: build
BRANCH_NAME: ${{ github.event.repository.default_branch }}
RELEASE_BIN_ARCHIVE: qemu-ot-earlgrey-${{ inputs.release_tag }}-x86_64-unknown-linux-gnu.tar.gz
runs-on: ubuntu-20.04
timeout-minutes: 10
steps:
- name: Check out repository
uses: actions/checkout@v3
# Update the package index, then install all dependencies listed in
# the various apt-requirements.txt files in the project.
- name: Install Dependencies
run: |
sudo apt-get update
sudo apt-get install -y ninja-build libpixman-1-dev
- name: Configure
run: |
mkdir "$BUILD_DIR"
cd "$BUILD_DIR"
../configure --target-list=riscv32-softmmu --without-default-features --enable-tcg \
--enable-tools --enable-trace-backends=log
- name: Build
run: |
cd "$BUILD_DIR"
ninja
ninja qemu-img
- name: Create binary archive
run: |
./scripts/opentitan/make_release.sh "$RELEASE_BIN_ARCHIVE" . "$BUILD_DIR"
- name: Create release
env:
GH_TOKEN: ${{ github.token }}
run: |
gh release create \
--target "$BRANCH_NAME" \
${{ inputs.release_tag }} \
--generate-notes \
"$RELEASE_BIN_ARCHIVE#QEMU system emulator"