Skip to content

freebsd-x64 dotnet-runtime build #69

freebsd-x64 dotnet-runtime build

freebsd-x64 dotnet-runtime build #69

name: freebsd-x64 dotnet-runtime build
on:
workflow_dispatch:
jobs:
coreclr_Debug:
runs-on: ubuntu-latest
steps:
- name: Remove unnecessary files
run: df -h; sudo rm -rf "$AGENT_TOOLSDIRECTORY"; df -h
- name: runtime+libs+packs build
run: |
git clone https://github.com/am11/runtime -b feature/freebsd-port/outputrid-3 --single-branch --depth 1
docker run --rm -v$(pwd)/runtime:/runtime -e ROOTFS_DIR=/crossrootfs/x64 \
mcr.microsoft.com/dotnet-buildtools/prereqs:cbl-mariner-2.0-cross-amd64-freebsd-14 \
/runtime/build.sh -ci -arch x64 -os freebsd -cross -s clr+libs+host+packs -c Debug -rc Checked
# sh -c '/runtime/build.sh clr+libs+packs -c Debug -os freebsd -cross &&
# tdnf install -y file unzip && cd /tmp &&
# unzip /runtime/artifacts/packages/Debug/Shipping/runtime.freebsd-x64.Microsoft.DotNet.ILCompiler.9.0.0-dev.nupkg &&
# find . -name ilc -exec file {} \;'
# ./dotnet.sh build -v:diag -c Debug -p:TargetOS=freebsd -p:CrossBuild=true src/coreclr/tools/aot/ILCompiler/ILCompiler.csproj'
- name: Upload artifacts
run: |
sudo apt install -y hub
# hub(1) requires release to be created inside a git repo
git clone https://${{ secrets.CLONE_TOKEN }}:[email protected]/${{ github.repository }}.git repo
cd repo
artifacts=" -a ../runtime/artifacts/packages/Debug/Shipping/dotnet-runtime-9.0.0-ci-freebsd-x64.tar.gz"
artifacts+=" -a ../runtime/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Runtime.freebsd-x64.9.0.0-ci.nupkg"
artifacts+=" -a ../runtime/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Runtime.freebsd-x64.9.0.0-ci.symbols.nupkg"
artifacts+=" -a ../runtime/artifacts/packages/Debug/Shipping/Microsoft.DotNet.ILCompiler.9.0.0-ci.nupkg"
artifacts+=" -a ../runtime/artifacts/packages/Debug/Shipping/runtime.freebsd-x64.Microsoft.DotNet.ILCompiler.9.0.0-ci.nupkg"
artifacts+=" -a ../runtime/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Host.freebsd-x64.9.0.0-ci.nupkg"
artifacts+=" -a ../runtime/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Ref.9.0.0-ci.nupkg"
artifacts+=" -a ../runtime/artifacts/bin/coreclr/freebsd.x64.Checked/corehost/singlefilehost.dbg"
tag_name="freebsd_$GITHUB_RUN_ID"
hub release create $artifacts -m "$tag_name" "$tag_name"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}