Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 933726 - sys-process/audit-3.1.1[python_targets_python3_12]: missing dev-python/setuptools dependency : "ModuleNotFoundError: No module named 'distutils'" leading build failure later in the build
Summary: sys-process/audit-3.1.1[python_targets_python3_12]: missing dev-python/setupt...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal
Assignee: SE Linux Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-06-07 12:53 UTC by Will Lepofsky
Modified: 2024-06-07 15:50 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Build log (build.log,179.10 KB, text/x-log)
2024-06-07 12:58 UTC, Will Lepofsky
Details
Build log - 3.1.3 (build.log-3.1.2,180.46 KB, application/x-troff-man)
2024-06-07 13:04 UTC, Will Lepofsky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Will Lepofsky 2024-06-07 12:53:50 UTC
During the upgrade to Python 3.12, sys-process/audit returns the following:

libtool:   error: only absolute run-paths are allowed

Same things happens with sys-process/audit-3.1.2.

Reproducible: Always

Steps to Reproduce:
1.emerge -NuDav --changed-deps @world
Actual Results:  
/bin/sh /var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1-abi_x86_64.amd64/libtool  --tag=CC   --mode=link x86_64-pc-linux-gnu-gcc -shared -march=native -O2 -pipe -module -avoid-version -Wl,-z,relro -Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs -o _audit.la -rpath  _audit_la-audit_wrap.lo /var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1-abi_x86_64.amd64/lib/libaudit.la /var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1-abi_x86_64.amd64/lib/libaudit.la
libtool:   error: only absolute run-paths are allowed
make[1]: *** [Makefile:479: _audit.la] Error 1
make[1]: Leaving directory '/var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1-abi_x86_64.amd64-python3_12/bindings/swig/python3'
make: *** [Makefile:420: all-recursive] Error 1
make: Leaving directory '/var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1-abi_x86_64.amd64-python3_12/bindings/swig'
 * ERROR: sys-process/audit-3.1.1::gentoo failed (compile phase):
 *   emake failed
 * 
 * If you need support, post the output of `emerge --info '=sys-process/audit-3.1.1::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=sys-process/audit-3.1.1::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/sys-process/audit-3.1.1/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-process/audit-3.1.1/temp/environment'.
 * Working directory: '/var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1-abi_x86_64.amd64'
 * S: '/var/tmp/portage/sys-process/audit-3.1.1/work/audit-3.1.1'

 * GNU info directory index is up-to-date.
 * After world updates, it is important to remove obsolete packages with
 * emerge --depclean. Refer to `man emerge` for more information.

Expected Results:  
sys-process/audit-3.1.1 should compile cleanly.

Portage 3.0.63 (python 3.11.9-final-0, default/linux/amd64/23.0/split-usr/no-multilib/hardened/selinux, gcc-13, glibc-2.39-r6, 6.6.30-gentoo-x86_64 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-6.6.30-gentoo-x86_64-x86_64-AMD_Ryzen_Embedded_V1605B_with_Radeon_Vega_Gfx-with-glibc2.39
KiB Mem:    32305120 total,  29149524 free
KiB Swap:   67108860 total,  67108860 free
Timestamp of repository gentoo: Fri, 07 Jun 2024 11:45:00 +0000
Head commit of repository gentoo: 18c1fe12eadbed29dcf84ea868bf73a0c3f58173
sh bash 5.1_p16-r6
ld GNU ld (Gentoo 2.42 p3) 2.42.0
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-build/autoconf:        2.71-r7::gentoo
dev-build/automake:        1.16.5-r2::gentoo
dev-build/cmake:           3.28.5::gentoo
dev-build/libtool:         2.4.7-r4::gentoo
dev-build/make:            4.4.1-r1::gentoo
dev-build/meson:           1.4.0-r1::gentoo
dev-lang/perl:             5.38.2-r3::gentoo
dev-lang/python:           3.11.9::gentoo, 3.12.3::gentoo
sec-policy/selinux-base:   2.20240226-r1::gentoo
sys-apps/baselayout:       2.15::gentoo
sys-apps/openrc:           0.54::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-devel/binutils:        2.42-r1::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           17.0.6::gentoo
sys-devel/gcc:             13.2.1_p20240210::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/llvm:            17.0.6::gentoo
sys-kernel/linux-headers:  6.6-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.39-r6::gentoo
sys-libs/libselinux:       3.6-r1::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://192.168.1.200/gentoo-portage/
    priority: -1000
    volatile: False
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-jobs: 1
    sync-rsync-extra-opts: --quiet
    sync-rsync-verify-max-age: 24

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/var/cache/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps=y --quiet-build=y"
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="-march=native -O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync merge-wait multilib-strict network-sandbox news parallel-fetch pkgdir-index-trusted preserve-libs protect-owned qa-unresolved-soname-deps sandbox selinux sesandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-march=native -O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs"
LEX="flex"
LINGUAS="en_US en"
MAKEOPTS="-j8"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_EXTRA_OPTS="--quiet"
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 amd64 audit bzip2 caps cet crypt device-mapper dnscrypt gdbm hardened iconv icu ipv6 libtirpc lto lvm mktemp ncurses nftables nls openmp pam pcre pgo pic pie readline seccomp selinux split-usr ssl ssp test-rust threads unicode verify-sig xattr xfs xtpax zlib" ABI_X86="64" ADA_TARGET="gcc_12" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_anon authn_dbm authn_file authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt rdrand sha sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 ntrip navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="libinput" KERNEL="linux" L10N="en-US en" LCD_DEVICES="bayrad cfontz glk hd44780 lb216 lcdm001 mtxorb text" LLVM_TARGETS="AMDGPU BPF WebAssembly X86" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-2" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_12" PYTHON_TARGETS="python3_12" RUBY_TARGETS="ruby31 ruby32" VIDEO_CARDS="amdgpu radeonsi" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto 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, PYTHONPATH, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS

=================================================================
                        Package Settings
=================================================================

sys-process/audit-3.1.1::gentoo was built with the following:
USE="(python) (split-usr) -gssapi -io-uring -ldap -static-libs -test" PYTHON_TARGETS="python3_11 -python3_10"
FEATURES="merge-sync protect-owned unknown-features-warn selinux sfperms multilib-strict usersync news usersandbox preserve-libs pkgdir-index-trusted ipc-sandbox ebuild-locks parallel-fetch merge-wait userpriv xattr binpkg-dostrip distlocks unmerge-orphans userfetch qa-unresolved-soname-deps binpkg-docompress sandbox network-sandbox unmerge-logs assume-digests fixlafiles binpkg-logs sesandbox strict buildpkg-live"
Comment 1 Will Lepofsky 2024-06-07 12:58:25 UTC
Created attachment 895306 [details]
Build log
Comment 2 Will Lepofsky 2024-06-07 13:04:55 UTC
Created attachment 895307 [details]
Build log - 3.1.3
Comment 3 Alfred Wingate 2024-06-07 13:11:35 UTC
So another distutils dropped from python3.12 bug, this time it failed silently leading to the rpath error from libtool.

To get around this before an ebuild fix install dev-python/setuptools with python3.12 target enabled.

checking for python3... /var/tmp/portage/sys-process/audit-3.1.1/temp/python3.12/bin/python3
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'distutils'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'distutils'
Comment 4 Alfred Wingate 2024-06-07 13:14:00 UTC
Distutils requirement removed in >4.0.
https://github.com/linux-audit/audit-userspace/commit/0c4d12762569df0991ce8ea17ec52ff35f3be463
Comment 5 Larry the Git Cow gentoo-dev 2024-06-07 13:27:24 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5139c6dacff4d358f9313de8a43d9fe8fc027bb8

commit 5139c6dacff4d358f9313de8a43d9fe8fc027bb8
Author:     Kenton Groombridge <concord@gentoo.org>
AuthorDate: 2024-06-07 13:21:02 +0000
Commit:     Kenton Groombridge <concord@gentoo.org>
CommitDate: 2024-06-07 13:27:03 +0000

    sys-process/audit: add missing BDEPEND for setuptools
    
    With python3.12, distutils isn't included with the interpreter but is
    instead bundled in setuptools. Add a conditional dependency for it when
    python3.12 is enabled.
    
    Closes: https://bugs.gentoo.org/933726
    Signed-off-by: Kenton Groombridge <concord@gentoo.org>

 sys-process/audit/audit-3.1.1.ebuild | 8 +++++++-
 sys-process/audit/audit-3.1.2.ebuild | 8 +++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)
Comment 6 Will Lepofsky 2024-06-07 15:50:35 UTC
Thank you for the quick response and fix.