Skip to content

Add package workflow #14

Add package workflow

Add package workflow #14

Workflow file for this run

name: build and test
on:
push:
branches: [ mob ]
jobs:
create-tag:
runs-on: ubuntu-24.04
permissions: write-all
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Create tag
if: github.ref == 'refs/heads/mob'
shell: bash
env:
GH_TOKEN: ${{ github.token }}
run: |
set -eux
git config --global user.name "github-actions"
git config --global user.email "[email protected]"
TAG="dev"
gh release delete $TAG --yes || true
git tag -d $TAG || true
git push origin --delete $TAG || true
git fetch --tags
git tag -l
git tag $TAG
git push origin $TAG
test-x86_64-linux:
runs-on: ubuntu-20.04
needs: create-tag
timeout-minutes: 20
steps:
- uses: actions/checkout@v4
- name: Package (x86_64-linux)
run: ./configure --prefix=tinycc && make && make install
- name: Release - Attempt 1
uses: softprops/action-gh-release@v2
if: github.ref == 'refs/heads/mob'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: "Development build"
tag_name: dev
fail_on_unmatched_files: true
make_latest: true
files: |
tinycc/
test-aarch64-macos:
runs-on: macos-14
timeout-minutes: 20
steps:
- uses: actions/checkout@v4
- name: Package (aarch64-macos)
run: ./configure --prefix=tinycc && make && make install
test-x86_64-windows:
runs-on: windows-2022
timeout-minutes: 20
steps:
- uses: actions/checkout@v4
- uses: microsoft/setup-msbuild@v2
- name: Package (x86_64-windows)
shell: cmd
run: |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
pushd win32
build-tcc.bat -i tinycc -c cl
popd
echo "Dir ."
dir
echo "Dir win32"
dir win32