st/.woodpecker.yml

46 lines
1.1 KiB
YAML

matrix:
# PLATFORM:
# - linux/amd64
# - linux/arm64
ARCH:
# tuur
- tigerlake
# cenny
- skylake
branches: master
platform: linux/amd64
when:
event: push
pipeline:
build:
image: 'menci/archlinuxarm:base-devel'
commands:
# Add my bur repo to pacman for the libxft-bgra dependency
- echo -e '[bur]\nServer = https://arch.r8r.be/$repo/$arch\nSigLevel = Optional' >> /etc/pacman.conf
# Update packages
- pacman -Syu --noconfirm
# Create non-root user to perform build & switch to their home
- groupadd -g 1000 builder
- useradd -mg builder builder
- chown -R builder:builder "$PWD"
- "echo 'builder ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers"
- su builder
# Build the package
- >
MAKEFLAGS="-j$(nproc)"
makepkg -s --noconfirm --needed
CFLAGS+=" -O3 -flto -march=${ARCH} -mtune=${ARCH}"
CARCH="x86_64_${ARCH}"
publish:
image: 'curlimages/curl'
commands:
# Publish the package
- 'curl -s -XPOST -H "X-API-KEY: $API_KEY" -T "$(ls *.pkg*)" https://arch2.r8r.be/jjr'
secrets:
- api_key