45 lines
1.1 KiB
YAML
45 lines
1.1 KiB
YAML
name: Build XMRig
|
|
|
|
on:
|
|
push:
|
|
workflow_dispatch:
|
|
schedule:
|
|
- cron: 0 15 * * 3
|
|
|
|
jobs:
|
|
linux-amd64:
|
|
runs-on: ubuntu-latest
|
|
container: alpine:3.20
|
|
steps:
|
|
- name: Install dependencies
|
|
run: |
|
|
#apk add git make cmake libstdc++ gcc g++ automake libtool autoconf linux-headers
|
|
apk add git make cmake libstdc++ gcc g++ libuv-dev openssl-dev hwloc-dev upx nodejs
|
|
|
|
- name: Fetch sources
|
|
run: |
|
|
git clone https://github.com/xmrig/xmrig.git
|
|
|
|
# - name: Build static libraries
|
|
# run: |
|
|
# cd xmrig/scripts && ./build_deps.sh
|
|
|
|
- name: Build binary
|
|
run: |
|
|
mkdir -p xmrig/build && cd xmrig/build
|
|
#cmake .. -DXMRIG_DEPS=scripts/deps -DBUILD_STATIC=ON
|
|
cmake ..
|
|
make -j$(nproc)
|
|
|
|
- name: Compress executables
|
|
run: |
|
|
cd xmrig/build
|
|
strip xmrig
|
|
upx xmrig
|
|
|
|
- name: Upload artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: xmrig-linux-amd64
|
|
path: xmrig/build/xmrig
|