extra/nginx to 1.16.1-2

This commit is contained in:
Kevin Mihelich 2020-01-06 13:33:07 +00:00
parent ee2e1ece4a
commit 31a2ce9d4f

View file

@ -7,9 +7,10 @@
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - build armv7h and aarch64 with -fPIC
pkgname=nginx
pkgbase=nginx
pkgname=(nginx nginx-src)
pkgver=1.16.1
pkgrel=1
pkgrel=2
pkgdesc='Lightweight HTTP server and IMAP/POP3 proxy server'
arch=(x86_64)
url='https://nginx.org'
@ -73,8 +74,12 @@ _common_flags=(
_stable_flags=(
)
prepare() {
cp -r $pkgbase-$pkgver{,-src}
}
build() {
cd $pkgname-$pkgver
cd $pkgbase-$pkgver
[[ $CARCH == "armv7h" || $CARCH == "aarch64" ]] && CFLAGS+=" -fPIC" && CXXFLAGS+=" -fPIC"
@ -103,11 +108,11 @@ build() {
check() {
cd nginx-tests
TEST_NGINX_BINARY="$srcdir/$pkgname-$pkgver/objs/nginx" prove .
TEST_NGINX_BINARY="$srcdir/$pkgbase-$pkgver/objs/nginx" prove .
}
package() {
cd $pkgname-$pkgver
package_nginx() {
cd $pkgbase-$pkgver
make DESTDIR="$pkgdir" install
sed -e 's|\<user\s\+\w\+;|user html;|g' \
@ -141,3 +146,9 @@ package() {
"$pkgdir/usr/share/vim/vimfiles/$i/nginx.vim"
done
}
package_nginx-src() {
depends=()
install -d "$pkgdir/usr/src"
cp -r $pkgbase-$pkgver-src "$pkgdir/usr/src/nginx"
}