Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
delete --with-openssl from opts (line #31)
# Maintainer: hdhoang <arch@hdhoang.space>
pkgname=nginx-mainline-mod-fancyindex
pkgver=0.4.2
pkgrel=3
_modname="${pkgname#nginx-mainline-mod-}"
_nginxver="$(/bin/nginx -v 2>&1 | grep -Eo '([[:digit:]]|\.)+')"
pkgdesc='Fancy indexes module for the Nginx web server'
arch=('i686' 'x86_64' 'armv7h')
depends=('nginx-mainline-boringssl')
url="https://github.com/aperezdc/ngx-fancyindex"
license=('BSD')
source=(
https://nginx.org/download/nginx-$_nginxver.tar.gz{,.asc}
https://github.com/aperezdc/ngx-$_modname/archive/v$pkgver.tar.gz
)
sha256sums=('SKIP' 'SKIP'
'8327150864ca267b735d550d3304030efbbd863fdddfe0a94e970f249a8827ee')
validpgpkeys=('B0F4253373F8F6F510D42178520A9993A1C052F8') # Maxim Dounin <mdounin@mdounin.ru>
prepare() {
cd ngx-$_modname-$pkgver
}
build() {
cd "$srcdir"/nginx-$_nginxver
#opts=$(nginx -V 2>&1 | grep 'configure arguments' | sed -r 's@^[^:]+: @@')
opts=$(nginx -V 2>&1 | grep 'configure arguments' | sed -r 's@^[^:]+: @@' | sed 's/--with-openssl.*ssl //')
IFS=$'\n' opts=( $(xargs -n1 <<< "$opts") )
./configure "${opts[@]}" \
--add-dynamic-module=../ngx-$_modname-$pkgver
make modules
}
package() {
install -Dm644 "$srcdir/"ngx-$_modname-$pkgver/LICENSE \
"$pkgdir"/usr/share/licenses/$pkgname/LICENSE
cd "$srcdir"/nginx-$_nginxver/objs
for mod in *.so; do
install -Dm755 $mod "$pkgdir"/usr/lib/nginx/modules/$mod
done
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.