Skip to content

TMP

TMP #357

Workflow file for this run

name: CI
permissions:
contents: read
on: [push, pull_request]
jobs:
# build-linux:
# name: Build and test Linux executable
# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# matrix:
# arch: [amd64]
# #, armv7, aarch64, ppc64le, riscv64, i386]
#
# steps:
# - uses: actions/checkout@v4
#
# - name: Prepare
# run: chmod u+x .github/workflows/*.sh
#
# - name: Build for matrix.arch == amd64
# if: ${{ matrix.arch == 'amd64' }}
# run: |
# sudo .github/workflows/generic-build.sh ${{ matrix.arch }}
# sudo .github/workflows/ci-run-tests.sh
# wget https://codecov.io/bash || true
# bash bash -s /tmp/kcov-kcov || true
#
# - name: Build for matrix.arch == i386
# if: ${{ matrix.arch == 'i386' }}
# run: |
# chmod u+x ./.github/workflows/setup-i386.sh
# sudo .github/workflows/setup-i386.sh
# sudo schroot -c mychroot -- ./.github/workflows/generic-build.sh ${{ matrix.arch }}
#
# - name: Build for matrix.arch == armv7, aarch64, ppc64le
# if: ${{ matrix.arch == 'armv7' || matrix.arch == 'aarch64' || matrix.arch == 'ppc64le' || matrix.arch == 'riscv64' }}
# uses: uraimo/run-on-arch-action@v2
# with:
# arch: ${{ matrix.arch }}
# distro: ubuntu22.04
# run: |
# .github/workflows/generic-build.sh ${{ matrix.arch }}
#
build-osx:
name: Build OSX executable (macos-latest)
runs-on: macos-latest
env:
CC: clang
CXX: clang++
steps:
- uses: actions/checkout@v4
- name: Prepare
run: |
chmod u+x .github/workflows/osx-build.sh .github/workflows/ci-run-tests.sh
brew install zlib bash cmake pkgconfig python@3.9 openssl@1.1 dwarfutils
- name: Build for OSX
run: |
sudo .github/workflows/osx-build.sh
sudo .github/workflows/ci-run-tests.sh
# build-freebsd:
# runs-on: ubuntu-22.04
# name: Build and test FreeBSD executable
# steps:
# - uses: actions/checkout@v4
# - name: FreeBSD
# id: test
# uses: vmactions/freebsd-vm@v1
# with:
# usesh: true
# prepare: pkg install -y binutils cmake elfutils python bash git python2
# run: |
# chmod u+x .github/workflows/freebsd-build.sh .github/workflows/ci-run-tests.sh
# .github/workflows/freebsd-build.sh x86_64
# .github/workflows/ci-run-tests.sh
build-and-push-docker-image:
name: Build and push to Docker Hub
needs: [build-linux, build-osx, build-freebsd]

Check failure on line 86 in .github/workflows/ci.yml

View workflow run for this annotation

GitHub Actions / CI

Invalid workflow file

The workflow is not valid. .github/workflows/ci.yml (Line: 86, Col: 13): Job 'build-and-push-docker-image' depends on unknown job 'build-linux'. .github/workflows/ci.yml (Line: 86, Col: 37): Job 'build-and-push-docker-image' depends on unknown job 'build-freebsd'.
runs-on: ubuntu-latest
environment:
name: "Docker Hub"
url: https://hub.docker.com/r/kcov/kcov
#if: github.ref == 'refs/heads/master'
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Docker Hub login
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
# https://github.com/docker/setup-qemu-action
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
# https://github.com/docker/setup-buildx-action
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push the docker image (latest)
# https://github.com/docker/buildx#building
run: |
docker buildx build \
--tag $IMAGE_TAG \
--platform $PLATFORM \
.
env:
IMAGE_TAG: kcov/kcov:latest
# All (build on the base image):
# - linux/386
# - linux/amd64
# - linux/arm/v6
# - linux/arm/v7
# - linux/arm64/v8
# - linux/ppc64le
# - linux/mips64le
# - linux/riscv64
# - linux/s390x
# Does not build:
# - linux/s390x
# - linux/mips64le
# No users on this platform:
# - linux/ppc64le
PLATFORM: linux/amd64