mirror of
https://github.com/linux-msm/cdba.git
synced 2026-02-25 13:11:56 -08:00
Without big development activity, thus workflows triggered on changes, CI builds might never run. In the same time distros actually change, so things can get be broken due to external (distro) reasons. This is especially true for development versions, like Debian testing. Run at least once per week, to be sure everything still builds even without development activity. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
195 lines
5.8 KiB
YAML
195 lines
5.8 KiB
YAML
# SPDX-License-Identifier: GPL-2.0
|
|
#
|
|
# Copyright (c) 2021 Canonical Ltd.
|
|
# Copyright (c) 2023 Linaro Ltd
|
|
# Author: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
|
|
# <krzk@kernel.org>
|
|
#
|
|
# Loosely based on: https://github.com/linux-test-project/ltp
|
|
# https://github.com/linux-nfc/neard
|
|
#
|
|
name: "Builds"
|
|
on:
|
|
pull_request:
|
|
push:
|
|
schedule:
|
|
# Run at 1:01 PM, every Tuesday
|
|
- cron: '1 13 * * 2'
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
job:
|
|
name: Build
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
actions: read
|
|
contents: read
|
|
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
arch: [x86-64]
|
|
compiler: [gcc, clang]
|
|
container:
|
|
- archlinux:latest
|
|
- debian:testing
|
|
- debian:stable
|
|
- debian:bookworm
|
|
- debian:bullseye
|
|
- debian:buster
|
|
# Fails on configure on GCC and clang (process restrictions?)
|
|
# - fedora:rawhide
|
|
- fedora:latest
|
|
- fedora:39
|
|
- fedora:38
|
|
- fedora:37
|
|
- ubuntu:lunar # EOL 01.2024
|
|
- ubuntu:jammy
|
|
- ubuntu:focal
|
|
- ubuntu:bionic
|
|
- ubuntu:xenial
|
|
cross_compile: [""]
|
|
variant: [""]
|
|
include:
|
|
# Debian 32-bit builds
|
|
- container: "debian:testing"
|
|
arch: i386
|
|
compiler: gcc -m32
|
|
cross_compile: i686-linux-gnu
|
|
variant: i386
|
|
pkg_config_path: /usr/lib/i386-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:stable"
|
|
arch: i386
|
|
compiler: gcc -m32
|
|
cross_compile: i686-linux-gnu
|
|
variant: i386
|
|
pkg_config_path: /usr/lib/i386-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:bookworm"
|
|
arch: i386
|
|
compiler: gcc -m32
|
|
cross_compile: i686-linux-gnu
|
|
variant: i386
|
|
pkg_config_path: /usr/lib/i386-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:buster"
|
|
arch: i386
|
|
compiler: gcc -m32
|
|
cross_compile: i686-linux-gnu
|
|
variant: i386
|
|
pkg_config_path: /usr/lib/i386-linux-gnu/pkgconfig
|
|
|
|
# Debian cross compilation builds
|
|
- container: "debian:testing"
|
|
arch: armhf
|
|
compiler: arm-linux-gnueabihf-gcc
|
|
cross_compile: arm-linux-gnueabihf
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/arm-linux-gnueabihf/pkgconfig
|
|
|
|
- container: "debian:testing"
|
|
arch: arm64
|
|
compiler: aarch64-linux-gnu-gcc
|
|
cross_compile: aarch64-linux-gnu
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/aarch64-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:testing"
|
|
arch: ppc64el
|
|
compiler: powerpc64le-linux-gnu-gcc
|
|
cross_compile: powerpc64le-linux-gnu
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/powerpc64le-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:testing"
|
|
arch: s390x
|
|
compiler: s390x-linux-gnu-gcc
|
|
cross_compile: s390x-linux-gnu
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/s390x-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:stable"
|
|
arch: armhf
|
|
compiler: arm-linux-gnueabihf-gcc
|
|
cross_compile: arm-linux-gnueabihf
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/arm-linux-gnueabihf/pkgconfig
|
|
|
|
- container: "debian:stable"
|
|
arch: arm64
|
|
compiler: aarch64-linux-gnu-gcc
|
|
cross_compile: aarch64-linux-gnu
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/aarch64-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:stable"
|
|
arch: ppc64el
|
|
compiler: powerpc64le-linux-gnu-gcc
|
|
cross_compile: powerpc64le-linux-gnu
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/powerpc64le-linux-gnu/pkgconfig
|
|
|
|
- container: "debian:stable"
|
|
arch: s390x
|
|
compiler: s390x-linux-gnu-gcc
|
|
cross_compile: s390x-linux-gnu
|
|
variant: cross-compile
|
|
pkg_config_path: /usr/lib/s390x-linux-gnu/pkgconfig
|
|
|
|
container:
|
|
image: ${{ matrix.container }}
|
|
env:
|
|
ARCH: ${{ matrix.arch }}
|
|
CC: ${{ matrix.compiler }}
|
|
CROSS_COMPILE: ${{ matrix.cross_compile }}
|
|
MODE: ${{ matrix.mode }}
|
|
VARIANT: ${{ matrix.variant }}
|
|
PKG_CONFIG_PATH: ${{ matrix.pkg_config_path }}
|
|
|
|
steps:
|
|
- name: Show OS
|
|
run: cat /etc/os-release
|
|
|
|
- name: Show env (matrix settings)
|
|
run: |
|
|
echo "ARCH: $ARCH"
|
|
echo "CC: $CC"
|
|
echo "CROSS_COMPILE: $CROSS_COMPILE"
|
|
echo "MODE: $MODE"
|
|
echo "VARIANT: $VARIANT"
|
|
|
|
- name: Git checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Install additional packages
|
|
run: |
|
|
INSTALL=${{ matrix.container }}
|
|
INSTALL="${INSTALL%%:*}"
|
|
INSTALL="${INSTALL%%/*}"
|
|
./ci/$INSTALL.sh
|
|
if [ "$VARIANT" ]; then ./ci/$INSTALL.$VARIANT.sh; fi
|
|
|
|
- name: Compiler version
|
|
run: $CC --version
|
|
|
|
- name: Display environment and Linux version
|
|
run: |
|
|
test -f /etc/issue && cat /etc/issue
|
|
echo "############################################"
|
|
lsb_release -a || true
|
|
echo "############################################"
|
|
cat /usr/include/linux/version.h
|
|
echo "############################################"
|
|
uname -a
|
|
echo "############################################"
|
|
cat /proc/cmdline
|
|
echo "############################################"
|
|
printenv
|
|
|
|
- name: Compile
|
|
run: make -j$(nproc)
|
|
|
|
- name: Install
|
|
run: make install
|