The latest Nginx seems to have moved on to libpcre2 but the Ebuild still has libpcre as the only dependency. This will break if you install Nginx using ROOT= environment variable during install. Nginx will return this error when started: /usr/sbin/nginx: error while loading shared libraries: libpcre2-8.so.0: cannot open shared object file: No such file or directory Nginx 1.20.1-r3 doesn't have this issue as it seems to be using libpcre still and which will correctly be installed as a dependency. Not sure if a build.log will do much here. Nginx builds fine. It's just that it doesn't install correct dependencies when using ROOT= variable during install. Reproducible: Always Steps to Reproduce: 1. ROOT=/mnt/chroot emerge nginx 2. see error about missing libpcre2-8.so.0 3.
Also linking fails... (if f.e. naxsi is disabled). ..........objs/ngx_modules.o \ -L/usr/lib64 -L/usr/lib64 -Wl,-E -lcrypt -L/usr/lib64 -lluajit-5.1 -lm -ldl -lpam -lyajl -lldap -llber -lmaxminddb -lmaxminddb /var/tmp/portage/www-servers/nginx-1.21.6-r1/work/njs-0.7.2/nginx/../build/libnjs.a -lm /var/tmp/portage/www-servers/nginx-1.21.6-r1/work/njs-0.7.2/nginx/../build/libnjs.a -lm -lbrotlienc -lm -lpcre2-8 -lssl -lcrypto -lz -lxml2 -lxslt -lexslt -lgd -lGeoIP \ -Wl,-E -Wl,-O1 -Wl,--as-needed -L/usr/lib64/perl5/5.34/x86_64-linux-thread-multi/CORE -lperl -ldl -lm -lcrypt -lutil -lpthread -lc \ -Wl,-E /usr/lib/gcc/x86_64-pc-linux-gnu/11.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: objs/addon/src/ngx_http_lua_regex.o: undefined reference to symbol 'pcre_exec' /usr/lib/gcc/x86_64-pc-linux-gnu/11.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: /lib64/libpcre.so.1: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status make[1]: *** [objs/Makefile:521: objs/nginx] Error 1 make[1]: Leaving directory '/var/tmp/portage/www-servers/nginx-1.21.6-r1/work/nginx-1.21.6'
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fef9c212cc857654acea385e37a492e818e3d417 commit fef9c212cc857654acea385e37a492e818e3d417 Author: Tomáš Mózes <hydrapolic@gmail.com> AuthorDate: 2022-07-11 13:37:11 +0000 Commit: Conrad Kostecki <conikost@gentoo.org> CommitDate: 2022-07-13 19:01:59 +0000 www-servers/nginx: bump to 1.23.0 Bug: https://bugs.gentoo.org/838247 Closes: https://bugs.gentoo.org/852953 Signed-off-by: Tomáš Mózes <hydrapolic@gmail.com> Closes: https://github.com/gentoo/gentoo/pull/26347 Signed-off-by: Conrad Kostecki <conikost@gentoo.org> www-servers/nginx/Manifest | 6 + .../files/http_headers_more-nginx-1.23.0.patch | 187 ++++ .../nginx/files/http_sticky-nginx-1.23.0.patch | 25 + .../files/http_uploadprogress-nginx-1.23.0.patch | 74 ++ www-servers/nginx/nginx-1.23.0.ebuild | 1028 ++++++++++++++++++++ 5 files changed, 1320 insertions(+)