33 lines
871 B
YAML
33 lines
871 B
YAML
platform: 'linux/amd64'
|
|
|
|
when:
|
|
branch:
|
|
exclude: [main]
|
|
event: push
|
|
|
|
steps:
|
|
build:
|
|
image: 'rust:1.79-alpine3.19'
|
|
environment:
|
|
- 'LIBARCHIVE_STATIC=1'
|
|
commands:
|
|
# Dependencies required to statically compile libarchive and libsqlite3
|
|
- >
|
|
apk add --no-cache build-base
|
|
libarchive-static libarchive-dev
|
|
zlib-static
|
|
openssl-libs-static
|
|
bzip2-static
|
|
xz-static
|
|
expat-static
|
|
zstd-static
|
|
lz4-static
|
|
acl-static
|
|
- cargo build --verbose
|
|
# Binaries, even debug ones, should be statically compiled
|
|
- '[ "$(readelf -d target/debug/rieterd | grep NEEDED | wc -l)" = 0 ]'
|
|
# Clippy also performs a full build, so putting it here saves the CI a
|
|
# lot of work
|
|
- rustup component add clippy
|
|
- cargo clippy -- --no-deps -Dwarnings
|