2021-10-06 00:13:31 +13:00
|
|
|
name: Continuous Build Linux
|
2021-10-05 21:42:36 +13:00
|
|
|
|
|
|
|
on:
|
2021-10-06 07:57:33 +13:00
|
|
|
push:
|
2021-10-07 04:27:51 +13:00
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
tags-ignore:
|
|
|
|
- '*.*'
|
2021-10-06 07:55:15 +13:00
|
|
|
paths:
|
|
|
|
- 'src/**'
|
2021-10-06 19:19:33 +13:00
|
|
|
- '!src/osx/**'
|
|
|
|
- '!src/freebsd/**'
|
2021-10-06 07:55:15 +13:00
|
|
|
- 'include/**'
|
|
|
|
- 'Makefile'
|
2021-10-05 21:42:36 +13:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
|
2021-10-05 23:33:41 +13:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
container: ubuntu:21.04
|
2021-10-05 21:42:36 +13:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
2021-10-05 23:53:22 +13:00
|
|
|
- name: Install build tools
|
2021-10-05 21:42:36 +13:00
|
|
|
run: |
|
2021-10-05 23:33:41 +13:00
|
|
|
apt update && \
|
|
|
|
apt install coreutils sed git build-essential gcc-11 g++-11 -y
|
2021-10-06 02:24:51 +13:00
|
|
|
apt install -y g++-11-aarch64-linux-gnu g++-11-i686-linux-gnu \
|
2021-10-06 02:56:15 +13:00
|
|
|
g++-11-arm-linux-gnueabi g++-11-arm-linux-gnueabihf g++-11-riscv64-linux-gnu \
|
2021-10-06 02:24:51 +13:00
|
|
|
g++-11-sparc64-linux-gnu
|
|
|
|
|
2021-10-06 02:04:51 +13:00
|
|
|
mkdir -p multiarch_bin
|
2021-10-06 02:24:51 +13:00
|
|
|
|
2021-10-06 02:56:15 +13:00
|
|
|
git init # [fix Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).]
|
|
|
|
|
2021-10-06 01:16:08 +13:00
|
|
|
- name: Compile x86_64
|
|
|
|
run: |
|
|
|
|
make CXX=g++-11 ARCH=x86_64 STATIC=true QUIET=true
|
2021-10-06 02:24:51 +13:00
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-x86_64-$GIT_HASH
|
|
|
|
make distclean
|
|
|
|
|
|
|
|
- name: Compile i686
|
|
|
|
run: |
|
2021-10-06 07:55:15 +13:00
|
|
|
make CXX=i686-linux-gnu-g++-11 ARCH=i686 STATIC=true QUIET=true
|
2021-10-06 02:24:51 +13:00
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-i686-$GIT_HASH
|
2021-10-06 01:53:12 +13:00
|
|
|
make distclean
|
2021-10-06 02:24:51 +13:00
|
|
|
|
2021-10-06 01:16:08 +13:00
|
|
|
- name: Compile aarch64
|
|
|
|
run: |
|
|
|
|
make CXX=aarch64-linux-gnu-g++-11 ARCH=aarch64 STATIC=true QUIET=true
|
2021-10-06 02:24:51 +13:00
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-aarch64-$GIT_HASH
|
2021-10-06 01:53:12 +13:00
|
|
|
make distclean
|
2021-10-06 02:24:51 +13:00
|
|
|
|
|
|
|
- name: Compile armel
|
|
|
|
run: |
|
2021-10-06 07:55:15 +13:00
|
|
|
make CXX=arm-linux-gnueabi-g++-11 ARCH=armel STATIC=true QUIET=true
|
2021-10-06 02:24:51 +13:00
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-armel-$GIT_HASH
|
|
|
|
make distclean
|
|
|
|
|
|
|
|
- name: Compile armhf
|
|
|
|
run: |
|
|
|
|
make CXX=arm-linux-gnueabihf-g++-11 ARCH=armhf STATIC=true QUIET=true
|
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-armhf-$GIT_HASH
|
|
|
|
make distclean
|
|
|
|
|
|
|
|
- name: Compile riscv64
|
|
|
|
run: |
|
|
|
|
make CXX=riscv64-linux-gnu-g++-11 ARCH=riscv64 STATIC=true QUIET=true
|
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-riscv64-$GIT_HASH
|
|
|
|
make distclean
|
|
|
|
|
|
|
|
- name: Compile sparc64
|
|
|
|
run: |
|
|
|
|
make CXX=sparc64-linux-gnu-g++-11 ARCH=sparc64 STATIC=true QUIET=true
|
|
|
|
GIT_HASH=$(git rev-parse --short "$GITHUB_SHA")
|
|
|
|
mv bin/btop multiarch_bin/btop-sparc64-$GIT_HASH
|
|
|
|
make distclean
|
|
|
|
|
2021-10-06 07:20:47 +13:00
|
|
|
- name: Make executable
|
|
|
|
run: |
|
|
|
|
chmod +x multiarch_bin/*
|
|
|
|
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: btop-x86_64
|
|
|
|
path: 'multiarch_bin/btop-x86_64*'
|
|
|
|
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: btop-i686
|
|
|
|
path: 'multiarch_bin/btop-i686*'
|
|
|
|
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: btop-aarch64
|
|
|
|
path: 'multiarch_bin/btop-aarch64*'
|
|
|
|
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: btop-armel
|
|
|
|
path: 'multiarch_bin/btop-armel*'
|
|
|
|
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: btop-armhf
|
|
|
|
path: 'multiarch_bin/btop-armhf*'
|
|
|
|
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: btop-riscv64
|
|
|
|
path: 'multiarch_bin/btop-riscv64*'
|
|
|
|
|
2021-10-05 21:42:36 +13:00
|
|
|
- uses: actions/upload-artifact@v2
|
|
|
|
with:
|
2021-10-06 07:20:47 +13:00
|
|
|
name: btop-sparc64
|
2021-10-06 19:19:33 +13:00
|
|
|
path: 'multiarch_bin/btop-sparc64*'
|