Package Details: nginx-mainline-mod-fancyindex 0.5.2-3

Git Clone URL: https://aur.archlinux.org/nginx-mainline-mod-fancyindex.git (read-only, click to copy)
Package Base: nginx-mainline-mod-fancyindex
Description: Fancy index module for the nginx-mainline web server
Upstream URL: https://www.nginx.com/resources/wiki/modules/fancy_index/
Keywords: module nginx
Licenses: BSD
Submitter: hdhoang
Maintainer: morgenstern
Last Packager: morgenstern
Votes: 11
Popularity: 0.038516
First Submitted: 2017-05-23 02:20 (UTC)
Last Updated: 2022-06-07 11:41 (UTC)

Pinned Comments

Latest Comments

morgenstern commented on 2022-06-07 11:42 (UTC)

@TheHardew the PKGBUILD has been updated to reflect the architectures for which nginx-mainline-src is available per Arch Linux ARM.

TheHardew commented on 2022-06-07 11:21 (UTC)

Any reason arm is not marked as supported? Seems to work fine on raspberry pi 4.

morgenstern commented on 2022-01-13 22:07 (UTC) (edited on 2022-01-13 22:07 (UTC) by morgenstern)

Thanks for the diff @kescherAUR - the PKGBUILD has been updated to reflect your proposed changes. The nginx configure flags were included in the build() function by a past maintainer; I did not realise their presence would cause issues when building with custom nginx packages.

kescherAUR commented on 2022-01-13 11:17 (UTC)

Please adjust build() to not use the NGINX configure flags, as not only is that entirely unneccessary, it breaks when building this for custom nginx packages that provide nginx-mainline (for instance, nginx-quic).

The following git diff works just fine:

