Ebuild is misconfigured and won't install language modules. Logs: ``` 2023/05/26 12:12:55 [notice] 19904#19904 process 19906 exited with code 0 2023/05/26 12:12:55 [info] 28472#28472 discovery started 2023/05/26 12:12:55 [notice] 28472#28472 no modules matching: "/usr/lib64/nginx-unit/*.unit.so" found 2023/05/26 12:12:55 [info] 28471#28471 controller started 2023/05/26 12:12:55 [notice] 28471#28471 process 28472 exited with code 0 2023/05/26 12:12:55 [alert] 28473#28473 the previous configuration is invalid: The module to run "perl" is not found among the available application modules. 2023/05/26 12:12:55 [info] 28474#28474 router started 2023/05/26 12:12:55 [info] 28474#28474 OpenSSL 1.1.1t 7 Feb 2023, 1010114f ``` Then we look at what is compiled there ``` $ unitd -h unit options: --control ADDRESS set address of control API socket default: "unix:/run/nginx-unit.sock" --pid FILE set pid filename default: "/run/nginx-unit.pid" --log FILE set log filename default: "/var/log/nginx-unit" --modulesdir DIR set modules directory name default: "lib64/nginx-unit" <<<<<<<<<< ! --statedir DIR set state directory name default: "/var/lib/nginx-unit" --tmpdir DIR set tmp directory name default: "/tmp" ``` This is most likely related to this line in the changelog: ``` Changes with Unit 1.30.0 10 May 2023 *) Feature: default values for 'make install' pathnames such as prefix; this allows to './configure && make && sudo make install'. ``` Reproducible: Always Portage 3.0.44 (python 3.10.10-final-0, default/linux/amd64/17.1, gcc-12, glibc-2.36-r7, 5.10.174-gentoo-dist x86_64) ================================================================= System uname: Linux-5.10.174-gentoo-dist-x86_64-Intel-R-_Core-TM-_i3-7350K_CPU_@_4.20GHz-with-glibc2.36 KiB Mem: 16247976 total, 4066208 free KiB Swap: 12287996 total, 8295732 free Timestamp of repository gentoo: Wed, 24 May 2023 06:00:01 +0000 Head commit of repository gentoo: cc974d70be053afdebbdf01808425b099b3f345b sh bash 5.1_p16-r2 ld GNU ld (Gentoo 2.39 p6) 2.39.0 ccache version 4.7.4 [disabled] app-misc/pax-utils: 1.3.5::gentoo app-shells/bash: 5.1_p16-r2::gentoo dev-lang/perl: 5.36.1::gentoo dev-lang/python: 3.9.16_p3::gentoo, 3.10.10_p3::gentoo, 3.11.2_p2::gentoo dev-lang/rust-bin: 1.66.1-r1::gentoo dev-util/ccache: 4.7.4::gentoo dev-util/cmake: 3.25.3::gentoo dev-util/meson: 1.0.1::gentoo sys-apps/baselayout: 2.13-r1::gentoo sys-apps/openrc: 0.46::gentoo sys-apps/sandbox: 2.29::gentoo sys-devel/autoconf: 2.71-r5::gentoo sys-devel/automake: 1.16.5::gentoo sys-devel/binutils: 2.39-r5::gentoo sys-devel/binutils-config: 5.5::gentoo sys-devel/gcc: 12.2.1_p20230304::gentoo sys-devel/gcc-config: 2.10::gentoo sys-devel/libtool: 2.4.7-r1::gentoo sys-devel/llvm: 15.0.7::gentoo sys-devel/make: 4.4.1::gentoo sys-kernel/linux-headers: 6.1::gentoo (virtual/os-headers) sys-libs/glibc: 2.36-r7::gentoo Repositories: gentoo location: /var/portage sync-type: rsync sync-uri: rsync://rsync.gentoo.org/gentoo-portage priority: -1000 volatile: True sync-rsync-verify-metamanifest: yes sync-rsync-extra-opts: sync-rsync-verify-max-age: 24 sync-rsync-verify-jobs: 1 bes location: /var/lib/layman/bes masters: gentoo priority: 50 volatile: True ACCEPT_KEYWORDS="amd64" ACCEPT_LICENSE="*" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -march=sandybridge -pipe -fomit-frame-pointer" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/spool/munin-async/.ssh" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.4/ext-active/ /etc/php/cgi-php7.4/ext-active/ /etc/php/cli-php7.4/ext-active/ /etc/php/fpm-php7.4/ext-active/ /etc/php/phpdbg-php7.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo" CXXFLAGS="-O2 -march=sandybridge -pipe -fomit-frame-pointer" DISTDIR="/var/distfiles" EMERGE_DEFAULT_OPTS=" --quiet-build=n --keep-going --jobs 4 --load-average 8" ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="http://distfiles.gentoo.org" LANG="en_GB.utf8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" LEX="flex" LINGUAS="en" MAKEOPTS="-j2" PKGDIR="/var/cache/binpkgs" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git" PORTAGE_TMPDIR="/var/tmp" SHELL="/bin/bash" USE="acl acpi amd64 avif bash-completion bzip2 bzlib charconv cli crypt curl dist-kernel dnsdb dovecot-sasl dri exiscan-acl fastcgi fftw fontconfig gdbm gnutls gpm hdri heif http2 iconv icu idn ipv6 jpeg libde265 libtirpc lm_sensors lvm lzma maildir multilib mysql ncurses nfsv41 nls nptl openmp pam pcre png readline sasl seccomp spf split-usr sqlite ssl svg symlink syslog test-rust threads truetype unicode urandom utf8 webp winbind x264 x265 xattr xml zip zlib zstd" ABI_X86="64" ADA_TARGET="gnat_2021" APACHE2_MODULES="*" APACHE2_MPMS="worker" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="avx mmx mmxext pclmul popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="emu pc efi-64" INPUT_DEVICES="libinput" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" NGINX_MODULES_HTTP="echo access auth_basic autoindex browser charset empty_gif headers_more fastcgi geo geoip2 gzip gzip_static image_filter limit_req limit_conn map perl proxy realip rewrite referer ssi stub_status userid addition auth_request brotli sub javascript" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11" RUBY_TARGETS="ruby30" VIDEO_CARDS="amdgpu fbdev intel nouveau radeon radeonsi vesa dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account" Unset: ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2a9bac18bdecb1eb0a065bdd747a8467ca9cfcba commit 2a9bac18bdecb1eb0a065bdd747a8467ca9cfcba Author: Mike Pagano <mpagano@gentoo.org> AuthorDate: 2023-05-29 20:16:53 +0000 Commit: Mike Pagano <mpagano@gentoo.org> CommitDate: 2023-05-29 20:16:53 +0000 www-servers/nginx-unit: Support building perl module Closes: https://bugs.gentoo.org/907204 Signed-off-by: Mike Pagano <mpagano@gentoo.org> www-servers/nginx-unit/nginx-unit-1.30.0.ebuild | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
I think this is still an issue. The ebuild's configure command produces this summary output: Unit configuration summary: bin directory: ............. "/usr/bin" sbin directory: ............ "/usr/sbin" lib directory: ............. "/usr/lib" include directory: ......... "/usr/include" pkgconfig directory: ....... "/usr/share/pkgconfig" man pages directory: ....... "/usr/share/man" modules directory: ......... "lib64/nginx-unit" state directory: ........... "/var/lib/nginx-unit" tmp directory: ............. "/tmp" This also causes `make install` phase to install the compiled module files into the wrong 'image' directory. Note the "imagelib64" in this snippet: test -d /var/tmp/portage/www-servers/nginx-unit-1.31.0/image/var/lib/nginx-unit || install -d /var/tmp/portage/www-servers/nginx-unit-1.31.0/image/var/lib/nginx-unit install -d /var/tmp/portage/www-servers/nginx-unit-1.31.0/imagelib64/nginx-unit install -p build/lib/unit/modules/python.unit.so \ /var/tmp/portage/www-servers/nginx-unit-1.31.0/imagelib64/nginx-unit/ If I had to guess, it looks like the ebuild assumes `--modules` will be interpreted as relative to `--prefix`, but that is not the case. This diff solves the bug: --- nginx-unit-1.31.0.ebuild.orig 2023-09-02 19:10:52.802681961 -0500 +++ nginx-unit-1.31.0.ebuild 2023-09-02 19:11:05.642681941 -0500 @@ -51,7 +51,7 @@ local opt=( --control=unix:/run/${PN}.sock --log=/var/log/${PN} - --modules=$(get_libdir)/${PN} + --modules=/usr/$(get_libdir)/${PN} --pid=/run/${PN}.pid --prefix=/usr --state=/var/lib/${PN}
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=15b206cabf3ebaf8ec21d30b376bd8c307dbd495 commit 15b206cabf3ebaf8ec21d30b376bd8c307dbd495 Author: Mike Pagano <mpagano@gentoo.org> AuthorDate: 2023-09-03 20:21:41 +0000 Commit: Mike Pagano <mpagano@gentoo.org> CommitDate: 2023-09-03 20:21:41 +0000 www-servers/nginx-unit: Fix for modules install, thanks to Brandon Holbrook Closes: https://bugs.gentoo.org/907204 Signed-off-by: Mike Pagano <mpagano@gentoo.org> www-servers/nginx-unit/nginx-unit-1.31.0.ebuild | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)