2020-12-09 20:08:58 -07:00
|
|
|
name: ci/gh-actions/depends
|
|
|
|
|
2021-04-20 03:47:21 -06:00
|
|
|
on:
|
|
|
|
push:
|
2022-10-01 13:32:58 -06:00
|
|
|
paths-ignore:
|
|
|
|
- 'docs/**'
|
|
|
|
- '**/README.md'
|
2021-04-20 03:47:21 -06:00
|
|
|
pull_request:
|
|
|
|
paths-ignore:
|
|
|
|
- 'docs/**'
|
|
|
|
- '**/README.md'
|
2020-12-09 20:08:58 -07:00
|
|
|
|
2021-09-09 04:57:24 -06:00
|
|
|
env:
|
|
|
|
APT_SET_CONF: |
|
|
|
|
echo "Acquire::Retries \"3\";" | sudo tee -a /etc/apt/apt.conf.d/80-custom
|
|
|
|
echo "Acquire::http::Timeout \"120\";" | sudo tee -a /etc/apt/apt.conf.d/80-custom
|
|
|
|
echo "Acquire::ftp::Timeout \"120\";" | sudo tee -a /etc/apt/apt.conf.d/80-custom
|
|
|
|
CCACHE_SETTINGS: |
|
|
|
|
ccache --max-size=150M
|
|
|
|
ccache --set-config=compression=true
|
2023-09-29 11:13:37 -06:00
|
|
|
USE_DEVICE_TREZOR_MANDATORY: ON
|
2021-09-09 04:57:24 -06:00
|
|
|
|
2020-12-09 20:08:58 -07:00
|
|
|
jobs:
|
2022-06-28 20:51:43 -06:00
|
|
|
build-cross:
|
2022-09-24 13:02:41 -06:00
|
|
|
runs-on: ubuntu-20.04
|
2020-12-09 20:08:58 -07:00
|
|
|
env:
|
|
|
|
CCACHE_TEMPDIR: /tmp/.ccache-temp
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
toolchain:
|
|
|
|
- name: "RISCV 64bit"
|
|
|
|
host: "riscv64-linux-gnu"
|
|
|
|
packages: "python3 gperf g++-riscv64-linux-gnu"
|
|
|
|
- name: "ARM v7"
|
|
|
|
host: "arm-linux-gnueabihf"
|
|
|
|
packages: "python3 gperf g++-arm-linux-gnueabihf"
|
|
|
|
- name: "ARM v8"
|
|
|
|
host: "aarch64-linux-gnu"
|
|
|
|
packages: "python3 gperf g++-aarch64-linux-gnu"
|
|
|
|
- name: "i686 Win"
|
|
|
|
host: "i686-w64-mingw32"
|
2022-09-19 16:01:19 -06:00
|
|
|
packages: "python3 g++-mingw-w64-i686"
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: "i686 Linux"
|
|
|
|
host: "i686-pc-linux-gnu"
|
|
|
|
packages: "gperf cmake g++-multilib python3-zmq"
|
|
|
|
- name: "Win64"
|
|
|
|
host: "x86_64-w64-mingw32"
|
2022-09-19 16:01:19 -06:00
|
|
|
packages: "cmake python3 g++-mingw-w64-x86-64"
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: "x86_64 Linux"
|
|
|
|
host: "x86_64-unknown-linux-gnu"
|
|
|
|
packages: "gperf cmake python3-zmq libdbus-1-dev libharfbuzz-dev"
|
2022-05-05 06:41:05 -06:00
|
|
|
- name: "Cross-Mac x86_64"
|
2023-09-26 23:37:01 -06:00
|
|
|
host: "x86_64-apple-darwin"
|
2020-12-09 20:08:58 -07:00
|
|
|
packages: "cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev python3-setuptools-git"
|
2022-05-05 06:41:05 -06:00
|
|
|
- name: "Cross-Mac aarch64"
|
2023-09-26 23:37:01 -06:00
|
|
|
host: "aarch64-apple-darwin"
|
2022-05-05 06:41:05 -06:00
|
|
|
packages: "cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev python3-setuptools-git"
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: "x86_64 Freebsd"
|
|
|
|
host: "x86_64-unknown-freebsd"
|
|
|
|
packages: "clang-8 gperf cmake python3-zmq libdbus-1-dev libharfbuzz-dev"
|
2022-07-05 13:32:21 -06:00
|
|
|
- name: "ARMv8 Android"
|
|
|
|
host: "aarch64-linux-android"
|
|
|
|
packages: "gperf cmake python3"
|
2020-12-09 20:08:58 -07:00
|
|
|
name: ${{ matrix.toolchain.name }}
|
|
|
|
steps:
|
2024-02-18 16:01:22 -07:00
|
|
|
- uses: actions/checkout@v4
|
2020-12-09 20:08:58 -07:00
|
|
|
with:
|
2023-02-19 10:33:18 -07:00
|
|
|
fetch-depth: 0
|
2020-12-09 20:08:58 -07:00
|
|
|
submodules: recursive
|
2021-07-10 06:56:41 -06:00
|
|
|
# Most volatile cache
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: ccache
|
2024-02-18 16:01:22 -07:00
|
|
|
uses: actions/cache@v4
|
2020-12-09 20:08:58 -07:00
|
|
|
with:
|
2021-07-10 06:56:41 -06:00
|
|
|
path: ~/.ccache
|
2020-12-09 20:08:58 -07:00
|
|
|
key: ccache-${{ matrix.toolchain.host }}-${{ github.sha }}
|
|
|
|
restore-keys: ccache-${{ matrix.toolchain.host }}-
|
2021-07-10 06:56:41 -06:00
|
|
|
# Less volatile cache
|
|
|
|
- name: depends cache
|
2024-02-18 16:01:22 -07:00
|
|
|
uses: actions/cache@v4
|
2021-07-10 06:56:41 -06:00
|
|
|
with:
|
|
|
|
path: contrib/depends/built
|
|
|
|
key: depends-${{ matrix.toolchain.host }}-${{ hashFiles('contrib/depends/packages/*') }}
|
|
|
|
restore-keys: |
|
|
|
|
depends-${{ matrix.toolchain.host }}-${{ hashFiles('contrib/depends/packages/*') }}
|
|
|
|
depends-${{ matrix.toolchain.host }}-
|
|
|
|
# Static cache
|
|
|
|
- name: OSX SDK cache
|
2024-02-18 16:01:22 -07:00
|
|
|
uses: actions/cache@v4
|
2021-07-10 06:56:41 -06:00
|
|
|
with:
|
|
|
|
path: contrib/depends/sdk-sources
|
|
|
|
key: sdk-${{ matrix.toolchain.host }}-${{ matrix.toolchain.osx_sdk }}
|
|
|
|
restore-keys: sdk-${{ matrix.toolchain.host }}-${{ matrix.toolchain.osx_sdk }}
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: set apt conf
|
2021-09-09 04:57:24 -06:00
|
|
|
run: ${{env.APT_SET_CONF}}
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: install dependencies
|
2020-12-20 00:27:10 -07:00
|
|
|
run: sudo apt update; sudo apt -y install build-essential libtool cmake autotools-dev automake pkg-config bsdmainutils curl git ca-certificates ccache ${{ matrix.toolchain.packages }}
|
2020-12-09 20:08:58 -07:00
|
|
|
- name: prepare w64-mingw32
|
|
|
|
if: ${{ matrix.toolchain.host == 'x86_64-w64-mingw32' || matrix.toolchain.host == 'i686-w64-mingw32' }}
|
|
|
|
run: |
|
|
|
|
sudo update-alternatives --set ${{ matrix.toolchain.host }}-g++ $(which ${{ matrix.toolchain.host }}-g++-posix)
|
|
|
|
sudo update-alternatives --set ${{ matrix.toolchain.host }}-gcc $(which ${{ matrix.toolchain.host }}-gcc-posix)
|
|
|
|
- name: build
|
|
|
|
run: |
|
2021-09-09 04:57:24 -06:00
|
|
|
${{env.CCACHE_SETTINGS}}
|
2020-12-09 20:08:58 -07:00
|
|
|
make depends target=${{ matrix.toolchain.host }} -j2
|
2024-02-18 16:01:22 -07:00
|
|
|
- uses: actions/upload-artifact@v4
|
2023-11-06 12:39:40 -07:00
|
|
|
if: ${{ matrix.toolchain.host == 'x86_64-w64-mingw32' || matrix.toolchain.host == 'x86_64-apple-darwin' || matrix.toolchain.host == 'x86_64-unknown-linux-gnu' }}
|
2020-12-09 20:08:58 -07:00
|
|
|
with:
|
|
|
|
name: ${{ matrix.toolchain.name }}
|
|
|
|
path: |
|
2024-06-02 19:27:35 -06:00
|
|
|
/home/runner/work/${{ github.event.repository.name }}/${{ github.event.repository.name }}/build/${{ matrix.toolchain.host }}/release/bin/monero-wallet-cli*
|
|
|
|
/home/runner/work/${{ github.event.repository.name }}/${{ github.event.repository.name }}/build/${{ matrix.toolchain.host }}/release/bin/monerod*
|