arch-pkgs/nginx-mainline-mod-brotli/PKGBUILD

36 lines
1 KiB
Text
Raw Normal View History

# Maintainer: George Rawlinson <george@rawlinson.net.nz>
# Contributor: Massimiliano Torromeo <massimiliano.torromeo@gmail.com>
2023-06-26 21:28:39 +00:00
_ngx_ver=1.25.1
pkgname=nginx-mainline-mod-brotli
pkgver=1.0.0rc
2023-06-26 21:28:39 +00:00
pkgrel=20
pkgdesc='Brotli compression filter module'
arch=('x86_64')
url='https://github.com/google/ngx_brotli'
_modname="${url##*/}"
license=('BSD')
2023-06-26 21:28:39 +00:00
depends=("nginx-mainline=$_ngx_ver" 'brotli')
makedepends=('nginx-mainline-src')
source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz")
b2sums=('450d0ea693bd98d4a1b615f2cdcaad41ccd28266f6d80beec7fe77fe750ab8c5d1bb55aabe15161b9b6d819d2b4d99a7774f2706f2f6fd084b52a7c7dddbc00c')
prepare() {
mkdir -p build
ln -sf -t build /usr/src/nginx/{auto,src}
}
build() {
cd build
/usr/src/nginx/configure --with-compat --add-dynamic-module="$srcdir/$_modname-$pkgver"
make modules
}
package() {
# modules
install -vDm755 -t "$pkgdir/usr/lib/nginx/modules" build/objs/*.so
# license
install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" "$_modname-$pkgver/LICENSE"
}