diff --git a/PKGBUILD b/PKGBUILD
index 2b02854..8ff0965 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -24,10 +24,7 @@ prepare() {

 build() {
   cd "${srcdir}/nginx"
-  _opts=$(nginx -V 2>&1 | grep 'configure arguments' | sed -r 's/^[^:]+: //')
-  IFS=$'\n' _opts=( $(xargs -n1 <<< "$_opts") )
-  /usr/src/nginx/configure "${_opts[@]}" \
-       --add-dynamic-module=../ngx-"$_modname-$pkgver"
+  /usr/src/nginx/configure --with-compat --add-dynamic-module=../ngx-"$_modname-$pkgver"
   make modules
 }

morgenstern commented on 2021-05-08 05:41 (UTC)

@BotoX + @RiCON - thanks for the suggestions. I agree that using nginx-mainline-src is a better option, and I have updated the PKGBUILD accordingly.

BotoX commented on 2021-05-07 13:42 (UTC) (edited on 2021-05-07 13:43 (UTC) by BotoX)

improved the PKGBUILD to use nginx-mainline-src

# Maintainer: Morgenstern <charles [at] charlesbwise [dot] com>
# Contributor: jkl <jkl@johnluebs.com>
# Contributor: hdhoang <arch@hdhoang.space>

pkgname=nginx-mainline-mod-fancyindex
pkgver=0.5.1
pkgrel=7
_modname="${pkgname#nginx-mainline-mod-}"
pkgdesc="Fancy indexes module for the nginx web server"
arch=('x86_64')
url="https://github.com/aperezdc/ngx-fancyindex"
license=('BSD')
depends=("nginx-mainline")
makedepends=('nginx-mainline-src')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/aperezdc/ngx-$_modname/archive/v$pkgver.tar.gz")
validpgpkeys=('B0F4253373F8F6F510D42178520A9993A1C052F8') # Maxim Dounin <mdounin@mdounin.ru>
sha256sums=('238bd5521d6c9b55780e6871339a7ea79508b9a6758ad2fa4451f2dfe26d94c9')

prepare() {
  cp -r /usr/src/nginx .
}

build() {
  cd "$srcdir"/nginx
  _opts=$(nginx -V 2>&1 | grep 'configure arguments' | sed -r 's/^[^:]+: //')
  IFS=$'\n' _opts=( $(xargs -n1 <<< "$_opts") )
  ./configure "${_opts[@]}" \
    --add-dynamic-module=../ngx-"$_modname-$pkgver"
  make modules
}

package() {
  cd "$srcdir"/nginx/objs
  for _mod in *.so; do
    install -D $_mod "$pkgdir/usr/lib/nginx/modules/$_mod"
  done
  install -Dm0644 "$srcdir/ngx-$_modname-$pkgver/LICENSE" \
    "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

edit: oops someone else has already posted theirs

morgenstern commented on 2021-03-11 20:44 (UTC)

@RiCON interesting, I did not realise that nginx-mainline-src could be used for compilation. I will consider it.

RiCON commented on 2021-03-10 23:14 (UTC)

Hey, I've modified this to use nginx-mainline-src instead of using a hardcoded nginx version: https://gist.github.com/wiiaboo/d56f54cec3b09ee6eb4486586730ad6c

It'll require less maintenance work from you, as users just know that for every new nginx-mainline version they need to recompile their nginx-mainline-mod-* AUR packages.

morgenstern commented on 2021-03-09 19:55 (UTC) (edited on 2021-03-09 19:58 (UTC) by morgenstern)

Updated.

@duffydack this package will only be updated once nginx-mainline has been updated. Therefore, I recommend you set IgnorePkg in pacman.conf to omit any nginx packages until you can confirm that modules such as this are up-to-date.

duffydack commented on 2021-03-09 18:52 (UTC) (edited on 2021-03-09 18:53 (UTC) by duffydack)

@akiirui; Yeah, I've already amended the pkgbuild to reflect the nginx-mainline updated version, to verify it builds and functions as before. Just thought I'd give a heads-up on the situation.

akiirui commented on 2021-03-09 18:41 (UTC)

@duffydack You can edit the PKGBUILD manually, L7 to pkgrel=4 L9 to _nginxver=1.19.8 And makepkg --geninteg copy output, overwrite the L18~L20.

At last, makepkg and pacman -U PACKAGE

duffydack commented on 2021-03-09 18:23 (UTC)

Can you bump the nginx version to 1.19.8 as the module needs rebuilding against it. => /usr/lib/nginx/modules/ngx_http_fancyindex_module.so" version 1019007 instead of 1019008`

Thanks

sampsoncrowley commented on 2020-08-24 23:57 (UTC)

Repo with updated PKGBUILD for nginx 1.19.2 => https://github.com/SampsonCrowley/arch_packages/tree/master/nginx-mainline-mod-brotli

https://raw.githubusercontent.com/SampsonCrowley/arch_packages/4a10fb1435be85d2cbb9387734c4f4aa7beaab2f/nginx-mainline-mod-brotli/PKGBUILD

sampsoncrowley commented on 2020-08-24 23:55 (UTC)

if you get an nginx-1.19.2.tar.gz ... FAILED (unknown public key 520A9993A1C052F8) ==> ERROR: One or more PGP signatures could not be verified! error, use the following line to pull in the right keys (also mentioned below, but below solution doesn't contain a keyserver to use like this does)

gpg --keyserver pool.sks-keyservers.net --recv-keys 520A9993A1C052F8

SibrenVasse commented on 2019-01-30 22:33 (UTC)

Please fix the .SRCINFO

wangqr commented on 2018-03-31 12:27 (UTC)

Currently `pkgrel' in .SRCINFO and PKGBUILD don't match. AUR helpers (eg. yaourt) now always think that there is a new version, because the pkgrel in AUR(4) is greater than installed(3).

hdhoang commented on 2018-03-28 09:59 (UTC)

This is awkward: the PKGBUILD determines nginx version at build time, and downloads the corresponding source. In the -4 release bump, I deleted that version line from .SRCINFO so that nginx doesn't show up in Sources list above.

When a new nginx-mainline release enters [community], I will bump the release number again to trigger rebuild for you. [community-testing] users would need to rebuild on their own.

hdhoang commented on 2017-10-21 02:18 (UTC)

Thank you for your concern. I have switched to verifying the nginx source by PGP signature instead of checksum, because testing users may have different nginx version than I do. Please verify that that fingerprint is the proper nginx signing key's (e.g. by looking for it in the PKGBUILD), then import it into your builder's gpg keyring https://git.archlinux.org/svntogit/community.git/tree/trunk/PKGBUILD?h=packages/nginx-mainline gpg --recv-keys 520A9993A1C052F8

levinit commented on 2017-10-21 02:02 (UTC)

Verifying source file signatures with gpg... nginx-1.13.5.tar.gz ... FAILED (unknown public key 520A9993A1C052F8) ==> ERROR: One or more PGP signatures could not be verified! ==> ERROR: Makepkg was unable to build nginx-mainline-mod-fancyindex. ==> Restart building nginx-mainline-mod-fancyindex ? [y/N]

hdhoang commented on 2017-07-20 02:49 (UTC)

I think -6 has fixed that. I'll also notify other module packagers

hdhoang commented on 2017-07-20 00:32 (UTC) (edited on 2017-07-20 00:33 (UTC) by hdhoang)

that option comes from nginx -V as part of this --with-cc-opt='-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt -D_FORTIFY_SOURCE=2' maybe the single quote got unwrapped somehow. I'll look into it.

dotted commented on 2017-07-19 16:03 (UTC)

aura >>= Building `nginx-mainline-mod-fancyindex`... ^[[3~==> Making package: nginx-mainline-mod-fancyindex 0.4.1-5 (Wed Jul 19 18:02:15 CEST 2017) ==> Checking runtime dependencies... ==> Checking buildtime dependencies... ==> Retrieving sources... -> Downloading nginx-1.13.3.tar.gz... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 962k 100 962k 0 0 452k 0 0:00:02 0:00:02 --:--:-- 453k -> Downloading v0.4.1.tar.gz... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 131 0 131 0 0 299 0 --:--:-- --:--:-- --:--:-- 299 100 21130 0 21130 0 0 21768 0 --:--:-- --:--:-- --:--:-- 21768 ==> Validating source files with sha256sums... nginx-1.13.3.tar.gz ... Passed v0.4.1.tar.gz ... Passed ==> Extracting sources... -> Extracting nginx-1.13.3.tar.gz with bsdtar -> Extracting v0.4.1.tar.gz with bsdtar ==> Starting prepare()... ==> Starting build()... ./configure: error: invalid option "-mtune=generic" ==> ERROR: A failure occurred in build(). Aborting... aura >>= Well, building `nginx-mainline-mod-fancyindex` failed.

x-f commented on 2017-06-07 22:51 (UTC)

THX, i added both (i commented fancyindex out, because it wasn't available by default). After installation i still had autoindex on. THX for the PKGBUILD

hdhoang commented on 2017-06-07 09:19 (UTC)

Have you replaced the "autoindex on;" directive with "fancyindex on;"?

x-f commented on 2017-06-07 07:56 (UTC)

How to enable the fancyindex? nginx -t had a syntax error, i installed the module and loaded the module with load_module /usr/lib/nginx/modules/ngx_http_fancyindex_module.so; in nginx.conf - outside of server and http. fancyindexx options has no errors, but the output isn't fancyindex.