Created attachment 729441 [details] build.log morecore.c: In function ‘__lh_hugetlbfs_setup_morecore’: morecore.c:368:3: error: ‘__morecore’ undeclared (first use in this function); did you mean ‘thp_morecore’? 368 | __morecore = &thp_morecore; | ^~~~~~~~~~ | thp_morecore ---- Portage 3.0.20 (python 3.9.6-final-0, default/linux/amd64/17.1/systemd, gcc-10.3.0, glibc-9999, 5.10.51-gentoo-dist-hardened x86_64) ================================================================= System uname: Linux-5.10.51-gentoo-dist-hardened-x86_64-AMD_Ryzen_7_2700_Eight-Core_Processor-with-glibc2.33.9000 KiB Mem: 16365968 total, 5384500 free KiB Swap: 16777212 total, 14837244 free Timestamp of repository gentoo: Thu, 29 Jul 2021 19:00:01 +0000 Head commit of repository gentoo: d096e08e672b70624fc0ff2b6574f8dccca2d89c sh bash 5.1_p8 ld GNU ld (Gentoo 2.35.2 p1) 2.35.2 app-shells/bash: 5.1_p8::gentoo dev-lang/perl: 5.34.0-r1::gentoo dev-lang/python: 3.9.6::gentoo, 3.10.0_beta4::gentoo dev-lang/rust: 1.53.0::gentoo dev-util/cmake: 3.21.1::gentoo sys-apps/baselayout: 2.7-r3::gentoo sys-apps/sandbox: 2.24::gentoo sys-devel/autoconf: 2.13-r1::gentoo, 2.69-r5::gentoo sys-devel/automake: 1.16.4::gentoo sys-devel/binutils: 2.35.2::gentoo, 2.36.1-r2::gentoo sys-devel/gcc: 10.3.0-r2::gentoo, 11.2.0::gentoo sys-devel/gcc-config: 2.4::gentoo sys-devel/libtool: 2.4.6-r6::gentoo sys-devel/make: 4.3::gentoo sys-kernel/linux-headers: 5.13::gentoo (virtual/os-headers) sys-libs/glibc: 9999::gentoo Repositories: gentoo location: /var/db/repos/gentoo sync-type: rsync sync-uri: rsync://rsync.gentoo.org/gentoo-portage priority: -1000 sync-rsync-verify-max-age: 24 sync-rsync-extra-opts: sync-rsync-verify-jobs: 1 sync-rsync-verify-metamanifest: yes ACCEPT_KEYWORDS="amd64 ~amd64" ACCEPT_LICENSE="@FREE" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-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/sandbox.d /etc/terminfo" CXXFLAGS="-O2 -pipe" DISTDIR="/var/cache/distfiles" ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY 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" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs 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="C.UTF8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" MAKEOPTS="-j8" 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" USE="acl amd64 bzip2 cli crypt dri fortran gdbm iconv ipv6 libglvnd libtirpc multilib ncurses nls nptl openmp pam pcre readline seccomp split-usr ssl systemd tcpd udev unicode xattr zlib" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache 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="mmx mmxext sse sse2" 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" 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" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_9" PYTHON_TARGETS="python3_9" RUBY_TARGETS="ruby26" USERLAND="GNU" 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: CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS
Ping
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9215f11d48a5f54263e700e10d91613b5735e1b9 commit 9215f11d48a5f54263e700e10d91613b5735e1b9 Author: Sam James <sam@gentoo.org> AuthorDate: 2021-10-25 13:24:36 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2021-10-25 13:27:50 +0000 profiles: last-rite sys-libs/libhugetlbfs Bug: https://bugs.gentoo.org/630128 Bug: https://bugs.gentoo.org/715640 Bug: https://bugs.gentoo.org/806079 Signed-off-by: Sam James <sam@gentoo.org> profiles/package.mask | 6 ++++++ 1 file changed, 6 insertions(+)
This is not just a 'lib' for other programs to use as a dependency. It is a tool (hugeadm) for interacting with the huge page control directory in sysfs. It is recommended in the linux kernel documentation (see bottom of https://www.kernel.org/doc/html/latest/admin-guide/mm/hugetlbpage.html) Upstream seems to be aware of the compatibility issue and is working on it: https://github.com/libhugetlbfs/libhugetlbfs/issues/52 Is the failing glibc build enough to rip it out?
In addition to previous comment - it seems like sys-apps/nvme-cli actually depends on libhugetlbfs though the dependency is not declared it seems. I filed a separate bug just now for that: https://bugs.gentoo.org/820320
(In reply to Scott Howard from comment #3) > This is not just a 'lib' for other programs to use as a dependency. It is a > tool (hugeadm) for interacting with the huge page control directory in sysfs. > > It is recommended in the linux kernel documentation (see bottom of > https://www.kernel.org/doc/html/latest/admin-guide/mm/hugetlbpage.html) > > Upstream seems to be aware of the compatibility issue and is working on it: > https://github.com/libhugetlbfs/libhugetlbfs/issues/52 > > Is the failing glibc build enough to rip it out? The problem is that this won't build at all on the latest glibc version and there doesn't seem to be much movement upstream. Apparently we could disable building the library: https://gitweb.gentoo.org/repo/gentoo.git/tree/sys-libs/libhugetlbfs/libhugetlbfs-2.23.ebuild#n53. I'll unmask it for now but we do need a resolution here..
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7ec980bceed718723bbcae039cf041b1dd8bb79e commit 7ec980bceed718723bbcae039cf041b1dd8bb79e Author: Sam James <sam@gentoo.org> AuthorDate: 2021-10-26 07:15:41 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2021-10-26 07:16:03 +0000 profiles: un-last-rite sys-libs/libhugetlbfs for now Needed for tools at least. Bug: https://bugs.gentoo.org/806079 Signed-off-by: Sam James <sam@gentoo.org> profiles/package.mask | 6 ------ 1 file changed, 6 deletions(-)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ed5576e429fac992d5c039e5f2290cc2d5d8d6f4 commit ed5576e429fac992d5c039e5f2290cc2d5d8d6f4 Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2021-11-18 13:59:38 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2021-11-18 13:59:48 +0000 sys-libs/libhugetlbfs: allow building against glibc-2.34 Bug: https://bugs.gentoo.org/806079 Package-Manager: Portage-3.0.28, Repoman-3.0.3 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org> ...fs-2.23-allow-building-against-glibc-2.34.patch | 258 +++++++++++++++++++++ sys-libs/libhugetlbfs/libhugetlbfs-2.23.ebuild | 1 + 2 files changed, 259 insertions(+)
This bug will stay open for a while and will probably cause some users to stay on <glibc-2.34 and will not warrant any last-rite: The __morecore functionality is crucial for any serious server deployment making use of hugetlb. At the moment there is _no_ replacement available, i.e. libhugetlbfs maintainer can't do anything. There is some work going on in glibc to provide a new interface which will probably not be available before glibc-2.35 or 2.36. The applied patch will at least allow user-space tools to build, helping single cluster nodes to keep using functionality.
> > There is some work going on in glibc to provide a new interface which will > probably not be available before glibc-2.35 or 2.36. > The patchset is in glibc master, i.e., it will be in 2.35 (see also linked upstream bug). An upstream backport is possible (but not very likely).
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fad8da8af89b70f55448bde1a8d84e0dfd22db69 commit fad8da8af89b70f55448bde1a8d84e0dfd22db69 Author: Sam James <sam@gentoo.org> AuthorDate: 2022-02-11 14:50:26 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2022-02-11 14:50:46 +0000 profiles/base: stable-mask sys-apps/nvme-cli[hugepages] Doesn't work with soon-to-be-stable glibc-2.34 Bug: https://bugs.gentoo.org/806079 Signed-off-by: Sam James <sam@gentoo.org> profiles/base/package.use.stable.mask | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a43629357609b4fc45137c24dc47dd68d7947e85 commit a43629357609b4fc45137c24dc47dd68d7947e85 Author: Sam James <sam@gentoo.org> AuthorDate: 2023-07-09 02:30:56 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-07-09 02:31:24 +0000 profiles/arch/base: mask nvme-cli[hugepages] Needs <glibc-2.34. Bug: https://bugs.gentoo.org/806079 Bug: https://bugs.gentoo.org/908793 Signed-off-by: Sam James <sam@gentoo.org> profiles/arch/base/package.use.mask | 4 ++++ profiles/base/package.use.stable.mask | 6 ------ 2 files changed, 4 insertions(+), 6 deletions(-)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fed2ebb536459393f2cd907402413b6809257b85 commit fed2ebb536459393f2cd907402413b6809257b85 Author: Michał Górny <mgorny@gentoo.org> AuthorDate: 2024-02-07 21:23:42 +0000 Commit: Michał Górny <mgorny@gentoo.org> CommitDate: 2024-02-07 21:24:04 +0000 package.mask: Last rite sys-libs/libhugetlbfs Bug: https://bugs.gentoo.org/806079 Signed-off-by: Michał Górny <mgorny@gentoo.org> profiles/package.mask | 6 ++++++ 1 file changed, 6 insertions(+)
(In reply to Larry the Git Cow from comment #12) > The bug has been referenced in the following commit(s): > > https://gitweb.gentoo.org/repo/gentoo.git/commit/ > ?id=fed2ebb536459393f2cd907402413b6809257b85 > > commit fed2ebb536459393f2cd907402413b6809257b85 > Author: Michał Górny <mgorny@gentoo.org> > AuthorDate: 2024-02-07 21:23:42 +0000 > Commit: Michał Górny <mgorny@gentoo.org> > CommitDate: 2024-02-07 21:24:04 +0000 > > package.mask: Last rite sys-libs/libhugetlbfs > > Bug: https://bugs.gentoo.org/806079 > Signed-off-by: Michał Górny <mgorny@gentoo.org> > > profiles/package.mask | 6 ++++++ > 1 file changed, 6 insertions(+) This builds for me with sys-libs/glibc-2.38-r10. Was there some other solution for providing the hugeadm tools?
What do you actually need from libhugetlbfs?
hugeadm is needed for managing huge page allocations and policy. Initial configuration can be set on the kernel command line, but runtime configuration is much more flexible, I use it for managing allocations used for VMs. I've never used hugectl, but I'm sure it's useful especially for testing whether there's a benefit to using huge pages, or for cases where the application can't be configured/patched at build-time to enable the use of huge pages.
I'm also wondering, why it is masked. Note, upstream libhugetlbfs has been updated two week ago to 2.24. And it seems it fixes glibc __morecore problem: https://github.com/libhugetlbfs/libhugetlbfs/blob/master/NEWS I'm using hugeadm from this package.
@base-system, are you reviving this or should I remove it?
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cde90da0c3dbcad0d05466f1499b8991913f4850 commit cde90da0c3dbcad0d05466f1499b8991913f4850 Author: Michał Górny <mgorny@gentoo.org> AuthorDate: 2024-04-13 14:31:49 +0000 Commit: Michał Górny <mgorny@gentoo.org> CommitDate: 2024-04-13 14:32:55 +0000 sys-libs/libhugetlbfs: Remove last-rited pkg Bug: https://bugs.gentoo.org/806079 Signed-off-by: Michał Górny <mgorny@gentoo.org> profiles/package.mask | 6 - sys-libs/libhugetlbfs/Manifest | 1 - ...fs-2.23-allow-building-against-glibc-2.34.patch | 258 --------------------- .../files/libhugetlbfs-2.23-musl-ino_t-fix.patch | 13 -- .../files/libhugetlbfs-2.23-musl-nonnull-fix.patch | 31 --- .../libhugetlbfs-2.23-musl-path-max-fix.patch | 22 -- .../libhugetlbfs-2.23-musl-sc-level2-fix.patch | 45 ---- .../libhugetlbfs-2.23-uncompressed-man-pages.patch | 34 --- .../files/libhugetlbfs-2.6-fixup-testsuite.patch | 31 --- sys-libs/libhugetlbfs/libhugetlbfs-2.23.ebuild | 175 -------------- sys-libs/libhugetlbfs/metadata.xml | 12 - 11 files changed, 628 deletions(-)