HAMR-codegen #35
This file contains 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
name: HAMR-codegen | |
on: | |
workflow_dispatch: | |
inputs: | |
use_sireum_release: | |
type: boolean | |
description: Use latest Sireum release rather than building from source | |
default: false | |
push: | |
paths: | |
- 'micro-examples/**' | |
- 'isolette/**' | |
- 'open-platform-models/isolate-ethernet-simple' | |
schedule: | |
- cron: "0 2 * * 6" # every sunday at 2am | |
jobs: | |
ci: | |
runs-on: ubuntu-latest | |
container: jasonbelt/microkit_domain_scheduling:latest | |
name: HAMR-codegen | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: INSPECTA-models | |
submodules: recursive | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: Sireum | |
repository: sireum/kekinian | |
submodules: recursive | |
- name: Cache Java | |
id: cache-java | |
uses: actions/cache@v4 | |
with: | |
path: Sireum/bin/linux/java | |
key: ${{ runner.os }}-${{ hashFiles('Sireum/versions.properties') }}-java | |
- name: Cache Scala | |
id: cache-scala | |
uses: actions/cache@v4 | |
with: | |
path: Sireum/bin/scala | |
key: ${{ runner.os }}-${{ hashFiles('Sireum/versions.properties') }}-scala | |
- name: Cache Coursier | |
id: cache-coursier | |
uses: actions/cache@v4 | |
with: | |
path: Sireum/cache/coursier | |
key: ${{ runner.os }}-${{ hashFiles('Sireum/versions.properties') }}-coursier | |
- name: Cache OSATE | |
id: cache-osate | |
uses: actions/cache@v4 | |
with: | |
path: Sireum/bin/linux/osate | |
key: ${{ runner.os }}-${{ hashFiles('Sireum/hamr/codegen/jvm/src/main/resources/phantom_versions.properties') }}-osate | |
- name: Build | |
shell: bash | |
run: | | |
export HOME=/home/microkit | |
source $HOME/.bashrc | |
# get the location of the microkit sdk inside the container. The ci scripts | |
# require MICROKIT_SDK be set in order to build the seL4 images | |
export MICROKIT_SDK=$(find /home/microkit/microkit/release/ -type d -name microkit-sdk*) | |
export MICROKIT_BOARD=qemu_virt_aarch64 | |
export DEMO_ROOT=$HOME/provers | |
mv $(pwd)/INSPECTA-models $DEMO_ROOT/ | |
rm -rf ${DEMO_ROOT}/Sireum # remove bootstrap version | |
export SIREUM_HOME=$(pwd)/Sireum | |
export PATH=$SIREUM_HOME/bin:$PATH | |
echo "${{ github.event.inputs.use_sireum_release }}" | |
if [ "${{ github.event.inputs.use_sireum_release }}" = "true" ]; then | |
#(DIR=Sireum && export SIREUM_V=master && rm -fR $DIR && mkdir -p $DIR/bin && cd $DIR/bin && curl -JLso init.sh https://raw.githubusercontent.com/sireum/kekinian/$SIREUM_V/bin/init.sh && bash init.sh) | |
(DIR=Sireum && export SIREUM_V=master && mkdir -p $DIR/bin && cd $DIR/bin && curl -JLso init.sh https://raw.githubusercontent.com/sireum/kekinian/$SIREUM_V/bin/init.sh && bash init.sh) | |
else | |
$SIREUM_HOME/bin/build.cmd setup | |
rm -rf $SIREUM_HOME/out | |
fi | |
sireum | |
sireum slang run $SIREUM_HOME/hamr/codegen/bin/build.cmd install-osate-gumbo | |
export OSATE_HOME=$SIREUM_HOME/bin/linux/osate | |
export ASP_BIN=/home/microkit/provers/asp-libs/bin | |
#env | |
$DEMO_ROOT/INSPECTA-models/.github/workflows/hamr/hamr-ci.cmd |