Skip to content

Conversation

@pmenzel
Copy link
Collaborator

@pmenzel pmenzel commented May 1, 2026

Update with

$ sudo bee remove glibc-memusage-fixup-2.36-0.x86_64 && sudo bee install libxcrypt-4.5.2 && sudo bee update glibc-2.43
  • Tested on dose: SSH and sudo work afterward. Restarting dose with sudo mxgrub --reboot also worked.
  • Tested on maleficent (amdgpu): Xfce keeps running and working while doing the glibc update.
  • Test on afk with HTTPD servers

@pmenzel
Copy link
Collaborator Author

pmenzel commented May 1, 2026

Currently breaks PAM, and therefore SSH and sudo.

$ ssh dose
Connection closed by 141.14.17.51 port 22

@dose:~$ sudo bee remove glibc-memusage-fixup-2.36-0.x86_64
sudo: PAM account management error: Module is unknown
sudo: a password is required
$ su
su: Module is unknown

I’ll fix dose in the next days.

@thomas
Copy link
Collaborator

thomas commented May 2, 2026

Maybe this is related to the removal/deprecation of libcrypt.so.1 in glibc 2.38 /1/ ?
I guess introducing libxcrypt /2/ will solve the issue.

/1/ https://sourceware.org/glibc/wiki/Release/2.38#Building_libcrypt_is_disabled_by_default
/2/ https://github.com/besser82/libxcrypt

@pmenzel
Copy link
Collaborator Author

pmenzel commented May 5, 2026

@thomas, thank you for the tip. That was indeed it. After

$ sudo bee install libxcrypt-4.5.2
$ sudo bee update glibc-2.43

sudo still works, and I am able to log in over SSH.

@pmenzel
Copy link
Collaborator Author

pmenzel commented May 27, 2026

Tested on maleficent.

@donald
Copy link
Collaborator

donald commented May 27, 2026

tested on theinternet

@donald
Copy link
Collaborator

donald commented Jun 3, 2026

Possible problem: mariux64/mariux64-issues#217

@donald
Copy link
Collaborator

donald commented Jun 26, 2026

Can we get C.UTF8 locale?

@wwwutz
Copy link
Collaborator

wwwutz commented Jun 26, 2026

Can we get C.UTF8 locale?

Are there cookies included ? Ice ?

Go for it.

pmenzel added 11 commits August 1, 2026 08:24
glibc 2.43 already contains the three fixes below, so drop the patches:

    glibc-linux-Fix-sys-mount.h-usage-with-kernel-headers.patch
    glibc-2.36-0004-tunables-Terminate-if-end-of-input-is-reached-CVE-2023-4911.patch
    glibc-2.36-Makerules-fix-MAKEFLAGS-assignment-for-upcoming-make.patch

The two ldconfig patches are MarIuX specific and have to stay.
Update to the latest stable Linux release, so glibc is built against
up to date kernel headers.
Building glibc 2.43 against the Linux 7.0 headers fails, because
glibc's <sys/mount.h> and the kernel's <linux/mount.h> both define
OPEN_TREE_CLONE, and the two definitions differ:

    In file included from ../sysdeps/unix/sysv/linux/include/sys/mount.h:22,
                     from ../sysdeps/unix/sysv/linux/umount.c:18:
    ../sysdeps/unix/sysv/linux/sys/mount.h:268: error: "OPEN_TREE_CLONE" redefined [-Werror]
      268 | #define OPEN_TREE_CLONE    1         /* Clone the target tree and attach the clone */
          |
    In file included from ../sysdeps/unix/sysv/linux/sys/mount.h:32:
    /usr/include/linux/mount.h:64: note: this is the location of the previous definition
       64 | #define OPEN_TREE_CLONE         (1 << 0)        /* Clone the target tree and attach the clone */
          |
    In file included from ../sysdeps/unix/sysv/linux/include/sys/mount.h:22,
                     from ../sysdeps/unix/sysv/linux/umount2.c:19:
    ../sysdeps/unix/sysv/linux/sys/mount.h:268: error: "OPEN_TREE_CLONE" redefined [-Werror]
      268 | #define OPEN_TREE_CLONE    1         /* Clone the target tree and attach the clone */
          |
    In file included from ../sysdeps/unix/sysv/linux/sys/mount.h:32:
    /usr/include/linux/mount.h:64: note: this is the location of the previous definition
       64 | #define OPEN_TREE_CLONE         (1 << 0)        /* Clone the target tree and attach the clone */
          |
    cc1: all warnings being treated as errors
    cc1: all warnings being treated as errors
    make[2]: *** [/dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/sysd-rules:263: /dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/misc/umount.os] Error 1
    make[2]: *** Waiting for unfinished jobs....
    make[2]: *** [/dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/sysd-rules:263: /dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/misc/umount2.os] Error 1
    cc1: all warnings being treated as errors
    cc1: all warnings being treated as errors
    make[2]: *** [/dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/sysd-rules:247: /dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/misc/umount.o] Error 1
    make[2]: *** [/dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/sysd-rules:247: /dev/shm/bee-pmenzel/glibc/glibc-2.43-0/build/misc/umount2.o] Error 1
    make[2]: Leaving directory '/dev/shm/bee-pmenzel/glibc/glibc-2.43-0/source/misc'
    make[1]: *** [Makefile:484: misc/subdir_lib] Error 2
    make[1]: Leaving directory '/dev/shm/bee-pmenzel/glibc/glibc-2.43-0/source'
    make: *** [Makefile:20: all] Error 2

