Diff glibc-2.33-r14 with a glibc-2.34-r14

/usr/portage/sys-libs/glibc/glibc-2.34-r14.ebuild 2024-12-25 14:59:52.815270184 +0300
20 20
EMULTILIB_PKG="true"
21 21

  
22 22
# Gentoo patchset (ignored for live ebuilds)
23
PATCH_VER=11
23
PATCH_VER=17
24 24
PATCH_DEV=dilfridge
25 25

  
26 26
if [[ ${PV} == 9999* ]]; then
......
37 37

  
38 38
LOCALE_GEN_VER=2.22
39 39

  
40
GLIBC_SYSTEMD_VER=20210814
40
GLIBC_SYSTEMD_VER=20210729
41 41

  
42 42
SRC_URI+=" https://gitweb.gentoo.org/proj/locale-gen.git/snapshot/locale-gen-${LOCALE_GEN_VER}.tar.gz"
43 43
SRC_URI+=" multilib-bootstrap? ( https://dev.gentoo.org/~dilfridge/distfiles/gcc-multilib-bootstrap-${GCC_BOOTSTRAP_VER}.tar.xz )"
44 44
SRC_URI+=" systemd? ( https://gitweb.gentoo.org/proj/toolchain/glibc-systemd.git/snapshot/glibc-systemd-${GLIBC_SYSTEMD_VER}.tar.gz )"
45 45

  
46
IUSE="audit caps cet compile-locales +crypt custom-cflags doc gd headers-only +multiarch multilib multilib-bootstrap nscd profile selinux +ssp +static-libs static-pie suid systemd systemtap test vanilla"
46
IUSE="audit caps cet +clone3 compile-locales +crypt custom-cflags doc gd headers-only +multiarch multilib multilib-bootstrap nscd profile selinux +ssp +static-libs static-pie suid systemd systemtap test vanilla"
47 47

  
48 48
# Minimum kernel version that glibc requires
49 49
MIN_KERN_VER="3.2.0"
50
# Minimum pax-utils version needed (which contains any new syscall changes for
51
# its seccomp filter!). Please double check this!
52
MIN_PAX_UTILS_VER="1.3.3"
50 53

  
51 54
# Here's how the cross-compile logic breaks down ...
52 55
#  CTARGET - machine that will target the binaries
......
100 103

  
101 104
BDEPEND="
102 105
	${PYTHON_DEPS}
103
	>=app-misc/pax-utils-1.3.1
106
	>=app-misc/pax-utils-${MIN_PAX_UTILS_VER}
104 107
	sys-devel/bison
105 108
	doc? ( sys-apps/texinfo )
106 109
	!compile-locales? (
......
132 135
	sys-apps/grep
133 136
	app-alternatives/awk
134 137
	sys-apps/gentoo-functions
135
	!<app-misc/pax-utils-1.3.1
138
	!<app-misc/pax-utils-${MIN_PAX_UTILS_VER}
136 139
	!<net-misc/openssh-8.1_p1-r2
137 140
"
138 141

  
......
163 166
# The following tests fail due to the Gentoo build system and are thus
164 167
# executed but ignored:
165 168
XFAIL_TEST_LIST=(
166
	# 9) Failures of unknown origin
167
	tst-latepthread
168

  
169 169
	# buggy test, assumes /dev/ and /dev/null on a single filesystem
170 170
	# 'mount --bind /dev/null /chroot/dev/null' breaks it.
171 171
	# https://sourceware.org/PR25909
172 172
	tst-support_descriptors
173 173

  
174
	# Flaky test, known to fail occasionally:
175
	# https://sourceware.org/PR19329
176
	# https://bugs.gentoo.org/719674#c12
177
	tst-stack4
178

  
179 174
	# The following tests fail only inside portage
180 175
	# https://bugs.gentoo.org/831267
181 176
	tst-system
......
326 321
				export CFLAGS_x86="${CFLAGS_x86} -march=${t}"
327 322
				einfo "Auto adding -march=${t} to CFLAGS_x86 #185404 (ABI=${ABI})"
328 323
			fi
324

  
325
			# Workaround for https://bugs.gentoo.org/823780. This really should
326
			# be removed when the upstream bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103275
327
			# is fixed in our tree, either via 11.3 or an 11.2p2 patch set.
328
			if [[ ${ABI} == x86 ]] && tc-is-gcc && (($(gcc-major-version) == 11)) && (($(gcc-minor-version) <= 2)) && (($(gcc-micro-version) == 0)); then
329
				export CFLAGS_x86="${CFLAGS_x86} -mno-avx512f"
330
				einfo "Auto adding -mno-avx512f to CFLAGS_x86 (bug #823780) (ABI=${ABI})"
331
			fi
329 332
		;;
330 333
		mips)
331 334
			# The mips abi cannot support the GNU style hashes. #233233
......
400 403
		filter-flags '-O?'
401 404
		append-flags -O2
402 405
	fi
406

  
403 407
	strip-unsupported-flags
404 408
	filter-lto
405 409
	filter-flags -m32 -m64 '-mabi=*'
......
439 443
	replace-flags -O0 -O1
440 444

  
441 445
	filter-flags '-fstack-protector*'
446

  
447
	# See end of bug #830454; we handle this via USE=cet
448
	filter-flags '-fcf-protection='
442 449
}
443 450

  
444 451
use_multiarch() {
......
526 533
		# a good start into that direction.
527 534
		# Also, if you're crosscompiling, let's assume you know what you are doing.
528 535
		# Hopefully.
536
		# Last, we need the settings of the *build* environment, not of the
537
		# target environment...
529 538

  
530
		local current_binutils_path=$(binutils-config -B)
531
		local current_gcc_path=$(gcc-config -B)
539
		local current_binutils_path=$(env ROOT="${BROOT}" binutils-config -B)
540
		local current_gcc_path=$(env ROOT="${BROOT}" gcc-config -B)
532 541
		einfo "Overriding clang configuration, since it won't work here"
533 542

  
534 543
		export CC="${current_gcc_path}/gcc"
......
765 774

  
766 775
	# When we actually have to compile something...
767 776
	if ! just_headers && [[ ${MERGE_TYPE} != "binary" ]] ; then
777
		if [[ -d "${ESYSROOT}"/usr/lib/include ]] ; then
778
			# bug #833620, bug #643302
779
			eerror "Found ${ESYSROOT}/usr/lib/include directory!"
780
			eerror "This is known to break glibc's build."
781
			eerror "Please backup its contents then remove the directory."
782
			die "Found directory (${ESYSROOT}/usr/lib/include) which will break build (bug #833620)!"
783
		fi
784

  
768 785
		if [[ ${CTARGET} == *-linux* ]] ; then
769 786
			local run_kv build_kv want_kv
770 787

  
......
800 817
				ewarn "After upgrading glibc, please restart all running processes."
801 818
				ewarn "Be sure to include init (telinit u) or systemd (systemctl daemon-reexec)."
802 819
				ewarn "Alternatively, reboot your system."
820
				ewarn "(See bug #660556, bug #741116, bug #823756, etc)"
803 821
				break
804 822
			fi
805 823
		done
......
868 886
		einfo "Done."
869 887
	fi
870 888

  
889
	if use clone3 ; then
890
		append-cppflags -DGENTOO_USE_CLONE3
891
	else
892
		# See e.g. bug #827386, bug #819045.
893
		elog "Disabling the clone3 syscall for compatibility with older Electron apps."
894
		elog "Please re-enable this flag before filing bugs!"
895
	fi
896

  
871 897
	default
872 898

  
873 899
	gnuconfig_update
......
1012 1038
	export libc_cv_rootsbindir="$(host_eprefix)/sbin"
1013 1039
	export libc_cv_slibdir="$(host_eprefix)/$(get_libdir)"
1014 1040

  
1015
	# We take care of patching our binutils to use both hash styles,
1016
	# and many people like to force gnu hash style only, so disable
1017
	# this overriding check.  #347761
1018
	export libc_cv_hashstyle=no
1019

  
1020 1041
	local builddir=$(builddir nptl)
1021 1042
	mkdir -p "${builddir}"
1022 1043
	cd "${builddir}"
......
1507 1528

  
1508 1529
	# first let's find the actual dynamic linker here
1509 1530
	# symlinks may point to the wrong abi
1510
	local newldso=$(find . -maxdepth 1 -name 'ld-*so' -type f -print -quit)
1531
	local newldso=$(find . -maxdepth 1 -name 'ld*so.?' -type f -print -quit)
1511 1532

  
1512 1533
	einfo Last-minute run tests with ${newldso} in /$(get_libdir) ...
1513 1534

  
Thank you!