#!/bin/mkpkg # description: High performance wlroots screen recording with hardware encoding # url: https://github.com/russelltg/wl-screenrec name=wl-screenrec version=0.3.1 release=2 depends=(ffmpeg libdrm libva) makedeps=(rust vulkan-headers pkgconf cargo-audit) source=(https://github.com/russelltg/wl-screenrec/archive/refs/tags/v$version.tar.gz) renames=($name-$version.tar.gz) sha256sums=( "b55564cea4af0e20a5d9a350381fe8d26bf6b2addabbc81d15cafeaa5a5ad1e6" ) patch() { export CARGO_HOME="$SRC/.cargo" cd $name-$version cargo vendor ../vendor mkdir -p .cargo printf '%s\n' \ '[source.crates-io]' \ 'replace-with = "vendored-sources"' \ '' \ '[source."git+https://github.com/russelltg/rust-ffmpeg-sys?branch=vulkan"]' \ 'git = "https://github.com/russelltg/rust-ffmpeg-sys"' \ 'branch = "vulkan"' \ 'replace-with = "vendored-sources"' \ '' \ '[source.vendored-sources]' \ 'directory = "../vendor"' \ > .cargo/config.toml #cargo audit } build() { export CARGO_HTTP_CAINFO=/etc/ssl/cert.pem export CARGO_PROFILE_RELEASE_LTO=off export RUSTFLAGS="-C linker=clang -C link-arg=-fuse-ld=lld -C target-feature=-crt-static" cd $name-$version cargo build --release --offline install -Dm755 target/release/$name $PKG/usr/bin/$name } signify() { untrusted comment: public key RWTZ9IduCSQ/mL8337TEUinPwT92xFEUpD92hkS7IxcOnzTt9QdpohT3 } # vim: filetype=sh