So go back to the 6.18 series, whose headers glibc 2.43 builds against.
Building glibc 2.43 against the Linux 7.0 headers fails, because
glibc's <sys/mount.h> redefines OPEN_TREE_CLONE, which the kernel's
<linux/mount.h> already defines:

    ../sysdeps/unix/sysv/linux/sys/mount.h:268: error: "OPEN_TREE_CLONE" redefined [-Werror]
      268 | #define OPEN_TREE_CLONE    1         /* Clone the target tree and attach the clone */

So backport the two upstream commits fixing bug 33921 [1]:

    Commit 419245719ccb ("include: isolate __O_CLOEXEC flag for
    sys/mount.h and fcntl.h", 2026-01-26) stops <sys/mount.h> from
    pulling in <fcntl.h>, and commit d12b017cddfe ("Linux: Only define
    OPEN_TREE_* macros in <sys/mount.h> if undefined (bug 33921)",
    2026-03-04) only defines the OPEN_TREE_* macros if the kernel
    headers did not already define them.

[1]: https://sourceware.org/bugzilla/show_bug.cgi?id=33921
`--enable-kernel` tells glibc the oldest Linux version it has to
support at runtime.  The higher the version, the more compatibility
code glibc can drop, but the resulting binaries refuse to start on
older kernels.

Raise it from 5.15.77 to the current Linux release 7.0.3.
glibc 2.38 stopped building libcrypt by default [1]:

    * libcrypt is no longer built by default; one may use the
      "--enable-crypt" option to build libcrypt.  libcrypt is likely to
      be removed from the GNU C Library in a future release; we
      recommend that distributions and applications port away from it
      to an alternative such as libxcrypt.

As `glibc.be0` does not pass `--enable-crypt`, updating glibc to 2.43
leaves MarIuX without `libcrypt.so.1` and `<crypt.h>`.  So add
libxcrypt, the replacement recommended above, which by default
(`--enable-obsolete-api=yes`) ships a `libcrypt.so.1` compatible with
the one from glibc.

[1]: https://sourceware.org/git/?p=glibc.git;a=blob;f=NEWS;hb=refs/tags/glibc-2.38
libxcrypt requires Perl 5.14 or later — `configure.ac` calls
`zw_PROG_PERL([5.14.0])` and uses Perl to generate the hash tables and
the symbol version floor — but MarIuX' system Perl is 5.12.1, so
`configure` aborts with *Perl version 5.14.0 or later is required*.

So source the profile of the packaged Perl 5.34.0.
Requiring Linux 7.0.3 makes the glibc binaries refuse to start on every
kernel MarIuX currently ships, the oldest being 5.15.77:

    $ fakeroot bee list linux | grep ^linux
    linux-5.15.77-440.x86_64
    linux-5.15.86-443.x86_64
    linux-5.15.94-447.x86_64
    linux-5.15.112-449.x86_64
    linux-5.15.131-457.x86_64
    linux-5.15.160-476.x86_64
    linux-6.1.53-458.x86_64
    linux-6.6.12-461.x86_64
    linux-6.6.35-477.x86_64
    linux-6.12.11-479.x86_64
    linux-6.12.29-483.x86_64
    linux-6.12.40-484.x86_64
    linux-6.12.49-487.x86_64
    linux-6.12.74-489.x86_64
    linux-firmware-20230804_p7_g789aa815-2.x86_64
    linux-headers-6.15.3-0.x86_64

So lower `--enable-kernel` to 5.15 again.
`mee_install_post()` only generates the locales listed there, and
C.UTF-8 is not among them.  It is the locale independent UTF-8 locale
more and more programs expect, and without it `LC_ALL=C.UTF-8` fails
and programs fall back to the ASCII only C locale.

So generate it, too.
@pmenzel pmenzel force-pushed the update-glibc-from-2.36-to-2.43 branch from 761da85 to 63302e1 Compare August 1, 2026 08:47
Sign in to join this conversation on GitHub.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants