diff options
41 files changed, 5211 insertions, 1855 deletions
diff --git a/app-benchmarks/s-tui/Manifest b/app-benchmarks/s-tui/Manifest index 07ed50e..5773298 100644 --- a/app-benchmarks/s-tui/Manifest +++ b/app-benchmarks/s-tui/Manifest @@ -1,2 +1,2 @@ -DIST s-tui-1.1.4.tar.gz 2608449 BLAKE2B 80dfc8c4dbce181cf50a5fe3bf05b553401f0cd17b184b9123e61807ee1e5c06bdbdf543fc86a0aca8f7aa4aa508e76756047a121e5d6ddbce167e097938a870 SHA512 20adfb27bae6467650a901211f4b58d0351d756a5b9465922953feb3711969c6d647782f99479475499b4658ef65da6283ad4e55ce72839d36c08f8a7f244322 -EBUILD s-tui-1.1.4-r1.ebuild 926 BLAKE2B 05a9f9ca6328c02eec74cb0fcee6ea0ae9178f352a707a2484ab49ba3575efc888594dfdd8112e607d445f9783580754c521a2e75d8a75c3ebe01643c008dafd SHA512 d300c552dc47c654a7f8f9741c87bf87dd4c8e1380568b6aeabed4f4cad10dad29220c90c2773d6536f0c7b95a35c6de2ab8362f6d32a4ca9be1d067f5f17685 +DIST s-tui-1.1.6.tar.gz 2608253 BLAKE2B 64815def105ad3c57f2103841ad09948ec6205bda09f4afca7dcca3bb9586c3e8d08aa0524d42f086f589f613bd79b389fca0f55182391bf20679b4d040eb087 SHA512 73412b55175ca2a5e98e410a3c9b5ce9aa1cffc13eb9af26e834d0ea784c06f6a9f81bb1be028b8cf94046ff0a8b20fff5b1191c949d49a72cecf3abd6a1fc38 +EBUILD s-tui-1.1.6.ebuild 926 BLAKE2B 5ae169a4aa7a8e061c2c395b49b0bfa5d5b11afc0277fba0de9737cac00c8a01dd77cb797f40c95875aa48480461e54adeb9131c87655f4f861c771dc6221040 SHA512 7618084adec1a46648f93f1d2b2f6ef4fc65aad18210c078c7e358217bac1135bdfef9e89e82d52aa4f6c9f23993425e253e3af4685bdbb27b994f3e49f5d0e2 diff --git a/app-benchmarks/s-tui/s-tui-1.1.4-r1.ebuild b/app-benchmarks/s-tui/s-tui-1.1.6.ebuild index 01ca0a2..6f28e3c 100644 --- a/app-benchmarks/s-tui/s-tui-1.1.4-r1.ebuild +++ b/app-benchmarks/s-tui/s-tui-1.1.6.ebuild @@ -3,7 +3,7 @@ EAPI=8 -PYTHON_COMPAT=( python3_{9..11} ) +PYTHON_COMPAT=( python3_{9..13} ) DISTUTILS_USE_PEP517=setuptools inherit distutils-r1 optfeature diff --git a/app-misc/ledit/Manifest b/app-misc/ledit/Manifest index fa2dd99..628b25a 100644 --- a/app-misc/ledit/Manifest +++ b/app-misc/ledit/Manifest @@ -1,2 +1,2 @@ -DIST ledit-2-05.tar.gz 25220 BLAKE2B fb6251390ba75269022198defb8680f7b3fcf01c86f67cf207184abd7b66b0cfc1fca0cb1e1505e78933323470bff53f747335d5c92e3055e38cd1cc33ba4aed SHA512 1415ded092ed4b0c75dbc52508f8b4cdc3645b0cc63a50de613f4854fdeca05bf05ae335398f803cb28144650a35b4f7b9453fd0488fad217c1450dc64e0d04a -EBUILD ledit-2.05.ebuild 1068 BLAKE2B 3f586a49be240f4c3d1e5e54eb6d44eefd8d93fdfc47a57097a6c6735c0182942aec59d17e9cd2f9b277401c94dd4460b78881a2fd300d8d391044dfa2eaa6ca SHA512 c16709e1470450a264a6f5e54a06b637eccb31c10036b362f9eb8867e0e973c393bbf5338abc07eadcb07a50d0653626bfd50bf8989eddd73d0590d2a1cce74a +DIST ledit-2-06.tar.gz 25413 BLAKE2B a2116f3e723a712ab3afa97601e18310d7d6be35eed94ac7217f063023f1ab1c1cd1228077028e6c1bbd7b44232155fdca5a172084ebb6525d53dc0b630f01f7 SHA512 d82f89e329fc13262266c8d606bf4bc14d6d1a785d05e4d53fe169e07a8b0ab563d8d41c95eed0a3235d6795a5300b954a343c6e326bf04fa2eea50686a6aa89 +EBUILD ledit-2.06.ebuild 1068 BLAKE2B 3f586a49be240f4c3d1e5e54eb6d44eefd8d93fdfc47a57097a6c6735c0182942aec59d17e9cd2f9b277401c94dd4460b78881a2fd300d8d391044dfa2eaa6ca SHA512 c16709e1470450a264a6f5e54a06b637eccb31c10036b362f9eb8867e0e973c393bbf5338abc07eadcb07a50d0653626bfd50bf8989eddd73d0590d2a1cce74a diff --git a/app-misc/ledit/ledit-2.05.ebuild b/app-misc/ledit/ledit-2.06.ebuild index cbf9fd4..cbf9fd4 100644 --- a/app-misc/ledit/ledit-2.05.ebuild +++ b/app-misc/ledit/ledit-2.06.ebuild diff --git a/dev-lang/rust/Manifest b/dev-lang/rust/Manifest new file mode 100644 index 0000000..e2bd9b4 --- /dev/null +++ b/dev-lang/rust/Manifest @@ -0,0 +1,8 @@ +DIST rust-patches-1.88.0.tar.bz2 4062 BLAKE2B 64168ffa608f2edf2e0b3d079152c3b5dd59d0cea29078894f286bf91488e2e7769c55ede2d43769368d2147b46699d1bf981190d6800dc3d41c736289122eaf SHA512 b565acfb4d1146e52b1fb66b4a242927407cc34f1b38c2a100135cbbde24c8374af1997bc22069cca25f33cc8d747e56391f3d98a2d4e13dc0abcec0d6f88b0b +DIST rust-patches-1.89.0.tar.bz2 4091 BLAKE2B 0fea3488a39d2b00627084f6b192dfbd7ed49bdceabbb1141d1a849ba053f786e31115e00365679b1b6fb5b0ccdf5dc0dc0803057cbffbcf0ae3d75ae9830d94 SHA512 de6c9b693bdd719d06605b5da730ee5d9cf9a1d88d58194a0ba48bd378a951c66723f561e39181222d28abb38e974a2921e14ea1f40156caf7b903778cf65790 +DIST rustc-1.88.0-src.tar.xz 283294344 BLAKE2B fc17efbc8b2e54f2da61384097dcb3b8f595f27f7853f56cef034913f6b46a718113af0fe66f0e3b0afd184ec506b35f3b74172926cf727ddc061f567d54fa4c SHA512 e6c62af2953f49462b2369e9551b12f2bec114577f90e3e76049636da4279b1e7f4d53bc6896f5d0d4715d90ef6d29dacff529a45690ffac6af62ad64600db40 +DIST rustc-1.88.0-src.tar.xz.asc 801 BLAKE2B 858e987ad1fc49c1e1cbc5ea709f835c60fce907e89205e431c843bfad97dc0ccbcf399fc7d87319b8455561cbc24020bd88cb572cbe932cb8b80a8adec39687 SHA512 64ab398dc602fed3ad7bf232249e80cc0a9831aa90c7eb37658f7dc5b2af04ee391f9633aae7a1d90f743d019cec531318384f71384ecbe4f6169e6e88b7ba0e +DIST rustc-1.89.0-src.tar.xz 267487572 BLAKE2B 9f6e3c595f843c239b57f14e26685e9856cffa10189b75627fee4dc82970a9b5f2c6f42e145d1c1042d934bd4db0334014c046450f7594d621b378d951546d5d SHA512 3ac0f02baaff12c67fe35cef4d56b315134d0a043bb6103a248a2842456c74733c6e3039f079bacfb8b8ab9b7487f92d678987e588bd41276abf9bf7c2f7870b +DIST rustc-1.89.0-src.tar.xz.asc 801 BLAKE2B cd94da916d3646048d8f90c6de658de2981d0c815a1f8da01fe58ab6ec133e47180c8b506a41e22c68b3cb77aff5bd3bfc966a71ae2b73849918096d68764386 SHA512 006b91bf41fbedf91c39b8a6e483b089f69af7e78026f2903928fed64e44ee6aa53e46fd19bae31b1576b53a80dab66bf3e53a3bf79f820066d36285d706b90c +EBUILD rust-1.88.0-r991.ebuild 26315 BLAKE2B 553310be960b3478202c9f65c0fbae6ec15b38ad0687b7eae23172901fefce859b84573126766b008a841875db22bbd043f324966fc7080ca742adcb567677b1 SHA512 2de9182edfa8152113bc8c14e53f53e58ab36b35594c1f16fe6a6267bd4d52d35408f4db19aef06edcf6eebc73a88c1c5621dc125006a0f4e6b6dadab2f00a40 +EBUILD rust-1.89.0-r990.ebuild 26451 BLAKE2B 8bd999d54bbaaec33e01dbc232a8d1e1596a40ff80bf7850ff28cb1c3502328614b881f0e6cda616f4390db5a1cd54187dd31ea1c81a19f4377c146a27b64bd5 SHA512 45059e9dc65262973d4d0b071656cd9fc3e0ef48941a4501fb84d7b57b3bea7bb4dffcf3e1d8320676e256c3c2aefd8e1d764ae1d955df51cda622ebc3fb74d1 diff --git a/dev-lang/rust/rust-1.88.0-r991.ebuild b/dev-lang/rust/rust-1.88.0-r991.ebuild new file mode 100644 index 0000000..ab26045 --- /dev/null +++ b/dev-lang/rust/rust-1.88.0-r991.ebuild @@ -0,0 +1,837 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LLVM_COMPAT=( 20 ) +PYTHON_COMPAT=( python3_{11..14} ) + +RUST_PATCH_VER="1.88.0" + +RUST_MAX_VER=${PV%%_*} +if [[ ${PV} == *9999* ]]; then + RUST_MIN_VER="1.88.0" # Update this as new `beta` releases come out. +elif [[ ${PV} == *beta* ]]; then + RUST_MAX_VER="$(ver_cut 1).$(ver_cut 2).0" + RUST_MIN_VER="$(ver_cut 1).$(($(ver_cut 2) - 1)).0" +else + RUST_MIN_VER="$(ver_cut 1).$(($(ver_cut 2) - 1)).0" +fi + +inherit check-reqs estack flag-o-matic llvm-r1 multiprocessing optfeature \ + multilib multilib-build python-any-r1 rust rust-toolchain toolchain-funcs verify-sig + +if [[ ${PV} = *9999* ]]; then + inherit git-r3 +elif [[ ${PV} == *beta* ]]; then + # Identify the snapshot date of the beta release: + # curl -Ls static.rust-lang.org/dist/channel-rust-beta.toml | grep beta-src.tar.xz + betaver=${PV//*beta} + BETA_SNAPSHOT="${betaver:0:4}-${betaver:4:2}-${betaver:6:2}" + MY_P="rustc-beta" + SRC_URI="https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz -> rustc-${PV}-src.tar.xz + https://gitweb.gentoo.org/proj/rust-patches.git/snapshot/rust-patches-${RUST_PATCH_VER}.tar.bz2 + verify-sig? ( https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz.asc + -> rustc-${PV}-src.tar.xz.asc ) + " + S="${WORKDIR}/${MY_P}-src" +else + MY_P="rustc-${PV}" + SRC_URI="https://static.rust-lang.org/dist/${MY_P}-src.tar.xz + https://gitweb.gentoo.org/proj/rust-patches.git/snapshot/rust-patches-${RUST_PATCH_VER}.tar.bz2 + verify-sig? ( https://static.rust-lang.org/dist/${MY_P}-src.tar.xz.asc ) + " + S="${WORKDIR}/${MY_P}-src" + KEYWORDS="~amd64 ~arm ~arm64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86" +fi + +DESCRIPTION="Systems programming language originally developed by Mozilla" +HOMEPAGE="https://www.rust-lang.org/" + +# keep in sync with llvm ebuild of the same version as bundled one. +ALL_LLVM_TARGETS=( AArch64 AMDGPU ARC ARM AVR BPF CSKY DirectX Hexagon Lanai + LoongArch M68k Mips MSP430 NVPTX PowerPC RISCV Sparc SPIRV SystemZ VE + WebAssembly X86 XCore Xtensa ) +ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) +LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/(-)?} + +# https://github.com/rust-lang/llvm-project/blob/rustc-1.84.0/llvm/CMakeLists.txt +_ALL_RUST_EXPERIMENTAL_TARGETS=( ARC CSKY DirectX M68k SPIRV Xtensa ) +declare -A ALL_RUST_EXPERIMENTAL_TARGETS +for _x in "${_ALL_RUST_EXPERIMENTAL_TARGETS[@]}"; do + ALL_RUST_EXPERIMENTAL_TARGETS["llvm_targets_${_x}"]=0 +done + +LICENSE="|| ( MIT Apache-2.0 ) BSD BSD-1 BSD-2 BSD-4" +SLOT="${PV%%_*}" # Beta releases get to share the same SLOT as the eventual stable + +IUSE="big-endian clippy cpu_flags_x86_sse2 debug dist doc llvm-libunwind lto rustfmt rust-analyzer rust-src +system-llvm test wasm ${ALL_LLVM_TARGETS[*]}" + +if [[ ${PV} = *9999* ]]; then + # These USE flags require nightly rust + IUSE+=" miri" +fi +IUSE+=" nightly" + +LLVM_DEPEND=() +# splitting usedeps needed to avoid CI/pkgcheck's UncheckableDep limitation +for _x in "${ALL_LLVM_TARGETS[@]}"; do + LLVM_DEPEND+=( " ${_x}? ( $(llvm_gen_dep "llvm-core/llvm:\${LLVM_SLOT}[${_x}]") )" ) + if [[ -v ALL_RUST_EXPERIMENTAL_TARGETS["${_x}"] ]] ; then + ALL_RUST_EXPERIMENTAL_TARGETS["${_x}"]=1 + fi +done +LLVM_DEPEND+=( " wasm? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') )" ) +LLVM_DEPEND+=( " $(llvm_gen_dep 'llvm-core/llvm:${LLVM_SLOT}')" ) + +# dev-libs/oniguruma is used for documentation +BDEPEND="${PYTHON_DEPS} + app-eselect/eselect-rust + dev-libs/oniguruma + || ( + >=sys-devel/gcc-4.7[cxx] + >=llvm-core/clang-3.5 + ) + lto? ( system-llvm? ( + || ( + $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') + sys-devel/mold + ) + ) ) + !system-llvm? ( + >=dev-build/cmake-3.13.4 + app-alternatives/ninja + ) + test? ( dev-debug/gdb ) + verify-sig? ( sec-keys/openpgp-keys-rust ) +" + +DEPEND=" + >=app-arch/xz-utils-5.2 + net-misc/curl:=[http2,ssl] + sys-libs/zlib:= + dev-libs/openssl:0= + system-llvm? ( + ${LLVM_DEPEND[*]} + llvm-libunwind? ( llvm-runtimes/libunwind:= ) + ) + !system-llvm? ( + !llvm-libunwind? ( + elibc_musl? ( sys-libs/libunwind:= ) + ) + ) +" + +RDEPEND="${DEPEND} + app-eselect/eselect-rust + dev-lang/rust-common + sys-apps/lsb-release + !dev-lang/rust:stable + !dev-lang/rust-bin:stable +" + +REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} ) + rust-analyzer? ( rust-src ) + test? ( ${ALL_LLVM_TARGETS[*]} ) + wasm? ( llvm_targets_WebAssembly ) + x86? ( cpu_flags_x86_sse2 ) +" + +# we don't use cmake.eclass, but can get a warning +CMAKE_WARN_UNUSED_CLI=no + +QA_FLAGS_IGNORED=" + usr/lib/${PN}/${SLOT}/bin/.* + usr/lib/${PN}/${SLOT}/libexec/.* + usr/lib/${PN}/${SLOT}/lib/lib.*.so + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/bin/.* + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/lib.*.so +" + +QA_SONAME=" + usr/lib/${PN}/${SLOT}/lib/lib.*.so.* + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/lib.*.so +" + +QA_PRESTRIPPED=" + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/bin/rust-llvm-dwp + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/self-contained/crtn.o +" + +# An rmeta file is custom binary format that contains the metadata for the crate. +# rmeta files do not support linking, since they do not contain compiled object files. +# so we can safely silence the warning for this QA check. +QA_EXECSTACK="usr/lib/${PN}/${SLOT}/lib/rustlib/*/lib*.rlib:lib.rmeta" + +# causes double bootstrap +RESTRICT="test" + +VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/rust.asc + +clear_vendor_checksums() { + sed -i 's/\("files":{\)[^}]*/\1/' "vendor/${1}/.cargo-checksum.json" || die +} + +toml_usex() { + usex "${1}" true false +} + +pre_build_checks() { + local M=9216 + # multiply requirements by 1.3 if we are doing x86-multilib + if use amd64; then + M=$(( $(usex abi_x86_32 13 10) * ${M} / 10 )) + fi + M=$(( $(usex clippy 128 0) + ${M} )) + if [[ ${PV} == *9999* ]]; then + M=$(( $(usex miri 128 0) + ${M} )) + fi + M=$(( $(usex rustfmt 256 0) + ${M} )) + # add 2G if we compile llvm and 256M per llvm_target + if ! use system-llvm; then + M=$(( 2048 + ${M} )) + local ltarget + for ltarget in ${ALL_LLVM_TARGETS[@]}; do + M=$(( $(usex ${ltarget} 256 0) + ${M} )) + done + fi + M=$(( $(usex wasm 256 0) + ${M} )) + M=$(( $(usex debug 2 1) * ${M} )) + eshopts_push -s extglob + if is-flagq '-g?(gdb)?([1-9])'; then + M=$(( 15 * ${M} / 10 )) + fi + eshopts_pop + M=$(( $(usex doc 256 0) + ${M} )) + CHECKREQS_DISK_BUILD=${M}M check-reqs_pkg_${EBUILD_PHASE} +} + +llvm_check_deps() { + has_version -r "llvm-core/llvm:${LLVM_SLOT}[${LLVM_TARGET_USEDEPS// /,}]" +} + +# Is LLVM being linked against libc++? +is_libcxx_linked() { + local code='#include <ciso646> +#if defined(_LIBCPP_VERSION) + HAVE_LIBCXX +#endif +' + local out=$($(tc-getCXX) ${CXXFLAGS} ${CPPFLAGS} -x c++ -E -P - <<<"${code}") || return 1 + [[ ${out} == *HAVE_LIBCXX* ]] +} + +pkg_pretend() { + pre_build_checks +} + +pkg_setup() { + pre_build_checks + python-any-r1_pkg_setup + + export LIBGIT2_NO_PKG_CONFIG=1 #749381 + if tc-is-cross-compiler; then + use system-llvm && die "USE=system-llvm not allowed when cross-compiling" + local cross_llvm_target="$(llvm_tuple_to_target "${CBUILD}")" + use "llvm_targets_${cross_llvm_target}" || \ + die "Must enable LLVM_TARGETS=${cross_llvm_target} matching CBUILD=${CBUILD} when cross-compiling" + fi + + rust_pkg_setup + + if use system-llvm; then + llvm-r1_pkg_setup + + local llvm_config="$(get_llvm_prefix)/bin/llvm-config" + export LLVM_LINK_SHARED=1 + export RUSTFLAGS="${RUSTFLAGS} -Lnative=$("${llvm_config}" --libdir)" + fi +} + +rust_live_get_sources() { + EGIT_REPO_URI=" + https://anongit.gentoo.org/git/proj/rust-patches.git + " + EGIT_CHECKOUT_DIR="${WORKDIR}/rust-patches-${RUST_PATCH_VER}" + git-r3_src_unpack + + EGIT_REPO_URI=" + https://github.com/rust-lang/rust.git + " + EGIT_SUBMODULES=( + "*" + "-src/gcc" + ) + S="${WORKDIR}/rust" + EGIT_CHECKOUT_DIR="${S}" + git-r3_src_unpack +} + +src_unpack() { + if [[ ${PV} == *9999* ]] ; then + rust_live_get_sources + + # Vendor dependencies + mkdir "${S}/.cargo" || die # The vendor script has a check for .cargo/config{,.toml} + touch "${S}/.cargo/bootstrap.toml" || die + local rust_stage0_root="$(${RUSTC} --print sysroot || die "Can't determine rust's sysroot")" + # Configure vendor to use the portage-provided toolchain. This prevents it from + # attempting to fetch a `beta` toolchain from the internet. + cat <<- _EOF_ > "${T}/vendor-bootstrap.toml" + # Suppresses a warning about tracking changes which we don't care about. + change-id = "ignore" + [build] + build = "$(rust_abi "${CBUILD}")" + host = ["$(rust_abi "${CHOST}")"] + target = ["$(rust_abi "${CHOST}")"] + cargo = "${rust_stage0_root}/bin/cargo" + rustc = "${rust_stage0_root}/bin/rustc" + rustfmt = "${rust_stage0_root}/bin/rustfmt" + _EOF_ + # We're using git sources so we need to run the Vendor script + # to ensure that all dependencies are present and up-to-date + mkdir "${S}/vendor" || die + # This also compiles the 'build helper', there's no way to avoid this. + ${EPYTHON} "${S}"/x.py vendor -v --config="${T}"/vendor-bootstrap.toml -j$(makeopts_jobs) || + die "Failed to vendor dependencies" + # TODO: This has to be generated somehow, this is from a 1.84.x tarball I had lying around. + cat <<- _EOF_ > "${S}/.cargo/config.toml" + [source.crates-io] + replace-with = "vendored-sources" + + [source."git+https://github.com/rust-lang/team"] + git = "https://github.com/rust-lang/team" + replace-with = "vendored-sources" + + [source.vendored-sources] + directory = "vendor" + _EOF_ + elif use verify-sig ; then + # Patch tarballs are not signed (but we trust Gentoo infra) + verify-sig_verify_detached "${DISTDIR}"/rustc-${PV}-src.tar.xz{,.asc} + default + else + default + fi +} + +src_prepare() { + if [[ ${PV} = *9999* ]]; then + # We need to update / generate lockfiles for the workspace + ${CARGO} generate-lockfile --offline || die "Failed to generate lockfiles" + fi + + PATCHES=( + "${WORKDIR}/rust-patches-${RUST_PATCH_VER}/" + ) + + if use lto && tc-is-clang && ! tc-ld-is-lld && ! tc-ld-is-mold; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + + default +} + +src_configure() { + if tc-is-cross-compiler; then + export PKG_CONFIG_ALLOW_CROSS=1 + export PKG_CONFIG_PATH="${ESYSROOT}/usr/$(get_libdir)/pkgconfig" + export OPENSSL_INCLUDE_DIR="${ESYSROOT}/usr/include" + export OPENSSL_LIB_DIR="${ESYSROOT}/usr/$(get_libdir)" + fi + + # Avoid bundled copies of libraries + export RUSTONIG_SYSTEM_LIBONIG=1 + # Need to check if these can be optional + #export LIBSQLITE3_SYS_USE_PKG_CONFIG=1 + #export LIBSSH2_SYS_USE_PKG_CONFIG=1 + + filter-lto # https://bugs.gentoo.org/862109 https://bugs.gentoo.org/866231 + + local rust_target="" rust_targets="" arch_cflags + + # Collect rust target names to compile standard libs for all ABIs. + for v in $(multilib_get_enabled_abi_pairs); do + rust_targets+=",\"$(rust_abi $(get_abi_CHOST ${v##*.}))\"" + done + if use wasm; then + rust_targets+=",\"wasm32-unknown-unknown\"" + if use system-llvm; then + # un-hardcode rust-lld linker for this target + # https://bugs.gentoo.org/715348 + sed -i '/linker:/ s/rust-lld/wasm-ld/' compiler/rustc_target/src/spec/base/wasm.rs || die + fi + fi + rust_targets="${rust_targets#,}" + + # cargo and rustdoc are mandatory and should always be included + local tools='"cargo","rustdoc"' + use clippy && tools+=',"clippy"' + use rustfmt && tools+=',"rustfmt"' + use rust-analyzer && tools+=',"rust-analyzer","rust-analyzer-proc-macro-srv"' + use rust-src && tools+=',"src"' + + if [[ ${PV} == *9999* ]]; then + use miri && tools+=',"miri"' + fi + + local rust_stage0_root="$(${RUSTC} --print sysroot || die "Can't determine rust's sysroot")" + # in case of prefix it will be already prefixed, as --print sysroot returns full path + [[ -d ${rust_stage0_root} ]] || die "${rust_stage0_root} is not a directory" + + rust_target="$(rust_abi)" + rust_build="$(rust_abi "${CBUILD}")" + rust_host="$(rust_abi "${CHOST}")" + + RUST_EXPERIMENTAL_TARGETS=() + for _x in "${!ALL_RUST_EXPERIMENTAL_TARGETS[@]}"; do + if [[ ${ALL_RUST_EXPERIMENTAL_TARGETS[${_x}]} == 1 ]] && use ${_x} ; then + RUST_EXPERIMENTAL_TARGETS+=( ${_x#llvm_targets_} ) + fi + done + RUST_EXPERIMENTAL_TARGETS=${RUST_EXPERIMENTAL_TARGETS[@]} + + local cm_btype="$(usex debug DEBUG RELEASE)" + local build_channel + local build_miri="false" + case "${PV}" in + *9999*) + build_channel="nightly" + ;; + *beta*) + build_channel="beta" + ;; + *) + build_channel="stable" + ;; + esac + use nightly && build_channel="nightly" + cat <<- _EOF_ > "${S}"/bootstrap.toml + # Suppresses a warning about tracking changes which we don't care about. + change-id = "ignore" + # https://github.com/rust-lang/rust/issues/135358 (bug #947897) + profile = "dist" + [llvm] + download-ci-llvm = false + optimize = $(toml_usex !debug) + release-debuginfo = $(toml_usex debug) + assertions = $(toml_usex debug) + ninja = true + targets = "${LLVM_TARGETS// /;}" + experimental-targets = "${RUST_EXPERIMENTAL_TARGETS// /;}" + link-shared = $(toml_usex system-llvm) + $(if is_libcxx_linked; then + # https://bugs.gentoo.org/732632 + echo "use-libcxx = true" + echo "static-libstdcpp = false" + fi) + $(case "${rust_target}" in + i586-*-linux-*) + # https://github.com/rust-lang/rust/issues/93059 + echo 'cflags = "-fcf-protection=none"' + echo 'cxxflags = "-fcf-protection=none"' + echo 'ldflags = "-fcf-protection=none"' + ;; + *) + ;; + esac) + enable-warnings = false + [llvm.build-config] + CMAKE_VERBOSE_MAKEFILE = "ON" + $(if ! tc-is-cross-compiler; then + # When cross-compiling, LLVM is compiled twice, once for host and + # once for target. Unfortunately, this build configuration applies + # to both, which means any flags applicable to one target but not + # the other will break. Conditionally disable respecting user + # flags when cross-compiling. + echo "CMAKE_C_FLAGS_${cm_btype} = \"${CFLAGS}\"" + echo "CMAKE_CXX_FLAGS_${cm_btype} = \"${CXXFLAGS}\"" + echo "CMAKE_EXE_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\"" + echo "CMAKE_MODULE_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\"" + echo "CMAKE_SHARED_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\"" + echo "CMAKE_STATIC_LINKER_FLAGS_${cm_btype} = \"${ARFLAGS}\"" + fi) + [build] + build-stage = 2 + test-stage = 2 + build = "${rust_build}" + host = ["${rust_host}"] + target = [${rust_targets}] + cargo = "${rust_stage0_root}/bin/cargo" + rustc = "${rust_stage0_root}/bin/rustc" + rustfmt = "${rust_stage0_root}/bin/rustfmt" + docs = $(toml_usex doc) + compiler-docs = false + submodules = false + python = "${EPYTHON}" + locked-deps = true + vendor = true + extended = true + tools = [${tools}] + verbose = 2 + sanitizers = false + profiler = true + cargo-native-static = false + [install] + prefix = "${EPREFIX}/usr/lib/${PN}/${SLOT}" + sysconfdir = "etc" + docdir = "share/doc/rust" + bindir = "bin" + libdir = "lib" + mandir = "share/man" + [rust] + # https://github.com/rust-lang/rust/issues/54872 + codegen-units-std = 1 + optimize = true + debug = $(toml_usex debug) + debug-assertions = $(toml_usex debug) + debug-assertions-std = $(toml_usex debug) + debuginfo-level = $(usex debug 2 0) + debuginfo-level-rustc = $(usex debug 2 0) + debuginfo-level-std = $(usex debug 2 0) + debuginfo-level-tools = $(usex debug 2 0) + debuginfo-level-tests = 0 + backtrace = true + incremental = false + $(if ! tc-is-cross-compiler; then + echo "default-linker = \"${CHOST}-cc\"" + fi) + channel = "${build_channel}" + description = "gentoo" + rpath = true + verbose-tests = true + optimize-tests = $(toml_usex !debug) + codegen-tests = true + omit-git-hash = false + dist-src = false + remap-debuginfo = true + lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang && ! tc-ld-is-mold; then + echo "use-lld = true" + fi) + # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it + # https://github.com/rust-lang/rust/issues/74976 + # https://github.com/rust-lang/rust/issues/76526 + deny-warnings = $(usex wasm $(usex doc false true) true) + backtrace-on-ice = true + jemalloc = false + # See https://github.com/rust-lang/rust/issues/121124 + lto = "$(usex lto thin off)" + [dist] + src-tarball = false + compression-formats = ["xz"] + compression-profile = "balanced" + _EOF_ + + for v in $(multilib_get_enabled_abi_pairs); do + rust_target=$(rust_abi $(get_abi_CHOST ${v##*.})) + arch_cflags="$(get_abi_CFLAGS ${v##*.})" + + export CFLAGS_${rust_target//-/_}="${arch_cflags}" + + cat <<- _EOF_ >> "${S}"/bootstrap.toml + [target.${rust_target}] + ar = "$(tc-getAR)" + cc = "$(tc-getCC)" + cxx = "$(tc-getCXX)" + linker = "$(tc-getCC)" + ranlib = "$(tc-getRANLIB)" + llvm-libunwind = "$(usex llvm-libunwind $(usex system-llvm system in-tree) no)" + _EOF_ + if use system-llvm; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + llvm-config = "$(get_llvm_prefix)/bin/llvm-config" + _EOF_ + fi + # by default librustc_target/spec/linux_musl_base.rs sets base.crt_static_default = true; + # but we patch it and set to false here as well + if use elibc_musl; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + crt-static = false + musl-root = "$($(tc-getCC) -print-sysroot)/usr" + _EOF_ + fi + done + if use wasm; then + wasm_target="wasm32-unknown-unknown" + export CFLAGS_${wasm_target//-/_}="$(filter-flags '-mcpu*' '-march*' '-mtune*'; echo "$CFLAGS")" + cat <<- _EOF_ >> "${S}"/bootstrap.toml + [target.wasm32-unknown-unknown] + linker = "$(usex system-llvm lld rust-lld)" + # wasm target does not have profiler_builtins https://bugs.gentoo.org/848483 + profiler = false + _EOF_ + fi + + if [[ -n ${I_KNOW_WHAT_I_AM_DOING_CROSS} ]]; then # whitespace intentionally shifted below + # experimental cross support + # discussion: https://bugs.gentoo.org/679878 + # TODO: c*flags, clang, system-llvm, cargo.eclass target support + # it would be much better if we could split out stdlib + # complilation to separate ebuild and abuse CATEGORY to + # just install to /usr/lib/rustlib/<target> + + # extra targets defined as a bash array + # spec format: <LLVM target>:<rust-target>:<CTARGET> + # best place would be /etc/portage/env/dev-lang/rust + # Example: + # RUST_CROSS_TARGETS=( + # "AArch64:aarch64-unknown-linux-gnu:aarch64-unknown-linux-gnu" + # ) + # no extra hand holding is done, no target transformations, all + # values are passed as-is with just basic checks, so it's up to user to supply correct values + # valid rust targets can be obtained with + # rustc --print target-list + # matching cross toolchain has to be installed + # matching LLVM_TARGET has to be enabled for both rust and llvm (if using system one) + # only gcc toolchains installed with crossdev are checked for now. + + # BUG: we can't pass host flags to cross compiler, so just filter for now + # BUG: this should be more fine-grained. + filter-flags '-mcpu=*' '-march=*' '-mtune=*' + + local cross_target_spec + for cross_target_spec in "${RUST_CROSS_TARGETS[@]}";do + # extracts first element form <LLVM target>:<rust-target>:<CTARGET> + local cross_llvm_target="${cross_target_spec%%:*}" + # extracts toolchain triples, <rust-target>:<CTARGET> + local cross_triples="${cross_target_spec#*:}" + # extracts first element after before : separator + local cross_rust_target="${cross_triples%%:*}" + # extracts last element after : separator + local cross_toolchain="${cross_triples##*:}" + use llvm_targets_${cross_llvm_target} || die "need llvm_targets_${cross_llvm_target} target enabled" + command -v ${cross_toolchain}-gcc > /dev/null 2>&1 || die "need ${cross_toolchain} cross toolchain" + + cat <<- _EOF_ >> "${S}"/bootstrap.toml + [target.${cross_rust_target}] + ar = "${cross_toolchain}-ar" + cc = "${cross_toolchain}-gcc" + cxx = "${cross_toolchain}-g++" + linker = "${cross_toolchain}-gcc" + ranlib = "${cross_toolchain}-ranlib" + _EOF_ + if use system-llvm; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + llvm-config = "$(get_llvm_prefix)/bin/llvm-config" + _EOF_ + fi + if [[ "${cross_toolchain}" == *-musl* ]]; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + musl-root = "$(${cross_toolchain}-gcc -print-sysroot)/usr" + _EOF_ + fi + + # append cross target to "normal" target list + # example 'target = ["powerpc64le-unknown-linux-gnu"]' + # becomes 'target = ["powerpc64le-unknown-linux-gnu","aarch64-unknown-linux-gnu"]' + + rust_targets="${rust_targets},\"${cross_rust_target}\"" + sed -i "/^target = \[/ s#\[.*\]#\[${rust_targets}\]#" bootstrap.toml || die + + ewarn + ewarn "Enabled ${cross_rust_target} rust target" + ewarn "Using ${cross_toolchain} cross toolchain" + ewarn + if ! has_version -b 'sys-devel/binutils[multitarget]' ; then + ewarn "'sys-devel/binutils[multitarget]' is not installed" + ewarn "'strip' will be unable to strip cross libraries" + ewarn "cross targets will be installed with full debug information" + ewarn "enable 'multitarget' USE flag for binutils to be able to strip object files" + ewarn + ewarn "Alternatively llvm-strip can be used, it supports stripping any target" + ewarn "define STRIP=\"llvm-strip\" to use it (experimental)" + ewarn + fi + done + fi # I_KNOW_WHAT_I_AM_DOING_CROSS + + einfo "Rust configured with the following flags:" + echo + echo RUSTFLAGS="\"${RUSTFLAGS}\"" + echo RUSTFLAGS_BOOTSTRAP="\"${RUSTFLAGS_BOOTSTRAP}\"" + echo RUSTFLAGS_NOT_BOOTSTRAP="\"${RUSTFLAGS_NOT_BOOTSTRAP}\"" + echo MAGIC_EXTRA_RUSTFLAGS="\"${MAGIC_EXTRA_RUSTFLAGS}\"" + env | grep "CARGO_TARGET_.*_RUSTFLAGS=" + env | grep "CFLAGS_.*" + echo + einfo "bootstrap.toml contents:" + cat "${S}"/bootstrap.toml || die + echo +} + +src_compile() { + # -v will show invocations, -vv "very verbose" is overkill, -vvv "very very verbose" is insane + RUST_BACKTRACE=1 "${EPYTHON}" ./x.py build -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die +} + +src_test() { + # https://rustc-dev-guide.rust-lang.org/tests/intro.html + + # those are basic and codegen tests. + local tests=( + codegen + codegen-units + compile-fail + incremental + mir-opt + pretty + run-make + ) + + # fails if llvm is not built with ALL targets. + # and known to fail with system llvm sometimes. + use system-llvm || tests+=( assembly ) + + # fragile/expensive/less important tests + # or tests that require extra builds + # TODO: instead of skipping, just make some nonfatal. + if [[ ${ERUST_RUN_EXTRA_TESTS:-no} != no ]]; then + tests+=( + rustdoc + rustdoc-js + rustdoc-js-std + rustdoc-ui + run-make-fulldeps + ui + ui-fulldeps + ) + fi + + local i failed=() + einfo "rust_src_test: enabled tests ${tests[@]/#/src/test/}" + for i in "${tests[@]}"; do + local t="src/test/${i}" + einfo "rust_src_test: running ${t}" + if ! RUST_BACKTRACE=1 "${EPYTHON}" ./x.py test -vv --config="${S}"/bootstrap.toml \ + -j$(makeopts_jobs) --no-doc --no-fail-fast "${t}" + then + failed+=( "${t}" ) + eerror "rust_src_test: ${t} failed" + fi + done + + if [[ ${#failed[@]} -ne 0 ]]; then + eerror "rust_src_test: failure summary: ${failed[@]}" + die "aborting due to test failures" + fi +} + +src_install() { + DESTDIR="${D}" "${EPYTHON}" ./x.py install -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die + + docompress /usr/lib/${PN}/${SLOT}/share/man/ + + # bug #689562, #689160 + rm -v "${ED}/usr/lib/${PN}/${SLOT}/etc/bash_completion.d/cargo" || die + rmdir -v "${ED}/usr/lib/${PN}/${SLOT}"/etc{/bash_completion.d,} || die + + local symlinks=( + cargo + rustc + rustdoc + rust-gdb + rust-gdbgui + rust-lldb + ) + + use clippy && symlinks+=( clippy-driver cargo-clippy ) + if [[ ${PV} = *9999* ]]; then + use miri && symlinks+=( miri cargo-miri ) + fi + use rustfmt && symlinks+=( rustfmt cargo-fmt ) + use rust-analyzer && symlinks+=( rust-analyzer ) + + einfo "installing eselect-rust symlinks and paths: ${symlinks[@]}" + local i + for i in "${symlinks[@]}"; do + # we need realpath on /usr/bin/* symlink return version-appended binary path. + # so /usr/bin/rustc should point to /usr/lib/rust/<ver>/bin/rustc-<ver> + # need to fix eselect-rust to remove this hack. + local ver_i="${i}-${PV%%_*}" + if [[ -f "${ED}/usr/lib/${PN}/${SLOT}/bin/${i}" ]]; then + einfo "Installing ${i} symlink" + ln -v "${ED}/usr/lib/${PN}/${SLOT}/bin/${i}" "${ED}/usr/lib/${PN}/${SLOT}/bin/${ver_i}" || die + else + ewarn "${i} symlink requested, but source file not found" + ewarn "please report this" + fi + dosym "../lib/${PN}/${SLOT}/bin/${ver_i}" "/usr/bin/${ver_i}" + done + + # symlinks to switch components to active rust in eselect + dosym "${SLOT}/lib" "/usr/lib/${PN}/lib-${SLOT}" + use rust-analyzer && dosym "${SLOT}/libexec" "/usr/lib/${PN}/libexec-${SLOT}" + dosym "${SLOT}/share/man" "/usr/lib/${PN}/man-${SLOT}" + dosym "rust/${SLOT}/lib/rustlib" "/usr/lib/rustlib-${SLOT}" + dosym "../../lib/${PN}/${SLOT}/share/doc/rust" "/usr/share/doc/${P}" + + newenvd - "50${P}" <<-_EOF_ + MANPATH="${EPREFIX}/usr/lib/rust/man-${SLOT}" + _EOF_ + + rm -rf "${ED}/usr/lib/${PN}/${SLOT}"/*.old || die + rm -rf "${ED}/usr/lib/${PN}/${SLOT}/bin"/*.old || die + rm -rf "${ED}/usr/lib/${PN}/${SLOT}/doc"/*.old || die + + # note: eselect-rust adds EROOT to all paths below + cat <<-_EOF_ > "${T}/provider-${PN}-${SLOT}" + /usr/bin/cargo + /usr/bin/rustdoc + /usr/bin/rust-gdb + /usr/bin/rust-gdbgui + /usr/bin/rust-lldb + /usr/lib/rustlib + /usr/lib/rust/lib + /usr/lib/rust/man + /usr/share/doc/rust + _EOF_ + + if use clippy; then + echo /usr/bin/clippy-driver >> "${T}/provider-${P}" + echo /usr/bin/cargo-clippy >> "${T}/provider-${P}" + fi + if [[ ${SLOT} == *9999* ]] && use miri; then + echo /usr/bin/miri >> "${T}/provider-${P}" + echo /usr/bin/cargo-miri >> "${T}/provider-${P}" + fi + if use rustfmt; then + echo /usr/bin/rustfmt >> "${T}/provider-${P}" + echo /usr/bin/cargo-fmt >> "${T}/provider-${P}" + fi + if use rust-analyzer; then + echo /usr/lib/rust/libexec >> "${T}/provider-${P}" + echo /usr/bin/rust-analyzer >> "${T}/provider-${P}" + fi + + insinto /etc/env.d/rust + doins "${T}/provider-${PN}-${SLOT}" + + if use dist; then + "${EPYTHON}" ./x.py dist -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die + insinto "/usr/lib/${PN}/${SLOT}/dist" + doins -r "${S}/build/dist/." + fi +} + +pkg_postinst() { + + eselect rust update + + if has_version dev-debug/gdb || has_version llvm-core/lldb; then + elog "Rust installs helper scripts for calling GDB and LLDB," + elog "for convenience they are installed under /usr/bin/rust-{gdb,lldb}-${PV}." + fi + + if has_version app-editors/emacs; then + optfeature "emacs support for rust" app-emacs/rust-mode + fi + + if has_version app-editors/gvim || has_version app-editors/vim; then + optfeature "vim support for rust" app-vim/rust-vim + fi +} + +pkg_postrm() { + eselect rust cleanup +} diff --git a/dev-lang/rust/rust-1.89.0-r990.ebuild b/dev-lang/rust/rust-1.89.0-r990.ebuild new file mode 100644 index 0000000..687f2e2 --- /dev/null +++ b/dev-lang/rust/rust-1.89.0-r990.ebuild @@ -0,0 +1,839 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LLVM_COMPAT=( 20 ) +PYTHON_COMPAT=( python3_{11..14} ) + +RUST_PATCH_VER="1.89.0" + +RUST_MAX_VER=${PV%%_*} +if [[ ${PV} == *9999* ]]; then + RUST_MIN_VER="1.88.0" # Update this as new `beta` releases come out. +elif [[ ${PV} == *beta* ]]; then + RUST_MAX_VER="$(ver_cut 1).$(ver_cut 2).0" + RUST_MIN_VER="$(ver_cut 1).$(($(ver_cut 2) - 1)).0" +else + RUST_MIN_VER="$(ver_cut 1).$(($(ver_cut 2) - 1)).0" +fi + +inherit check-reqs estack flag-o-matic llvm-r1 multiprocessing optfeature \ + multilib multilib-build python-any-r1 rust rust-toolchain toolchain-funcs verify-sig + +if [[ ${PV} = *9999* ]]; then + inherit git-r3 +elif [[ ${PV} == *beta* ]]; then + # Identify the snapshot date of the beta release: + # curl -Ls static.rust-lang.org/dist/channel-rust-beta.toml | grep beta-src.tar.xz + betaver=${PV//*beta} + BETA_SNAPSHOT="${betaver:0:4}-${betaver:4:2}-${betaver:6:2}" + MY_P="rustc-beta" + SRC_URI="https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz -> rustc-${PV}-src.tar.xz + https://gitweb.gentoo.org/proj/rust-patches.git/snapshot/rust-patches-${RUST_PATCH_VER}.tar.bz2 + verify-sig? ( https://static.rust-lang.org/dist/${BETA_SNAPSHOT}/rustc-beta-src.tar.xz.asc + -> rustc-${PV}-src.tar.xz.asc ) + " + S="${WORKDIR}/${MY_P}-src" +else + MY_P="rustc-${PV}" + SRC_URI="https://static.rust-lang.org/dist/${MY_P}-src.tar.xz + https://gitweb.gentoo.org/proj/rust-patches.git/snapshot/rust-patches-${RUST_PATCH_VER}.tar.bz2 + verify-sig? ( https://static.rust-lang.org/dist/${MY_P}-src.tar.xz.asc ) + " + S="${WORKDIR}/${MY_P}-src" + KEYWORDS="~amd64 ~arm ~arm64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86" +fi + +DESCRIPTION="Systems programming language originally developed by Mozilla" +HOMEPAGE="https://www.rust-lang.org/" + +# keep in sync with llvm ebuild of the same version as bundled one. +ALL_LLVM_TARGETS=( AArch64 AMDGPU ARC ARM AVR BPF CSKY DirectX Hexagon Lanai + LoongArch M68k Mips MSP430 NVPTX PowerPC RISCV Sparc SPIRV SystemZ VE + WebAssembly X86 XCore Xtensa ) +ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) +LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/(-)?} + +# https://github.com/rust-lang/llvm-project/blob/rustc-1.84.0/llvm/CMakeLists.txt +_ALL_RUST_EXPERIMENTAL_TARGETS=( ARC CSKY DirectX M68k SPIRV Xtensa ) +declare -A ALL_RUST_EXPERIMENTAL_TARGETS +for _x in "${_ALL_RUST_EXPERIMENTAL_TARGETS[@]}"; do + ALL_RUST_EXPERIMENTAL_TARGETS["llvm_targets_${_x}"]=0 +done + +LICENSE="|| ( MIT Apache-2.0 ) BSD BSD-1 BSD-2 BSD-4" +SLOT="${PV%%_*}" # Beta releases get to share the same SLOT as the eventual stable + +IUSE="big-endian clippy cpu_flags_x86_sse2 debug dist doc llvm-libunwind lto rustfmt rust-analyzer rust-src +system-llvm test wasm ${ALL_LLVM_TARGETS[*]}" + +if [[ ${PV} = *9999* ]]; then + # These USE flags require nightly rust + IUSE+=" miri" +fi +IUSE+=" nightly" + +LLVM_DEPEND=() +# splitting usedeps needed to avoid CI/pkgcheck's UncheckableDep limitation +for _x in "${ALL_LLVM_TARGETS[@]}"; do + LLVM_DEPEND+=( " ${_x}? ( $(llvm_gen_dep "llvm-core/llvm:\${LLVM_SLOT}[${_x}=]") )" ) + if [[ -v ALL_RUST_EXPERIMENTAL_TARGETS["${_x}"] ]] ; then + ALL_RUST_EXPERIMENTAL_TARGETS["${_x}"]=1 + fi +done +LLVM_DEPEND+=( " wasm? ( $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') )" ) +LLVM_DEPEND+=( " $(llvm_gen_dep 'llvm-core/llvm:${LLVM_SLOT}')" ) + +# dev-libs/oniguruma is used for documentation +BDEPEND="${PYTHON_DEPS} + app-eselect/eselect-rust + dev-libs/oniguruma + || ( + >=sys-devel/gcc-4.7[cxx] + >=llvm-core/clang-3.5 + ) + lto? ( system-llvm? ( + || ( + $(llvm_gen_dep 'llvm-core/lld:${LLVM_SLOT}') + sys-devel/mold + ) + ) ) + !system-llvm? ( + >=dev-build/cmake-3.13.4 + app-alternatives/ninja + ) + test? ( dev-debug/gdb ) + verify-sig? ( sec-keys/openpgp-keys-rust ) +" + +DEPEND=" + >=app-arch/xz-utils-5.2 + net-misc/curl:=[http2,ssl] + sys-libs/zlib:= + dev-libs/openssl:0= + system-llvm? ( + ${LLVM_DEPEND[*]} + llvm-libunwind? ( llvm-runtimes/libunwind:= ) + ) + !system-llvm? ( + !llvm-libunwind? ( + elibc_musl? ( sys-libs/libunwind:= ) + ) + ) +" + +RDEPEND="${DEPEND} + app-eselect/eselect-rust + dev-lang/rust-common + sys-apps/lsb-release + !dev-lang/rust:stable + !dev-lang/rust-bin:stable +" + +REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} ) + rust-analyzer? ( rust-src ) + test? ( ${ALL_LLVM_TARGETS[*]} ) + wasm? ( llvm_targets_WebAssembly ) + x86? ( cpu_flags_x86_sse2 ) +" + +# we don't use cmake.eclass, but can get a warning +CMAKE_WARN_UNUSED_CLI=no + +QA_FLAGS_IGNORED=" + usr/lib/${PN}/${SLOT}/bin/.* + usr/lib/${PN}/${SLOT}/libexec/.* + usr/lib/${PN}/${SLOT}/lib/lib.*.so + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/bin/.* + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/lib.*.so +" + +QA_SONAME=" + usr/lib/${PN}/${SLOT}/lib/lib.*.so.* + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/lib.*.so +" + +QA_PRESTRIPPED=" + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/bin/rust-llvm-dwp + usr/lib/${PN}/${SLOT}/lib/rustlib/.*/lib/self-contained/crtn.o +" + +# An rmeta file is custom binary format that contains the metadata for the crate. +# rmeta files do not support linking, since they do not contain compiled object files. +# so we can safely silence the warning for this QA check. +QA_EXECSTACK="usr/lib/${PN}/${SLOT}/lib/rustlib/*/lib*.rlib:lib.rmeta" + +# causes double bootstrap +RESTRICT="test" + +VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/rust.asc + +clear_vendor_checksums() { + sed -i 's/\("files":{\)[^}]*/\1/' "vendor/${1}/.cargo-checksum.json" || die +} + +toml_usex() { + usex "${1}" true false +} + +pre_build_checks() { + local M=9216 + # multiply requirements by 1.3 if we are doing x86-multilib + if use amd64; then + M=$(( $(usex abi_x86_32 13 10) * ${M} / 10 )) + fi + M=$(( $(usex clippy 128 0) + ${M} )) + if [[ ${PV} == *9999* ]]; then + M=$(( $(usex miri 128 0) + ${M} )) + fi + M=$(( $(usex rustfmt 256 0) + ${M} )) + # add 2G if we compile llvm and 256M per llvm_target + if ! use system-llvm; then + M=$(( 2048 + ${M} )) + local ltarget + for ltarget in ${ALL_LLVM_TARGETS[@]}; do + M=$(( $(usex ${ltarget} 256 0) + ${M} )) + done + fi + M=$(( $(usex wasm 256 0) + ${M} )) + M=$(( $(usex debug 2 1) * ${M} )) + eshopts_push -s extglob + if is-flagq '-g?(gdb)?([1-9])'; then + M=$(( 15 * ${M} / 10 )) + fi + eshopts_pop + M=$(( $(usex doc 256 0) + ${M} )) + CHECKREQS_DISK_BUILD=${M}M check-reqs_pkg_${EBUILD_PHASE} +} + +llvm_check_deps() { + has_version -r "llvm-core/llvm:${LLVM_SLOT}[${LLVM_TARGET_USEDEPS// /,}]" +} + +# Is LLVM being linked against libc++? +is_libcxx_linked() { + local code='#include <ciso646> +#if defined(_LIBCPP_VERSION) + HAVE_LIBCXX +#endif +' + local out=$($(tc-getCXX) ${CXXFLAGS} ${CPPFLAGS} -x c++ -E -P - <<<"${code}") || return 1 + [[ ${out} == *HAVE_LIBCXX* ]] +} + +pkg_pretend() { + pre_build_checks +} + +pkg_setup() { + pre_build_checks + python-any-r1_pkg_setup + + export LIBGIT2_NO_PKG_CONFIG=1 #749381 + if tc-is-cross-compiler; then + use system-llvm && die "USE=system-llvm not allowed when cross-compiling" + local cross_llvm_target="$(llvm_tuple_to_target "${CBUILD}")" + use "llvm_targets_${cross_llvm_target}" || \ + die "Must enable LLVM_TARGETS=${cross_llvm_target} matching CBUILD=${CBUILD} when cross-compiling" + fi + + rust_pkg_setup + + if use system-llvm; then + llvm-r1_pkg_setup + + local llvm_config="$(get_llvm_prefix)/bin/llvm-config" + export LLVM_LINK_SHARED=1 + export RUSTFLAGS="${RUSTFLAGS} -Lnative=$("${llvm_config}" --libdir)" + fi +} + +rust_live_get_sources() { + EGIT_REPO_URI=" + https://anongit.gentoo.org/git/proj/rust-patches.git + " + EGIT_CHECKOUT_DIR="${WORKDIR}/rust-patches-${RUST_PATCH_VER}" + git-r3_src_unpack + + EGIT_REPO_URI=" + https://github.com/rust-lang/rust.git + " + EGIT_SUBMODULES=( + "*" + "-src/gcc" + ) + S="${WORKDIR}/rust" + EGIT_CHECKOUT_DIR="${S}" + git-r3_src_unpack +} + +src_unpack() { + if [[ ${PV} == *9999* ]] ; then + rust_live_get_sources + + # Vendor dependencies + mkdir "${S}/.cargo" || die # The vendor script has a check for .cargo/config{,.toml} + touch "${S}/.cargo/bootstrap.toml" || die + local rust_stage0_root="$(${RUSTC} --print sysroot || die "Can't determine rust's sysroot")" + # Configure vendor to use the portage-provided toolchain. This prevents it from + # attempting to fetch a `beta` toolchain from the internet. + cat <<- _EOF_ > "${T}/vendor-bootstrap.toml" + # Suppresses a warning about tracking changes which we don't care about. + change-id = "ignore" + [build] + build = "$(rust_abi "${CBUILD}")" + host = ["$(rust_abi "${CHOST}")"] + target = ["$(rust_abi "${CHOST}")"] + cargo = "${rust_stage0_root}/bin/cargo" + rustc = "${rust_stage0_root}/bin/rustc" + rustfmt = "${rust_stage0_root}/bin/rustfmt" + _EOF_ + # We're using git sources so we need to run the Vendor script + # to ensure that all dependencies are present and up-to-date + mkdir "${S}/vendor" || die + # This also compiles the 'build helper', there's no way to avoid this. + ${EPYTHON} "${S}"/x.py vendor -v --config="${T}"/vendor-bootstrap.toml -j$(makeopts_jobs) || + die "Failed to vendor dependencies" + # TODO: This has to be generated somehow, this is from a 1.84.x tarball I had lying around. + cat <<- _EOF_ > "${S}/.cargo/config.toml" + [source.crates-io] + replace-with = "vendored-sources" + + [source."git+https://github.com/rust-lang/team"] + git = "https://github.com/rust-lang/team" + replace-with = "vendored-sources" + + [source.vendored-sources] + directory = "vendor" + _EOF_ + elif use verify-sig ; then + # Patch tarballs are not signed (but we trust Gentoo infra) + verify-sig_verify_detached "${DISTDIR}"/rustc-${PV}-src.tar.xz{,.asc} + default + else + default + fi +} + +src_prepare() { + if [[ ${PV} = *9999* ]]; then + # We need to update / generate lockfiles for the workspace + ${CARGO} generate-lockfile --offline || die "Failed to generate lockfiles" + fi + + # Commit patches to the appropriate branch in proj/rust-patches.git + # then cut a new tag / tarball. Don't add patches to ${FILESDIR} + PATCHES=( + "${WORKDIR}/rust-patches-${RUST_PATCH_VER}/" + ) + + if use lto && tc-is-clang && ! tc-ld-is-lld && ! tc-ld-is-mold; then + export RUSTFLAGS+=" -C link-arg=-fuse-ld=lld" + fi + + default +} + +src_configure() { + if tc-is-cross-compiler; then + export PKG_CONFIG_ALLOW_CROSS=1 + export PKG_CONFIG_PATH="${ESYSROOT}/usr/$(get_libdir)/pkgconfig" + export OPENSSL_INCLUDE_DIR="${ESYSROOT}/usr/include" + export OPENSSL_LIB_DIR="${ESYSROOT}/usr/$(get_libdir)" + fi + + # Avoid bundled copies of libraries + export RUSTONIG_SYSTEM_LIBONIG=1 + # Need to check if these can be optional + #export LIBSQLITE3_SYS_USE_PKG_CONFIG=1 + #export LIBSSH2_SYS_USE_PKG_CONFIG=1 + + filter-lto # https://bugs.gentoo.org/862109 https://bugs.gentoo.org/866231 + + local rust_target="" rust_targets="" arch_cflags + + # Collect rust target names to compile standard libs for all ABIs. + for v in $(multilib_get_enabled_abi_pairs); do + rust_targets+=",\"$(rust_abi $(get_abi_CHOST ${v##*.}))\"" + done + if use wasm; then + rust_targets+=",\"wasm32-unknown-unknown\"" + if use system-llvm; then + # un-hardcode rust-lld linker for this target + # https://bugs.gentoo.org/715348 + sed -i '/linker:/ s/rust-lld/wasm-ld/' compiler/rustc_target/src/spec/base/wasm.rs || die + fi + fi + rust_targets="${rust_targets#,}" + + # cargo and rustdoc are mandatory and should always be included + local tools='"cargo","rustdoc"' + use clippy && tools+=',"clippy"' + use rustfmt && tools+=',"rustfmt"' + use rust-analyzer && tools+=',"rust-analyzer","rust-analyzer-proc-macro-srv"' + use rust-src && tools+=',"src"' + + if [[ ${PV} == *9999* ]]; then + use miri && tools+=',"miri"' + fi + + local rust_stage0_root="$(${RUSTC} --print sysroot || die "Can't determine rust's sysroot")" + # in case of prefix it will be already prefixed, as --print sysroot returns full path + [[ -d ${rust_stage0_root} ]] || die "${rust_stage0_root} is not a directory" + + rust_target="$(rust_abi)" + rust_build="$(rust_abi "${CBUILD}")" + rust_host="$(rust_abi "${CHOST}")" + + RUST_EXPERIMENTAL_TARGETS=() + for _x in "${!ALL_RUST_EXPERIMENTAL_TARGETS[@]}"; do + if [[ ${ALL_RUST_EXPERIMENTAL_TARGETS[${_x}]} == 1 ]] && use ${_x} ; then + RUST_EXPERIMENTAL_TARGETS+=( ${_x#llvm_targets_} ) + fi + done + RUST_EXPERIMENTAL_TARGETS=${RUST_EXPERIMENTAL_TARGETS[@]} + + local cm_btype="$(usex debug DEBUG RELEASE)" + local build_channel + local build_miri="false" + case "${PV}" in + *9999*) + build_channel="nightly" + ;; + *beta*) + build_channel="beta" + ;; + *) + build_channel="stable" + ;; + esac + use nightly && build_channel="nightly" + cat <<- _EOF_ > "${S}"/bootstrap.toml + # Suppresses a warning about tracking changes which we don't care about. + change-id = "ignore" + # https://github.com/rust-lang/rust/issues/135358 (bug #947897) + profile = "dist" + [llvm] + download-ci-llvm = false + optimize = $(toml_usex !debug) + release-debuginfo = $(toml_usex debug) + assertions = $(toml_usex debug) + ninja = true + targets = "${LLVM_TARGETS// /;}" + experimental-targets = "${RUST_EXPERIMENTAL_TARGETS// /;}" + link-shared = $(toml_usex system-llvm) + $(if is_libcxx_linked; then + # https://bugs.gentoo.org/732632 + echo "use-libcxx = true" + echo "static-libstdcpp = false" + fi) + $(case "${rust_target}" in + i586-*-linux-*) + # https://github.com/rust-lang/rust/issues/93059 + echo 'cflags = "-fcf-protection=none"' + echo 'cxxflags = "-fcf-protection=none"' + echo 'ldflags = "-fcf-protection=none"' + ;; + *) + ;; + esac) + enable-warnings = false + [llvm.build-config] + CMAKE_VERBOSE_MAKEFILE = "ON" + $(if ! tc-is-cross-compiler; then + # When cross-compiling, LLVM is compiled twice, once for host and + # once for target. Unfortunately, this build configuration applies + # to both, which means any flags applicable to one target but not + # the other will break. Conditionally disable respecting user + # flags when cross-compiling. + echo "CMAKE_C_FLAGS_${cm_btype} = \"${CFLAGS}\"" + echo "CMAKE_CXX_FLAGS_${cm_btype} = \"${CXXFLAGS}\"" + echo "CMAKE_EXE_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\"" + echo "CMAKE_MODULE_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\"" + echo "CMAKE_SHARED_LINKER_FLAGS_${cm_btype} = \"${LDFLAGS}\"" + echo "CMAKE_STATIC_LINKER_FLAGS_${cm_btype} = \"${ARFLAGS}\"" + fi) + [build] + build-stage = 2 + test-stage = 2 + build = "${rust_build}" + host = ["${rust_host}"] + target = [${rust_targets}] + cargo = "${rust_stage0_root}/bin/cargo" + rustc = "${rust_stage0_root}/bin/rustc" + rustfmt = "${rust_stage0_root}/bin/rustfmt" + description = "gentoo" + docs = $(toml_usex doc) + compiler-docs = false + submodules = false + python = "${EPYTHON}" + locked-deps = true + vendor = true + extended = true + tools = [${tools}] + verbose = 2 + sanitizers = false + profiler = true + cargo-native-static = false + [install] + prefix = "${EPREFIX}/usr/lib/${PN}/${SLOT}" + sysconfdir = "etc" + docdir = "share/doc/rust" + bindir = "bin" + libdir = "lib" + mandir = "share/man" + [rust] + # https://github.com/rust-lang/rust/issues/54872 + codegen-units-std = 1 + optimize = true + debug = $(toml_usex debug) + debug-assertions = $(toml_usex debug) + debug-assertions-std = $(toml_usex debug) + debuginfo-level = $(usex debug 2 0) + debuginfo-level-rustc = $(usex debug 2 0) + debuginfo-level-std = $(usex debug 2 0) + debuginfo-level-tools = $(usex debug 2 0) + debuginfo-level-tests = 0 + backtrace = true + incremental = false + $(if ! tc-is-cross-compiler; then + echo "default-linker = \"${CHOST}-cc\"" + fi) + channel = "${build_channel}" + rpath = true + verbose-tests = true + optimize-tests = $(toml_usex !debug) + codegen-tests = true + omit-git-hash = false + dist-src = false + remap-debuginfo = true + lld = $(usex system-llvm false $(toml_usex wasm)) + $(if use lto && tc-is-clang && ! tc-ld-is-mold; then + echo "use-lld = true" + fi) + # only deny warnings if doc+wasm are NOT requested, documenting stage0 wasm std fails without it + # https://github.com/rust-lang/rust/issues/74976 + # https://github.com/rust-lang/rust/issues/76526 + deny-warnings = $(usex wasm $(usex doc false true) true) + backtrace-on-ice = true + jemalloc = false + # See https://github.com/rust-lang/rust/issues/121124 + lto = "$(usex lto thin off)" + [dist] + src-tarball = false + compression-formats = ["xz"] + compression-profile = "balanced" + _EOF_ + + for v in $(multilib_get_enabled_abi_pairs); do + rust_target=$(rust_abi $(get_abi_CHOST ${v##*.})) + arch_cflags="$(get_abi_CFLAGS ${v##*.})" + + export CFLAGS_${rust_target//-/_}="${arch_cflags}" + + cat <<- _EOF_ >> "${S}"/bootstrap.toml + [target.${rust_target}] + ar = "$(tc-getAR)" + cc = "$(tc-getCC)" + cxx = "$(tc-getCXX)" + linker = "$(tc-getCC)" + ranlib = "$(tc-getRANLIB)" + llvm-libunwind = "$(usex llvm-libunwind $(usex system-llvm system in-tree) no)" + _EOF_ + if use system-llvm; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + llvm-config = "$(get_llvm_prefix)/bin/llvm-config" + _EOF_ + fi + # by default librustc_target/spec/linux_musl_base.rs sets base.crt_static_default = true; + # but we patch it and set to false here as well + if use elibc_musl; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + crt-static = false + musl-root = "$($(tc-getCC) -print-sysroot)/usr" + _EOF_ + fi + done + if use wasm; then + wasm_target="wasm32-unknown-unknown" + export CFLAGS_${wasm_target//-/_}="$(filter-flags '-mcpu*' '-march*' '-mtune*'; echo "$CFLAGS")" + cat <<- _EOF_ >> "${S}"/bootstrap.toml + [target.wasm32-unknown-unknown] + linker = "$(usex system-llvm lld rust-lld)" + # wasm target does not have profiler_builtins https://bugs.gentoo.org/848483 + profiler = false + _EOF_ + fi + + if [[ -n ${I_KNOW_WHAT_I_AM_DOING_CROSS} ]]; then # whitespace intentionally shifted below + # experimental cross support + # discussion: https://bugs.gentoo.org/679878 + # TODO: c*flags, clang, system-llvm, cargo.eclass target support + # it would be much better if we could split out stdlib + # complilation to separate ebuild and abuse CATEGORY to + # just install to /usr/lib/rustlib/<target> + + # extra targets defined as a bash array + # spec format: <LLVM target>:<rust-target>:<CTARGET> + # best place would be /etc/portage/env/dev-lang/rust + # Example: + # RUST_CROSS_TARGETS=( + # "AArch64:aarch64-unknown-linux-gnu:aarch64-unknown-linux-gnu" + # ) + # no extra hand holding is done, no target transformations, all + # values are passed as-is with just basic checks, so it's up to user to supply correct values + # valid rust targets can be obtained with + # rustc --print target-list + # matching cross toolchain has to be installed + # matching LLVM_TARGET has to be enabled for both rust and llvm (if using system one) + # only gcc toolchains installed with crossdev are checked for now. + + # BUG: we can't pass host flags to cross compiler, so just filter for now + # BUG: this should be more fine-grained. + filter-flags '-mcpu=*' '-march=*' '-mtune=*' + + local cross_target_spec + for cross_target_spec in "${RUST_CROSS_TARGETS[@]}";do + # extracts first element form <LLVM target>:<rust-target>:<CTARGET> + local cross_llvm_target="${cross_target_spec%%:*}" + # extracts toolchain triples, <rust-target>:<CTARGET> + local cross_triples="${cross_target_spec#*:}" + # extracts first element after before : separator + local cross_rust_target="${cross_triples%%:*}" + # extracts last element after : separator + local cross_toolchain="${cross_triples##*:}" + use llvm_targets_${cross_llvm_target} || die "need llvm_targets_${cross_llvm_target} target enabled" + command -v ${cross_toolchain}-gcc > /dev/null 2>&1 || die "need ${cross_toolchain} cross toolchain" + + cat <<- _EOF_ >> "${S}"/bootstrap.toml + [target.${cross_rust_target}] + ar = "${cross_toolchain}-ar" + cc = "${cross_toolchain}-gcc" + cxx = "${cross_toolchain}-g++" + linker = "${cross_toolchain}-gcc" + ranlib = "${cross_toolchain}-ranlib" + _EOF_ + if use system-llvm; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + llvm-config = "$(get_llvm_prefix)/bin/llvm-config" + _EOF_ + fi + if [[ "${cross_toolchain}" == *-musl* ]]; then + cat <<- _EOF_ >> "${S}"/bootstrap.toml + musl-root = "$(${cross_toolchain}-gcc -print-sysroot)/usr" + _EOF_ + fi + + # append cross target to "normal" target list + # example 'target = ["powerpc64le-unknown-linux-gnu"]' + # becomes 'target = ["powerpc64le-unknown-linux-gnu","aarch64-unknown-linux-gnu"]' + + rust_targets="${rust_targets},\"${cross_rust_target}\"" + sed -i "/^target = \[/ s#\[.*\]#\[${rust_targets}\]#" bootstrap.toml || die + + ewarn + ewarn "Enabled ${cross_rust_target} rust target" + ewarn "Using ${cross_toolchain} cross toolchain" + ewarn + if ! has_version -b 'sys-devel/binutils[multitarget]' ; then + ewarn "'sys-devel/binutils[multitarget]' is not installed" + ewarn "'strip' will be unable to strip cross libraries" + ewarn "cross targets will be installed with full debug information" + ewarn "enable 'multitarget' USE flag for binutils to be able to strip object files" + ewarn + ewarn "Alternatively llvm-strip can be used, it supports stripping any target" + ewarn "define STRIP=\"llvm-strip\" to use it (experimental)" + ewarn + fi + done + fi # I_KNOW_WHAT_I_AM_DOING_CROSS + + einfo "Rust configured with the following flags:" + echo + echo RUSTFLAGS="\"${RUSTFLAGS}\"" + echo RUSTFLAGS_BOOTSTRAP="\"${RUSTFLAGS_BOOTSTRAP}\"" + echo RUSTFLAGS_NOT_BOOTSTRAP="\"${RUSTFLAGS_NOT_BOOTSTRAP}\"" + echo MAGIC_EXTRA_RUSTFLAGS="\"${MAGIC_EXTRA_RUSTFLAGS}\"" + env | grep "CARGO_TARGET_.*_RUSTFLAGS=" + env | grep "CFLAGS_.*" + echo + einfo "bootstrap.toml contents:" + cat "${S}"/bootstrap.toml || die + echo +} + +src_compile() { + # -v will show invocations, -vv "very verbose" is overkill, -vvv "very very verbose" is insane + RUST_BACKTRACE=1 "${EPYTHON}" ./x.py build -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die +} + +src_test() { + # https://rustc-dev-guide.rust-lang.org/tests/intro.html + + # those are basic and codegen tests. + local tests=( + codegen + codegen-units + compile-fail + incremental + mir-opt + pretty + run-make + ) + + # fails if llvm is not built with ALL targets. + # and known to fail with system llvm sometimes. + use system-llvm || tests+=( assembly ) + + # fragile/expensive/less important tests + # or tests that require extra builds + # TODO: instead of skipping, just make some nonfatal. + if [[ ${ERUST_RUN_EXTRA_TESTS:-no} != no ]]; then + tests+=( + rustdoc + rustdoc-js + rustdoc-js-std + rustdoc-ui + run-make-fulldeps + ui + ui-fulldeps + ) + fi + + local i failed=() + einfo "rust_src_test: enabled tests ${tests[@]/#/src/test/}" + for i in "${tests[@]}"; do + local t="src/test/${i}" + einfo "rust_src_test: running ${t}" + if ! RUST_BACKTRACE=1 "${EPYTHON}" ./x.py test -vv --config="${S}"/bootstrap.toml \ + -j$(makeopts_jobs) --no-doc --no-fail-fast "${t}" + then + failed+=( "${t}" ) + eerror "rust_src_test: ${t} failed" + fi + done + + if [[ ${#failed[@]} -ne 0 ]]; then + eerror "rust_src_test: failure summary: ${failed[@]}" + die "aborting due to test failures" + fi +} + +src_install() { + DESTDIR="${D}" "${EPYTHON}" ./x.py install -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die + + docompress /usr/lib/${PN}/${SLOT}/share/man/ + + # bug #689562, #689160 + rm -v "${ED}/usr/lib/${PN}/${SLOT}/etc/bash_completion.d/cargo" || die + rmdir -v "${ED}/usr/lib/${PN}/${SLOT}"/etc{/bash_completion.d,} || die + + local symlinks=( + cargo + rustc + rustdoc + rust-gdb + rust-gdbgui + rust-lldb + ) + + use clippy && symlinks+=( clippy-driver cargo-clippy ) + if [[ ${PV} = *9999* ]]; then + use miri && symlinks+=( miri cargo-miri ) + fi + use rustfmt && symlinks+=( rustfmt cargo-fmt ) + use rust-analyzer && symlinks+=( rust-analyzer ) + + einfo "installing eselect-rust symlinks and paths: ${symlinks[@]}" + local i + for i in "${symlinks[@]}"; do + # we need realpath on /usr/bin/* symlink return version-appended binary path. + # so /usr/bin/rustc should point to /usr/lib/rust/<ver>/bin/rustc-<ver> + # need to fix eselect-rust to remove this hack. + local ver_i="${i}-${PV%%_*}" + if [[ -f "${ED}/usr/lib/${PN}/${SLOT}/bin/${i}" ]]; then + einfo "Installing ${i} symlink" + ln -v "${ED}/usr/lib/${PN}/${SLOT}/bin/${i}" "${ED}/usr/lib/${PN}/${SLOT}/bin/${ver_i}" || die + else + ewarn "${i} symlink requested, but source file not found" + ewarn "please report this" + fi + dosym "../lib/${PN}/${SLOT}/bin/${ver_i}" "/usr/bin/${ver_i}" + done + + # symlinks to switch components to active rust in eselect + dosym "${SLOT}/lib" "/usr/lib/${PN}/lib-${SLOT}" + use rust-analyzer && dosym "${SLOT}/libexec" "/usr/lib/${PN}/libexec-${SLOT}" + dosym "${SLOT}/share/man" "/usr/lib/${PN}/man-${SLOT}" + dosym "rust/${SLOT}/lib/rustlib" "/usr/lib/rustlib-${SLOT}" + dosym "../../lib/${PN}/${SLOT}/share/doc/rust" "/usr/share/doc/${P}" + + newenvd - "50${P}" <<-_EOF_ + MANPATH="${EPREFIX}/usr/lib/rust/man-${SLOT}" + _EOF_ + + rm -rf "${ED}/usr/lib/${PN}/${SLOT}"/*.old || die + rm -rf "${ED}/usr/lib/${PN}/${SLOT}/bin"/*.old || die + rm -rf "${ED}/usr/lib/${PN}/${SLOT}/doc"/*.old || die + + # note: eselect-rust adds EROOT to all paths below + cat <<-_EOF_ > "${T}/provider-${PN}-${SLOT}" + /usr/bin/cargo + /usr/bin/rustdoc + /usr/bin/rust-gdb + /usr/bin/rust-gdbgui + /usr/bin/rust-lldb + /usr/lib/rustlib + /usr/lib/rust/lib + /usr/lib/rust/man + /usr/share/doc/rust + _EOF_ + + if use clippy; then + echo /usr/bin/clippy-driver >> "${T}/provider-${P}" + echo /usr/bin/cargo-clippy >> "${T}/provider-${P}" + fi + if [[ ${SLOT} == *9999* ]] && use miri; then + echo /usr/bin/miri >> "${T}/provider-${P}" + echo /usr/bin/cargo-miri >> "${T}/provider-${P}" + fi + if use rustfmt; then + echo /usr/bin/rustfmt >> "${T}/provider-${P}" + echo /usr/bin/cargo-fmt >> "${T}/provider-${P}" + fi + if use rust-analyzer; then + echo /usr/lib/rust/libexec >> "${T}/provider-${P}" + echo /usr/bin/rust-analyzer >> "${T}/provider-${P}" + fi + + insinto /etc/env.d/rust + doins "${T}/provider-${PN}-${SLOT}" + + if use dist; then + "${EPYTHON}" ./x.py dist -v --config="${S}"/bootstrap.toml -j$(makeopts_jobs) || die + insinto "/usr/lib/${PN}/${SLOT}/dist" + doins -r "${S}/build/dist/." + fi +} + +pkg_postinst() { + + eselect rust update + + if has_version dev-debug/gdb || has_version llvm-core/lldb; then + elog "Rust installs helper scripts for calling GDB and LLDB," + elog "for convenience they are installed under /usr/bin/rust-{gdb,lldb}-${PV}." + fi + + if has_version app-editors/emacs; then + optfeature "emacs support for rust" app-emacs/rust-mode + fi + + if has_version app-editors/gvim || has_version app-editors/vim; then + optfeature "vim support for rust" app-vim/rust-vim + fi +} + +pkg_postrm() { + eselect rust cleanup +} diff --git a/media-sound/pineapple-tracker-player/Manifest b/media-sound/pineapple-tracker-player/Manifest new file mode 100644 index 0000000..470039e --- /dev/null +++ b/media-sound/pineapple-tracker-player/Manifest @@ -0,0 +1,2 @@ +DIST pineapple-tracker-player-0.5.0.tar.gz 94917 BLAKE2B 8161e78527d6cde0ecb99714ea5e5add8b662eb95606a1c6defbed607cc4edc76c16c132da38164b94bccd8b046a08f1cd119b91ae2d3247380c9843ad5b330d SHA512 6ad5ccf4382b8a03f7c127819bb21325e9df14adeb9cb87906a7a331672db7f5a2f11e9813644d793f913b4ad3776f5134fd9bc8d0625c8377742e189c3020c7 +EBUILD pineapple-tracker-player-0.5.0.ebuild 797 BLAKE2B af5fba55fce8092ec72a2a9cfc249694506d2f0a9c3bc81c5079324dad50ef50b585b51af92cb515d4ec60d128ef5dd1ee47fd2e7bd410ffb0fd6f7fdcde77ec SHA512 41f81efbea06c138e57d1bac818d0284d8b0dbd8a7dcfe4759d81133725bc595ea05cabfadfb490bc4ffe6d18223b82bf5967d275e9ba6e58eeec8528e26b2c4 diff --git a/media-sound/pineapple-tracker-player/pineapple-tracker-player-0.5.0.ebuild b/media-sound/pineapple-tracker-player/pineapple-tracker-player-0.5.0.ebuild new file mode 100644 index 0000000..98f243c --- /dev/null +++ b/media-sound/pineapple-tracker-player/pineapple-tracker-player-0.5.0.ebuild @@ -0,0 +1,43 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake xdg + +DESCRIPTION="A libopenmpt based module music player" +HOMEPAGE="https://github.com/BLumia/pineapple-tracker-player" +SRC_URI=" + https://github.com/BLumia/pineapple-tracker-player/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz +" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64" +IUSE="" + +DEPEND=" + dev-qt/qtbase[dbus,gui,widgets] + dev-qt/qtdeclarative + media-libs/libopenmpt + media-libs/portaudio + virtual/pkgconfig +" + +BDEPEND=" + dev-qt/linguist-tools + kde-frameworks/extra-cmake-modules +" + +src_install() { + cmake_src_install + rm -f ${D}/usr/bin/pineapple-tracker-player-quick +} + +pkg_postinst() { + xdg_desktop_database_update +} + +pkg_postrm() { + xdg_desktop_database_update +} diff --git a/sys-block/thin-provisioning-tools/Manifest b/sys-block/thin-provisioning-tools/Manifest new file mode 100644 index 0000000..b262633 --- /dev/null +++ b/sys-block/thin-provisioning-tools/Manifest @@ -0,0 +1,113 @@ +AUX thin-provisioning-tools-1.0.10-stdsimd-fix.patch 472 BLAKE2B 470291a9af89984c7d64f81f72f7190e5590f62f6ff86ffd1cc3c8687b366c99b59332391a19935a07ec59ac7f77e34366a0d01cf674db99858555e5485fb8c4 SHA512 b287bd795ab366da44f05232e1bf8bdc9a2770c3ba0bf5779f96f2a9b3a5a23303e4a57f7a07973f20314afc5dec1537a1b0cc7a9dbfc4a6a810dce9259ff76e +AUX thin-provisioning-tools-1.0.6-build-with-cargo.patch 824 BLAKE2B d14adb08e8fde976072ddb23b71f4d20a097bbea9fc364e9a50656e8186166f6094a655ab3d3f402683790db17a22ab90a7969fbfcd56414fbaf7cf146d0b7d0 SHA512 73a5b3482170186d2527f76e57ee71c146f31997fd06925938c5b92f198ada258e7c763d14f2075a7130331697d1d254c50116b63d374b070fb3bb89139acff6 +DIST adler-1.0.2.crate 12778 BLAKE2B a1dc17786adae945ac09d3525e609ed944e6465690787bbb831a1b9d53793cba1989793d0a5606d5d23ee20d36457923d451b1b3530c9ec7072a487aa3e55bbd SHA512 7ab190d31890fc05b0b55d8e2c6527a505e06793d5496be0b3831e0513412f9ba97f8148f6f68ed0770fa9cd980a5092d885e058becf1d5506b7c74b82674aa1 +DIST aho-corasick-1.1.2.crate 183136 BLAKE2B 2d4306d8968061b9f7e50190be6a92b3f668169ba1b9f9691de08a57c96185f7a4288d20c64cb8488a260eb18d3ed4b0e8358b0cca47aa44759b2e448049cbaa SHA512 61ef5092673ab5a60bec4e92df28a91fe6171ba59d5829ffe41fc55aff3bfb755533a4ad53dc7bf827a0b789fcce593b17e69d1fcfb3694f06ed3b1bd535d40c +DIST anstyle-1.0.4.crate 13998 BLAKE2B fb501700855709e53438461c2f4b48d869613e7bb3bb700db8bd0d95082876d3782dc2cfe3ce110bb4a206994de56afe0e90fe89f9ccd07c60fe1c652123ba59 SHA512 671c6f57106198bcfc2f9000aacba98fabacfadfce2329dfe8d0e0a2af9404da483d7a844ca2b08e1fc0249371f574c13d0082c9f7a4ed90ff581308257a52d3 +DIST anyhow-1.0.79.crate 44931 BLAKE2B 9270f04c6fbbecb535e3081f4275c3df28f6a893c1dfc0a9f7c009994de2deb8ebced04fe5e6f62931b33c3707f4fbfb0c3b28da1a611b413d40d27149d1fd2f SHA512 ecd6fb1367d494df18c0e274b336a133f3acf7b6a5487d20bdd06e08c7f1f729877086a0966e998221daff120504fadd2be2dc4219ed621f81b0a50c2bbc2011 +DIST atty-0.2.14.crate 5470 BLAKE2B 2db856a9e898a430258f059aeaf7c844a153293e8856d90ac81f7d91a888c89198768ad5cb09303c23241fe85c560a55148fa56a303651a82b0edb895616bfab SHA512 d7b6c4b9a0f898d91ddbc41a5ee45bbf45d1d269508c8cc87ee3e3990500e41e0ec387afb1f3bc7db55bedac396dd86c6509f4bf9e5148d809c3802edcc5e1d9 +DIST autocfg-1.1.0.crate 13272 BLAKE2B 7724055c337d562103f191f4e36cab469e578f0c51cc24d33624dea155d108a07578703766341fd6a4cc1ef52acda406e7dba1650d59115f18261281e5b40203 SHA512 df972c09abbdc0b6cb6bb55b1e29c7fed706ece38a62613d9e275bac46a19574a7f96f0152cccb0239efea04ee90083a146b58b15307696c4c81878cd12de28f +DIST base64-0.21.7.crate 82576 BLAKE2B 25cc8761c14220981ff4ed332058f6179948080cbfa2b225ec1d1602e4af14cd470c969e8b7049117e6fc51a5a24e06b1d27bab844486ecb76409d12e0581d5d SHA512 c6986d88dd9aa081d914f35b4174be4ba874848657ac4b5e63b9b45af765d973289c548ccb5a01584edfc0d8d79ff5be25b51365295d6e7a311bd7f0ae3c0cb9 +DIST bitflags-1.3.2.crate 23021 BLAKE2B eb990bb27b2bdeb66fd7212ce582cb36e1c616debbac85df642d0c82b25439e6bf9b1e811fac76b59e58ea3c1bbea6170d03a61e8f9a395e4334a0e2e2987eda SHA512 3c698f757b5cc62f815f9a1cce365c3d2dd88e4db71f331dff8bba86c2865f755b81cb4c9bfc59bd86b7643b0943f9e09a7c4f8ad75eb2ab0e714803d0129f62 +DIST bitflags-2.4.1.crate 37043 BLAKE2B f61c45b142265e9c2944c7054e01704de47510735e9ee5351cd02b98676cc4eb42d68b1fc4849ad5f54654617a74f20cb533b4207c2fe76516b724ba9318b414 SHA512 d3fd7abc95acc1cb5bf16d6acc12dbb8eadd250f069268df13c2e8dc3d5f5c15a929cd17ca931c77393b64dce0516ef8674c469789ed32d78e315b5faada062b +DIST bytemuck-1.14.0.crate 44933 BLAKE2B afd34f2becc41484e7bf71fb4a9f0925870a4f2d9d59daff9e91bada000462baeced4314e469a508d4413a8f2442d83a5f3082193653403fbee1340ab5c3f6c5 SHA512 f072a97e5de93228435bb362363ac1af0738b7927832b02a837f44eb21b0b089589b61e73004a06c5e4d4601e66bb42e67b9f707bbf13429a40b6250a0f05ae5 +DIST byteorder-1.5.0.crate 23288 BLAKE2B 7f85a7948406844070a2c8202e0bd52f73b3dfc7c666a97046128044eb9352195afb80e2bf894c0742ad109e4473339de1365d09591de70dfec6c8c02a8e1453 SHA512 96caf981177f6ded9f27f025922cb94eb0cd9de5303bd91680099912d922092e77b7361efa70011e84f1595e443193e4f1b354443b9980c123f6ae573b236f7f +DIST cassowary-0.3.0.crate 22876 BLAKE2B 7e74a08e02050548ade7dd1ebba7ce4e4360d258ea6acf126453889dbf16df433bed7b68789736881c957f4c09eead1f763a0c02f2474157b1650a1e77e6eca9 SHA512 0838c0b79ed31f0c514fe4ac82633976e34b0d6cb08616313cda0e00623514fc6498c6c308cfef54ea029f1fdbaafe2991ca8ac3c38437a113ac62e37f9397f8 +DIST cfg-if-1.0.0.crate 7934 BLAKE2B e99a5589c11d79d77a4537b34ce0a45d37b981c123b79b807cea836c89fc3926d693458893baca2882448d3d44e3f64e06141f6d916b748daa10b8cc1ae16d1b SHA512 0fb16a8882fd30e86b62c5143b1cb18ab564e84e75bd1f28fd12f24ffdc4a42e0d2e012a99abb606c12efe3c11061ff5bf8e24ab053e550ae083f7d90f6576ff +DIST clap-4.4.16.crate 55534 BLAKE2B 6d0b65f2c0ca0b8ad023abdaafcf2de397443188f0774c8b6ef6704231a81136476fdf41272e810ccf2a9af68b945c4346dc78c4e10467502527ecbaecb3ac76 SHA512 d3cb37f54bc424220d91c6cd5a3fb04cf116db55c7371356484e52483abb289970f6a0948eda32d54e2dc47c666c533c0e2f3391f47f439f5b73a68fd0b38064 +DIST clap_builder-4.4.16.crate 163503 BLAKE2B 9e8501c1cb7a3658b817a088ed4e2a94acbdd05d24fa67ac80693ca3fe75b36f07b69d3c44c2e5a892910228b7bfb86e9fc9443f45e06b5290999cfd4a310539 SHA512 0c627bef5bfe57e89c13eaf31e3c44ce730de8c5097d16113ad95cd8e3f65493ef9064bb962c9a617b2cdb537e7eb1cb3a303dd1779a7350539ea17d6facc16b +DIST clap_lex-0.6.0.crate 12272 BLAKE2B 22aa04997fffa15a2efc7013ae27fd223c3247cd31f8fe96aafb4e87e3224f075e887df10a95a2da80b468d4e16088ae9f171ba6551c0ae06d77bf3b8920ff9d SHA512 3651aa5e27ed35b6b75b1d25fd9c20c26a2a6039116e54d84c51469087732a4f0fd71754326456b367e341b017d03749e9a6774cb7b62250ca8745f5af46574e +DIST console-0.15.8.crate 36364 BLAKE2B 467de2c2fbfe31688cea20b338558ae9671e50ba1fd07983d21f32d7eacb73e565ebdd6ec5e78b2ae04446f09615c70983c0ee534e25ca5a28fd1b408acfdf34 SHA512 b05e49ed145785e29631d481885788f0cc5574d4d7c4d90280dfedaee7f8c1515072c9c4cfe6bd2e017230cd228157222af7e7d41a9fce697cd1888095df4de9 +DIST crc32c-0.6.5.crate 9586 BLAKE2B 32e4f20a996caa15baf5adf6a98bd07f3722645733dac5e5537176981dc4e073e88c8cab28ccbf199e2e2b720d0cca2c564fb8b335354ff181838c7e33b145ea SHA512 4a30845adfdc416e74ef1b8ec511e7e2de01e32035060b1df6a847c655071de82af1a336f210e989f7e1bc72e96201a9cf5c2fefdfa2490d4436526c754e01d5 +DIST crc32fast-1.3.2.crate 38661 BLAKE2B ce3762b03d24d5367d89738991c060f4b3af7840e0a7ac7fc17d01ed438caf964bbaefad0fc4d0c438dafa5a578429ddd353c71197f8b54b1ec441395f2f7ee0 SHA512 a683943e252afdb1b9d626a07533ed11cf7a63af603c19640056c5d2b9c884ad9aff33ac54c0853ffca2f6cf94b0730eae6c05abf3e53e55e709d180c8152357 +DIST data-encoding-2.5.0.crate 20632 BLAKE2B 16ea08dd12f09f2e6f8ba2910b3db07d4e7c9916e6a70d41420ef1a0e5393284b49787c47af0868bceb7f5d3f1fadf203f5a547dc8cb97713d5225dc9181fdef SHA512 b1de8bcfd7cfbfb988091fdb550eb98dfa5739ff58c4b789663e5db0d539c9acf145ccd72d87f7e1cdefd09d5771772d131d2b2e2589ac8f0bc6972c801ee0ae +DIST downcast-0.11.0.crate 5976 BLAKE2B 4ca0e66dbd8dbc86920d4184de8b37ab41954cb1560c7727334c990b97ad9544b098f7ce50759d10cac8b9cb955893805aed3bac5849c8b44a965e24d2ac7653 SHA512 11b037a09829e3e93eabff69f02b608725e6e348a191b1b6c8bb044b8d820a6ebf46eaea2f8bf5eb1c156f20d3e97be9b581e1b5fccebbfe76d94157d6bccd53 +DIST duct-0.13.7.crate 30055 BLAKE2B f1259e9818a7c2f1df3dc387be3837a987e0246dacac84d3ac3443a0c6870b6cb4dab36d380ef8d04db47545655ef4def8c713c62f6e86f2b995fa3b69a16b6f SHA512 b6e524144360b61b5c134d40aec409664388e88ada241443d152c5f7ef8795535ba243cc792c881557412bf75c2ba73c84e2f620eaf7d4668a15ba6bc274b1e7 +DIST either-1.9.0.crate 16660 BLAKE2B ad61038bfacb16f678fff5dd9ccf8f345e1bef18bd7aa0aa9c99d44abf8428939362f32fc8dbb1b60ac56016e0096201071d0bf8c0431b660605d0dfa97da466 SHA512 4978d50842386f51e31a47ad037d5e491106a668bc701bb833e6ec3998afe3ebd80efddc47756b2f300f534b39b26fc01386dc878d3b02cc8c1fec6a474c2177 +DIST encode_unicode-0.3.6.crate 45741 BLAKE2B e1e3792bc2bf9db7df33a516d0d755eef5eff1249aa9b2fd7f0dfcb155786c566fb619c9b2d73425a8625c8593988b117e9676c341f65e8795ddc838bf9881c4 SHA512 64193d6ac75f66d58ed864169b5d6228ede36dcf100614395e086bc8e847a3ddd287734d88e8ed50f38c679a99c80ec68449175a67d8ee03b02ec1cfa9d55e77 +DIST env_logger-0.8.4.crate 33342 BLAKE2B b1bb359be2f34ca6f93f72154c86920b8254f574b48f693b2ae7296cd1ff25d34dea61e95fb2954569fdebb6c522c851ef7499c107005528aa2226df13b0de33 SHA512 9e4478ff609a2e1e1a902a55b221af43a52622fdb5668dc33fb0be354b964708b7b6d13b7f1ef11982f45fa7e71f0712a2ab3fd4ea98155a5115e5a7c3d33049 +DIST errno-0.3.8.crate 10645 BLAKE2B 4a7af10845f11b3d8f177a75a692be468e8ef0ee53fb84a4d212335f1499456b6739a59af260894b5c3853d3bf21ef3490d1e3a613305561203ca334a636c3b3 SHA512 29753c421c6f929760cd7565f8171696e4f70e677654a7507253f4fc495edbcf214ace27be46bdfe5c1a0d782f4b688f591476e56f4a1096471cb353c643328d +DIST exitcode-1.1.2.crate 6538 BLAKE2B 3015eb8bf6658336cfe43b4cc59ca95d8fff5380dfa2bb2a3086005b0dde5e6a704c6b62e027bb5c0d6e6103bb5dec4ab4c869ef454361f224d013c267bf4a78 SHA512 fa31817e2bfdafe64faaaa6b32573e01e2ca0db24c6c88c81f43d84a9db66d19db842b61cbd89b8f6e199aad531a1dc0053b2d4166e0f9196f275fe715f28fc3 +DIST fastrand-2.0.1.crate 14664 BLAKE2B 7a5812153500170dcc53ca8d66384fef46eeb5a8f970be43863f22f82bf427672d07cb053f4e04b0fea358ca89178399871235680f57223b8561c07b8d21cf13 SHA512 79a1e1b3f39264f037def236afbd87b732f5e0a2154b1d9e721b3c7990c52be45138320e2571fe628f482e0da7e3cf867abb745e3c277b19015fc031fd4410d9 +DIST fixedbitset-0.4.2.crate 15954 BLAKE2B 91270883db5ad0e999ebbca1123d8729d3040eb936034ab8da3cda72a830e45fcb977b3fe3c2b94e870c1fbc366ee8602357bb77e8b9a40cc41a04afad1b266b SHA512 57c5d756b0a202b2506270f0d5e890f7617a1e0c015b6059ea23fab49cf7af47fd06927eb56feb03b37cb2b6c467e326b3f0da1e32cfcb6339cf11a130a3ccab +DIST flate2-1.0.28.crate 73690 BLAKE2B c9f141bde0eda6b9c42da0a3ed69322c12c6c29bc522131f51ad56f6e2758646aa5585382407409257a8301f5f07a1825d150838bbb55822f2d49037f6279aa8 SHA512 9db6f3ddc4e1e91960b07c08712beabd911b297d93db8be3ecb97a392a4262e608c75ed8e9e34d87d58c3e67d1b7987734e14ab3d45fd837a2767e8016380284 +DIST fragile-2.0.0.crate 14668 BLAKE2B 2e589b312d7409a1a550a676303b9b2adf2e28b0d4cd02c7fb22b48a88d1f88a04e55c4405078e2c43b13ccada890a33bcacfe179abd12236c23f219d275c4df SHA512 a48fee7c13ad800142a9ef1f355b2200b904ad9bf97b3601e310bad2b6ad90ea235b9704964c54be1d9c415c9c95fbc5f49e8ba5d7c6ee3488573f3404912608 +DIST getrandom-0.2.12.crate 36163 BLAKE2B 0afef8504932ea0ea051cde1d14bd5b79edde68d6ebae6fe88fa4aaa532605a16f466d0d9c0d0aa619eaa105600b6d5ee4e191865a3fa041549a78f78ca82396 SHA512 dd97d7dae1a7ba653abdaf2db719e1a9c8eb721b08b4af0f1c45b1ed5079069d1b57e4f6d9d879e7fae3a890763f4b6aea9bc2d945392b98e811e7b348589bee +DIST hermit-abi-0.1.19.crate 9979 BLAKE2B 801e8052b85341cca388ada9db4b06bb1bd7b64474185b2ad06c0256b9e597639bd3dd4ba0053ea010f922e53969a4ab47b90d451fd9b94c8f2324055d151ea1 SHA512 1c877fcd562b15d2de9c151fd6c5f3ea4bf48abcb799e6139a180ffad5d64b632f0000d5707bbd92ff23a0e5f349157b9e0f5be8b50f03680b0fa47315dbb78a +DIST hermit-abi-0.3.3.crate 14253 BLAKE2B 9ed8b40a1cc894addcba2a45562d74359ba55156e2c3a547afce139324b1345df2f158f58978ccd7d343fac5e5d2cda86e2e0a9dafc77af36d4cd8aa0a6d4c03 SHA512 eb162d085e8e0db72571aca925fdb6094d1e5d091766dd62d6a116957459bfadc8d51f1acc67f4da3cf6a8802c0ff445f3ad2516c1df8fcdca0b751632e150a1 +DIST indicatif-0.17.7.crate 63108 BLAKE2B 665bc2077207cac6ca2071d9e6ead76abb30d5f7c209d7b4a2ff5a1fcba566b331467239bd9168082839c961acf5a0522ae4c899aec141ccc649025b2eeeacc3 SHA512 412955eec523e961a20bb48f9921128004e723b405c8f1bb73abfaeb4f532ac6f883794fe6c8738a40c2e0a400a6ebf94ee17d89f7cdc98d9d0f8611d84a369e +DIST instant-0.1.12.crate 6128 BLAKE2B 728923f757c1ee4e4a7afb90e460eed81392068961240a538e5c6468e15a0b6491f590fb5f6cc46e6d78901ca232351f65abb9f2f230d8f4983c5e58c4011902 SHA512 fae494c00111c51c840f9dd6a10febe403e27ebb933dd16633a213e9c20f2bc11adeb431c71f8a6713bf88f270a010941e15d83df294e658791934f83a5d2407 +DIST iovec-0.1.4.crate 8720 BLAKE2B aa1b4cd98ebe47901c0959cf1d8eb2586a803d0453e2a8bdd5c63442b32886dbcb37650aa218c748fd45c9fe3a7fdf20569eae5b19716487b139caae1526da4c SHA512 e23fcaac239807daea20ddcf2cdd4fb858ba1aa970ce6248f70f0fba5bff7ebdb27247c0997ac0ff2791178f86ff9657e473d8f64b86c644763e5b3474edd158 +DIST itertools-0.11.0.crate 125074 BLAKE2B 8e686f176764e92e4da3697eb781e1bc30d6c57ac61d97343b4fc3a48e4febf669d5771fa8620005c620cce52c236760ee2e1bc344cf602e878bc168a2e69cab SHA512 8ece00ba0a7cf481ad4586da24385a6f0b1719b9c3f0c25b9b5b373dd1a0ca7b9687a77cd179853392890b7bf4d31e0356a4e5fd540465b4ac62bd74ef717fd8 +DIST lazy_static-1.4.0.crate 10443 BLAKE2B 25b2e61bbac48f0dcbc79c81d7bf01f2403d8269ecb6be3ea6147bd00f7a588df15a91f44dfc18ada19b21faa71de4637c7d493a8628cbecd0e547d74e616a23 SHA512 e124c0521ec7c950f3c4a066821918da7a9c6e711115d98009ae7c351928fdddead852e7596fea5937a9c30e4e4ce8eee7099b20248b5d6e3b2494b6a6d88cb8 +DIST libc-0.2.152.crate 740278 BLAKE2B 8eecde477063207d77b6894d6f9194c8dd10e55b69585e3d66296eaa0b9d3f6e2d033e667207182bf4c3cf31f6d38820c9187b2006f4b5ebee898adafb4b2751 SHA512 1722f6f52077efab90026aae3d10306f8c38ebba95366593c3c1adf707fae121ab450064ad9e8be5a667caf6af0b90fad4d1ca1009db0f2220093c44e33c4b5c +DIST linux-raw-sys-0.4.12.crate 1465800 BLAKE2B 2f70a344c427093fd55732b68239f771cf6563edfe2db4b2f50cdbc904dfc7565b30bf06454b91482eaeea787b9cd4214979665bfa32f3c1c586551333cf4d2e SHA512 d9564d02d5f41356478066592e438629adb3275df0e5a1a44030cc99bf8856b8af64f18f27371f84122a828b34712aae16495a1a16050fbdbece6d95e9cdace9 +DIST log-0.4.20.crate 38307 BLAKE2B cb9c9a401b49bd68c18d5e42f2ed94446f1aeb184caa23cefacad4ce54a2a357143af54a5595c45d6f3c3d20b054c451d9e6ccdc09c19cca99ffffdaf8bbfc72 SHA512 8661b0c71d3b7fc0d679aa3d7f06910e6d3da1c53862aa06526000e1bcaa0b0b068415a1a9ab317c318f00d15346dba8a4f5d2a60d8850790bed9cfaaf757b3e +DIST memchr-2.7.1.crate 96307 BLAKE2B f1a008fbdbfe84852a8ae1d9d9574306b1bf120dd5087903adbcca6af342c9abbb296496eb9bf6cb58915c4444b3edd6ca4e27131ac7d8aed8849815df87a944 SHA512 5120496faa31fc427c8b4178461a262b3a34d70eddb7ad17a19d6db8b9969c9e113d3625b5e6dc677087fc80907377b00ba0421aba9a92cf73ca2849d932f473 +DIST minimal-lexical-0.2.1.crate 94841 BLAKE2B e6b8919b80d938d0b98d60d4f5f29ce43d77ebfcf8b18bde08909141915c6ef4f0d07a543538d4f3ba8527a9f55926d4a8e83473248469d087e80b274d701d61 SHA512 385fab51884bdcc7b0f2728a219ab164d0dc8efe42160b918f2c09f79ecf853fb12bda006d11e649f097bae1499dcd41ddf2a8784ee7d178cf2c28059e46078c +DIST miniz_oxide-0.7.1.crate 55194 BLAKE2B 56afbe0c0b3eca98105ae2d507493f365353cce29a6b04910ff26bc75899400fdbd067756cbda7b3d86f047fb8f3d737de00043a4a7348a813cc43e45824e33f SHA512 5eb6ffe34a866403273ff0267ff7838aeb50722ca57a03d5a1d842a5f19a3b4af570b133a3b9d64d78eafe49e4b9732b92dd63fd9c6b0ce59b3295daf10f6a3c +DIST mockall-0.12.1.crate 22845 BLAKE2B b2299c6060b609732b041c66f58437e1a52228016ecef33f9d2d6a9e017b86f35079ef69ec7bf511d4fdec309c60bb4dd9cb2570c7a3e079a37366c5c1a0877f SHA512 8681eb1b1ae2fa00bd2b73269a0b493361d0003da4080da79ff047692c75c34359621923b06906046218acddecb1fd49186fb7b4e752c70657dc9becb8f20c6f +DIST mockall_derive-0.12.1.crate 45330 BLAKE2B 6593becbb7eb3393a8f05ca4d5d6fa8ed9d0ff00c1b53a218b39889a6f8e14259e29334f36b0fa926610296d5f46f17e627284cecf8dcd3689334d589078b394 SHA512 5a99f5f9cc0bb1383edc3d2eebfabbe520436154e39cc4a4556f03826493ba888a54127f40ec70df66cf9c83262cecae3ffab03de9cbdac2716c431e7ccd39b5 +DIST nom-7.1.3.crate 117570 BLAKE2B 5643b67990b7305e101b16b8cd27c447e162a7adc6d0dfac00920b0cb50fea98c9d4edca63c34f6845cba05f8d0acb407cf3045cf64a4cb28e53c8b6bc9090cf SHA512 1ffce08dde299bc0e0367ad59c7b6a83e23decfa11115ee076ab91ec53cdd9ef37e4c2103c96eff23a7b6b8b5c3f67c83ce1917928c7d4c6462083bdfa0c9cad +DIST num-derive-0.4.1.crate 14840 BLAKE2B 9dbacc6cf946aed6f765fd70ad52e7b6ef036a30cdf7df39afbd8dc8657cb4cfc8954727fff04dd053d46c4f3ed513217d24914f3611c96abcf2eae83992be2d SHA512 ea7bcb94e83698609d055981ac5f112e9b18edc87a767c0ad77d31bfb6fdd0d552f5a23934e2956bff56777e9460c08ea05a5ac636bcc6d45512e4c330260d30 +DIST num-traits-0.2.17.crate 50190 BLAKE2B a549ef00c749dc7f276c4817477d1f9dab70cba01b6a3afa5743f16f16353bc50d992d7446a54859cf750a410d66c8cd3440708a6b91fd89d3b8889f8fff1668 SHA512 4d47d3e2f5a31019e038e609897cb0cef1ba061b35cee7e2a02e65179dcdd4960bd5b9bc759b5c013d699b3fbd9b014940a15e36658f7d4fd12cb0c7841c5b4e +DIST num_cpus-1.16.0.crate 15713 BLAKE2B 11b432fc7c7496d48918f09ed0954e0f1d0845596301266321293b374392898853fb7c313a0b0fd9d22d9dbfe3ccc5cc1e38f38407c89b2e5906eb76caa6ad68 SHA512 a75863afc4a563e63c64d06471c7921615355d98011ea9497b1f1a7dac2bdfc876509136018e8062ac38575ccf476a196d1fd9231e09e90017333bbf2df4615d +DIST number_prefix-0.4.0.crate 6922 BLAKE2B 81bd3b588c788e6865104e5ce87119b5e0c5a526042963d52cd582ff23c2f8c9f32b4c445ef0397fc402b6d047e031d8e2c67ac97e191bde22e17662eec3a554 SHA512 a43b668d7314218b86ca7451daa9dfef71f6c9f6616bc34c12d94ae6030f182bcca9da83905cb46f3d49d0aa81385a787e92e4f3ae239658067adc249f8174df +DIST numtoa-0.1.0.crate 8999 BLAKE2B 6a8cbf17458227fa87bdd6a35404e09afc092a1ea45d68c6c035e08a9d344fdb356b1bc7b52239dd6354ed9094e9338ccac599542bd7f0caf167ab8d17ad5fa7 SHA512 41b5c774048592c5867fba217c85d4ece4540e0f3ab0eea7dd1a6af340ba46dae42bbca62ea7fe3afdb258660f39a3d3082264c99dea67d3d1ae178d00a01354 +DIST once_cell-1.19.0.crate 33046 BLAKE2B c14b374eaf4ac0f60acc2e02f7bba270a0e8e0a6978d749cd3cb0ab3eb26907e4fbea70dd5132982f90290381ed18ff8a87fd530f1415fabffac864f157ea380 SHA512 4154876afd34a699ee650d1a8a1c5ee5a25f0ebd9388b8bef2564e33629fae68f113d7507488c68abbe7ea1acf9bbc41813cbbf3ef3e464e3f3b9cc7a51d870c +DIST os_pipe-1.1.5.crate 11430 BLAKE2B 45abc371ddd363d193817a339f9e1894ec6fd275b9c9d190283347bb023ec7686e3ca6a5f2bf09cd7ee6abb8843ae52410c203af2310bf3e35c280c5b9874ea5 SHA512 d862484e9a0594f31e45531fac9a892fe247c1003a9c365a28083c0b5132719fe6fcd7ed996716a4baddf1f8ec4857d62d05663d3fd7ecee5802005c55368048 +DIST portable-atomic-1.6.0.crate 140689 BLAKE2B c91d06e04a87c9a207233d8a850859aa1f5cc43dda8aed34511c3fe9641c27412796539ed045a58e649d2a0c7d71100b6b2d78a0c662fc061fd961a652ae8722 SHA512 b27cf57655a2f1e2d6ea7b45d80b4f9920a836e462f132c50dc1e4d314e162444309de1baecf45dad2defc7a5b99759165e54da9fe759b24092f8cb8755c515c +DIST ppv-lite86-0.2.17.crate 22242 BLAKE2B 48c4a31a3b555fa37072c4de083580bb769747c7668748541af472778b5b58c3e7ab2b5e178760f542f973774f09910bdd4058ae5fb9d6b10c103eb76cfd0d3d SHA512 539d916e7e5869d832045c1aa88aec519bd000227f9b01d4dd0bfc9ffb640d5f5eb21b05eba718174773c97192a655ad3cb31b53ceb914dd19179a6699b3583a +DIST predicates-3.0.4.crate 23240 BLAKE2B ff0b96b85668dd24e8368479d82210b38f591f67a0793a080670e02b649516be8acda4ae5f80e98113a2030bfc7ec71cffe53a0fea4fb65f98b3a2fc1f6daece SHA512 b2dbfa83760004abce72f2ef576d7ec079c4ea909120a8fe1ec6b87da0fcc2b48406cd6857ed16e131281b4775a6f33ae94f975e381794fd9a98a2c0e11e1f75 +DIST predicates-core-1.0.6.crate 8084 BLAKE2B 337cbb155bc2859c5a8b891c21d352e998cd1eaaf606cf46c003c9c499a42f12268b071e7a4cca65d50cdfdfd4267f023076e078a0a3eb401ad836755d65298e SHA512 afeb1de4275c76bb1c5950f42bce2f83a21ab217ec60130336286cb48b15f36bf2a1ca346bd652c10a65a1f9e3310d16b23b8333a3e0f7e20fe874c3f728e702 +DIST predicates-tree-1.0.9.crate 7960 BLAKE2B b758c52dcdd0ea237ce25f0a092200604765bc83c5edcaea646c6b1db49431296b61aebddea3b325e62f0ba9bbd5edba7ec92fd031cb597e7e8d642b966b401a SHA512 1fd5d9a84ca8fdd1b3c4759d5e6fb16e3d8fe8b0dfe5afbd16bb509c8558b0750705fff47701c95f7a8df1a222f639116a1b9ba4d89775bf03b06daf34f249a3 +DIST proc-macro2-1.0.76.crate 45660 BLAKE2B 40b538d9d9fec10b9e4b147ce0a86efb10feedf9e0452e5568e8ad7d2b88a201ca6ffd2cd62d8815a1ee72d557fe6280120a913868c3d868c1235686742cd8b8 SHA512 2ea7ade475171166489ab3e745e8c526e49c7521bc39b1bfec6dd2fd0807fd3cc5579235f77534be855f9ecab481205e77e66b14ebb22e66d2c3cff842567247 +DIST quick-xml-0.31.0.crate 172236 BLAKE2B b83c7f485a30576027a4ae77aa23cd6284942d786f0f0a14faafdfecff646371ba15133b3ba90f820183c8537c8ac47ad3e1e7deaad65e56761bc662be406026 SHA512 9b1f4f9c32694ccb244938a9a4e9373c3902314afb6af5d2f6b1be55e5ec63fee5cf1085f8f32161570cc10fdd96f3375c7564b1d884bb152542b86593f175de +DIST quickcheck-1.0.3.crate 28069 BLAKE2B 5f0ddc8e22fec55e879745a95024abaa03d7bcfc6453286eec072663b36a5d6ae247b3c1622c4743e1ca9b7c4bb21da0d095aa5247f32b0bedc393f92cda6bc0 SHA512 07dd707c9d3fd0b9cedbba545bc8b4fc1ca2770d169e444f8c96f8306d3161a6a3e9189cc5d0d6b3dc4221f7dbc05887dfe2dedc914f88d5e69ab2b94179185a +DIST quickcheck_macros-1.0.0.crate 5275 BLAKE2B 1681fbc5a476c627da442d601d9f24dfeaa147dbad7c8d6989ad73cf5a204963c29b2b5bf68513ba74c322f74ef5ceea92594953e9034921a2c8132150252779 SHA512 f7de86f76a53fc36063f10f5405979677a2e48a96d13c439a4aa98e89ec7f3c3cae324b8dd789a5236630110ac9a1763f28361442cca08d1a1ef458c7bfadd55 +DIST quote-1.0.35.crate 28136 BLAKE2B 81424245e1e2b94459df68bb3a9a866c6a364102b5e1d010ede9c5f8278f8406d7b651957d091c5914e936b494b0f6e9a6a1dd8b7d35cd7d7100f86dee4ec12e SHA512 f5314fb6af17cf36c228e1970c569c29ec248954a450a5f90ba9e2896d04f74904c9cec5a1f74325f2489295a94491eee4ce8fb461e22cd4b34e53f1f881efd2 +DIST rand-0.8.5.crate 87113 BLAKE2B 516f26bb2a969d0d79e957818133f35d2c0b4d9f1b401098ea23c5b80d27599e842b9298c0c5e46e2a6cb6953857bf8a9fb71ec9366c5ce6708cf17df14f179c SHA512 8b33a8988906ba5e2057a9a84bdd11f867a5536c22f5056eec59ed4ec4e3a6da2fd773da4c0510d343762e5a4ea0f007db4c4a7cef87a47f90e36c1a84d86fb2 +DIST rand_chacha-0.3.1.crate 15251 BLAKE2B 645771b2c3e274f085e0837a20306b1d59f6e9032fba8eb38a6d1b30180d15e2f89ffa2a162bf6358da41e030098242d81e71dab4321980d0a4f6ddfc2974ce3 SHA512 8198c580b1b9b0429758ffa49cd8138fa3ce724f0dcf73c767ea7e55611d6a2e4c7cad9950896510def500ce4062b594386c947ac3d89425b4e5c9b04d0b8075 +DIST rand_core-0.6.4.crate 22666 BLAKE2B 8b6b66d50aade877f2779c006f8038db450f808c66d73d79efa66c4178dc03db06f12201bf0e7930181c4b0f4030c49b20cce6eb7839763cf2217cad9710789a SHA512 36c67eb845aa2ccca49d6d680f28d418229bbc5a050729e487fe6b9f9f384fdd7b8d67fc6508b90b79ffb3c26688e72feceb3ecae57d3d7f59338aeb62296f79 +DIST rangemap-1.4.0.crate 45931 BLAKE2B 64e6c9baa55ab2a4c68cacb7d33a060c582ab3e7f9ecc433bee5c3ca4e76b8f86bf9fbdaedaa0c5ec2af600d234d2f949d764799439eb494aa6163e36bd0caf7 SHA512 15faa3f26c38f395388f596cf3a655669cd09a84ae1a17e61c40dd62e5331c6bede2bec09ec6961f870d2f46e8cad7fea70635546721cac3015482fc264974ee +DIST redox_syscall-0.2.16.crate 24012 BLAKE2B 9497a52044458b1435ea16e86ee072e379b6b11ee31602ea72d6b6072a4a99426f409c2e58108a4e9c36dc193fa49c83951e71f4fd4e158eafff18c594dc01ad SHA512 63b5d876baaf99f5cf737679bc6ac7a9e3d8a41aa93f5c59416ce7e3841e2513bff678773553cfe62fb452707f82acc384ea63aec932a31bf94679cd1caddd27 +DIST redox_syscall-0.4.1.crate 24858 BLAKE2B c3301137a0b84e03b09d28dfa377ab3bea74d574a08cee21d35713b278d8b5b30ca2a1d73a0981baeb4644cbb88c86c8eb15ab3bb2692e38b93e6b35fab4e0da SHA512 073ed9d96090cf46eab9877742277a013c62d8da86d9caf2310b4fa868af306511936553579e01309f27067d344226cc8dc5e3aef01d9b900da2febd33848f8d +DIST redox_termios-0.1.3.crate 3240 BLAKE2B 3aa7360c9e982faf433b527605fab4cc01f74eac5f1f4698b5c7f43e5a7645fcddb39bd639c8f6935fb82db5a065630ee788fd8b111cca80be15db1a08d0b3fe SHA512 a221afea8eb1c7efe848e270a6ad5b65a97af945b4f64d3aa5346f5a61a9daaac1993446ddd78c1923b798e1659518856d7260d9d30651d91897850b0a1950d8 +DIST regex-1.10.2.crate 252839 BLAKE2B 4be7bede72d41634c52eea25566fb13337a84a055aae6fb73d3b18ab9168085ed04ffbfd5b6f87c2f85c9922893b9c9a253a8c874eae9185b2100850443b1517 SHA512 e594f70cc540586e4039e7b905ede9e507757b531f22a94aae185e47732ae0d54bceb2c6aceb815819a9652c01ccf697798d372631f2f864c04ca2eec59759d3 +DIST regex-automata-0.4.3.crate 617011 BLAKE2B e685724eb037411c1a73d6d355c76e9e32c40f1c9029acaf86477796d3f5ad092b0c5619f4df2fc1ce34243f2ad8af147aa31f83a435e5b5adf55b4c9c8a9359 SHA512 4fc82fe3556f829956c3172447589555ef286fd66ee9a445cbdcdbe57970655e35b6eb0895ba02c344d826609257e0c95d3f7f51858aa260103bed7b08d8c1a8 +DIST regex-syntax-0.8.2.crate 347228 BLAKE2B 211fd1c35ad0f28874d4b4d276e0fb0a27e5a1608f2f16ba2333641b154624e378419daf8d1c955f21ff5f40f6d49c89569b7e11ea5649850846d0fe447a675c SHA512 301dde555f300298f2594490ccd8b92033e4917fe9b8671b8a97db6c827793c73969be85a92999964dcaf3177edda51abeb576811ad6cab9772964dc0a77e728 +DIST retain_mut-0.1.7.crate 3945 BLAKE2B 475a46e0e3df8a55305b0d14d6da595874a3c3bceefc4a4d4feabb5ae245d48190bbc7ec325499d2aafb4ddfcc0906789bee89689fdbac261a92b66bf33cd493 SHA512 c90538becfbac41952a0d5ea1ba0dfda4ef6fc8988ae60080c0ac32e3abfcb0cd674be7e7c221debd916060c6447ac59ef8b3cd93fd9d558228e70d0dacfbcb9 +DIST rio-2979a720f671e836302c01546f9cc9f7988610c8.gh.tar.gz 27249 BLAKE2B 5a2206986662979875c6f8ed5c9cd19465bd22bef1ba55bc92d67bc539271a3af29993333951377953de2f4f8c8f5343c2def3350f1e94ead572a7b9b09159e8 SHA512 40d5b942737e099735bcacdaedb101e44c39dc1f8e1488550d3a039562b5b2bd78edaff42b0ba9731f038f0555a0480152ad1c33bf31693892ba5733a39bd946 +DIST roaring-0.10.2.crate 91257 BLAKE2B 1c24f76bb038451f8239065ffe278625a4bfc5e46580e91a2c2c02b584d73f34c5aa5905ca3ddaa99b040fb2e679d93c3c21962d814af1a6d76d33920c1d282f SHA512 a13b84d9a2dfd05f0410f247abab816980c8b83504f40ec1e043335445ef7115a0d7bb00e3dfd22fbe8616e71187649bf27123388e6fc812451cd64c1c6cead2 +DIST rustc_version-0.4.0.crate 12175 BLAKE2B 6fda2ce03eab45d7193fa0d70175cc7ffb56b7be85fb1314092bdcfd3948ea145420569ace3a47218a4a2a6e44a818862cea6dd8cfb945475496f63b591c29da SHA512 f66da7c6efe431db06cd01180d84ba67fcd38f8cd6ef693762957c00ccc2211f23c08079d7f184776e08f28d2d6ca3bdb5f5016f7de245c6193d4722891ba1db +DIST rustix-0.38.30.crate 374744 BLAKE2B 63ad9fe2e131259a008abdf7a19735d2e2401e62cceae7b449ec7cb6025e82f8d275c24caba5c23c19d9c37de9b3b9263e96db3eea6bba569eb6146f5b3dd62f SHA512 6ffcdc274f97e7dad9fb0a23fe948ec4041fff6ce915204fb46adc31b55646a5fd0ff3d8d6483673da2cc55044ba53af4d6e48ebeb8622e7ac027a5d390231de +DIST safemem-0.3.3.crate 7778 BLAKE2B 6ebc0e234054919687e8a369bc30ca6b007d0e4f8147157ba1a90c290b7f0b490e5c21a6d4406671e26ac073f9e4e06a2bc9b1f21eb152b05c4022a3a4ef3793 SHA512 2e4852ca91160f9f1e764b75145d794726a5f6c162cc99ecbf9cae20474a06cb3a0dfc245b895c51342240f6875423010b33e36d038b8b419a37e4820a9caf72 +DIST semver-1.0.21.crate 30445 BLAKE2B 1c779c25576723ee7e44e7c831eacc5dc6bb33cbf051bd0748f688573e01595d05808cdef4ae48a6423df15e474cea58a0664ad7fa5cad490a61f89473f426d7 SHA512 bc3ceb11f2b729be086120c06ca2cefc34c5141d2d4af64279b0868456894eb9097b234b326249f2aa83d8b99086fcac4c5b7ef4a1e14b1198ae808fde245c35 +DIST shared_child-1.0.0.crate 8939 BLAKE2B dd7aa5bc4f87cab26cd0cd382fa00f42ae45ab6944e3367e355d19fd1007ded068642a35941e0cecc100120bcb1ea7d07d91bc36227261e8207b87c53de87a17 SHA512 d0e16cc7253271e6468659db0d7344c2d75772dd3428f686c49ce34bfea6ba8fa010b1ba83375241bf019e77c842001c6e1ab5096af54af03586e05c3f8fc476 +DIST strsim-0.10.0.crate 11355 BLAKE2B bcb25ad0a7284e24e4f17ebe0ccb621bdc4118e499b50b094d98aa7e8fcc0b96716c9953c3516ce7ea78309d41d424892ded595259696a5bbffdcb07802b5c2f SHA512 78b318532addfcf5c1ccc1e14539e258aab9d3cd893cc45d82342549bde838c177d90f13c560671f8f32929af47d0b467db35e6876bd7697d8b3f9e055aeeac1 +DIST syn-1.0.109.crate 237611 BLAKE2B e827445d00c79a8eeb91eacde472f1987addd6ce9e1df95d7abf6446a77ff4173a8006845f3ae71c1da47193cfb72e0ead9a6d6bad2573be12c17e90735d9ad9 SHA512 12816b9e8cf984024b2fbce9f0ae14cf94d4d2c06f08cc54fb793ce78770bb4cc1288eb7df0ba5e8e937756e1e8e295c53fe07a0c5dde1ea8ddba03b6203b37d +DIST syn-2.0.48.crate 250566 BLAKE2B e46b0863af76c3116c84d01b654a9820b7edc51f75c9c5301a7967d12284f78da602409f34fc40524728350dc6b998a4d738f08b8868f95236b3e5d24c460580 SHA512 926c0ad55cc743df20f9166b6d71fd44421aeb1f073fd86b6ddb53e13cd508b539c0360ce64b07b65597bb14639c8f33acf7e60951e1e9128624517aa3aee325 +DIST tempfile-3.9.0.crate 32182 BLAKE2B 4e802990988aff3ab5173bd96dbd906651a8df46b2619e6a500a3b9e7f4a3cd01dc7ee977791343f7875afdc4793a845000bb363d8c1a6599aeb6b1efcce5d56 SHA512 04e06c966bfa7a1567e7185ebd5c2876b96e46e36af14931bf0eba63795cd20d1c3427b6709a4cab2a68b8d289fdabd5537a50e5407a76e3a9fa0dcc7d3ce6d7 +DIST termion-1.5.6.crate 22677 BLAKE2B b918dc82bfa370bb9662bace34211bc7afa03a042dbd25f4456a7e3859521d4f32ab755780e58070f29eb7903f3b4f8129eb9447cda953b9190f9df3b7eb3aea SHA512 228b6fa7e2f280d6bfc7cef77e7a1d0d8f597178e66af0bde1b1fb6553857b511ba8a6786165815aac6d8a082fd37191f4ea35a47f1e1182f7f2c6086eb34a8c +DIST termtree-0.4.1.crate 4557 BLAKE2B d4300b0e6e908c519a0a76f5e08167f4467f428b2926e7739614cef5d3e294dfac15ae8576f7011a852745713c16da93346660ff96520a2bb90a4dd4c23d889c SHA512 ddbe0d3ddd79b182732359f47958ca32aa351d10b1e7d5f6456700b851aa2b5314ce005e1fd120a248b676f219fbd68039cefc071d92c5b5477d053bb6e29062 +DIST thin-provisioning-tools-1.0.10.tar.gz 397068 BLAKE2B 2dabfe6d64ed806aec8e253902b0465b11105263971839cb2b95cad0d22ce120894a0db0fdb6a34b884509cd52c2f09012ca400104a30b15a1256758bf554808 SHA512 76ff45c6e7df3e1c0b8d7812f8e879879fbacc36949fd5e073e92200caad0005005e2c28de2b2c29eec046379d26b2fff07d9dec41a543d9b039fb27aaf2e105 +DIST thiserror-1.0.56.crate 20592 BLAKE2B e98c8bba8d21342c981646e88b72a7cbc146c695a200aae3e076b55948791cc51a29e8818d64451b17233ed4d095d0ef63ba4fb07502f4ffde5af738b8629c37 SHA512 6b7c856745256d6ef9e7ab2ea0027f9c1ed2c75ed5b075068af57cf706abfd835fd4552d9ec7578bece1f820086828c5dec85a9cbada409569838cdc9d63936c +DIST thiserror-impl-1.0.56.crate 15367 BLAKE2B 6fad787eb1e2c0f25fee7bef160be794fb8000a0aa292ec0d2d66d7a4d1fcb226c3e2e690ff6a61ba2d8704208014eea84044dba27523d4b2c26d2f7d4ba64d5 SHA512 da66f4674cf699083f7142f3a60c1c9334767b4de3690b4c7af460ffda787fab2089f5bca231e92b6e71724d46fe7dbdcaa19073f5d8100838536d10971efbde +DIST threadpool-1.8.1.crate 14408 BLAKE2B 8bd64ede19184e18460f6b2ad5bc888d6facd5fcaa5b43c35269e35909c9c68a884203f5c4b92619c097ad48c19ec29f73085755ee348cc637233ff3b5b50ccc SHA512 adaa5aecdeec25848af15b160e5b39833978454d834974211bd586d81837f2ce89e5590f08b7e0d4868346cf57056913a5d41bc8bf92b89109ed769cce4a8be0 +DIST tui-0.19.0.crate 141279 BLAKE2B 55eb71dc524f45c3154f8af4024ccce33816d0c30aa28b3708a4991602892e5980df7f59b47d6c2cfe39fc90d07d7a0409693c37564b5d0d2f2f3a48e9e17c91 SHA512 b90497d06181ca74ad0a976ed57bfd6e6495e6fc96651ee96fe9e326ebf773b6627d87cae07aec26d17800a4274624ad3e835a86c37258c51077c86e667078a8 +DIST unicode-ident-1.0.12.crate 42168 BLAKE2B 4cede03c08758ccd6bf53a0d0057d7542dfdd0c93d342e89f3b90460be85518a9fd24958d8b1da2b5a09b5ddbee8a4263982194158e171c2bba3e394d88d6dac SHA512 bc1824e1e4452a40732fc69874d7e1a66f7803717a314790dcf48867eba34bc9441331ef031e386912e52c385645c25b6ed39d4f149973b5b97371b1b96b1920 +DIST unicode-segmentation-1.10.1.crate 98416 BLAKE2B 4c391ad34c5f8a00096ce89793b15212555f2d8a367f3ae78f26a36c5897b69f3efcd280a1bd3eb3f61c87b8a26061804b1cd56e1c1500cbcd62e8bc74520014 SHA512 e96224bba73fe9a167bbf226bb13fe5bea085765a90f7232cb20b42f3c584242b7291aeba1eb8edbe2ae40e5bee2f4714f434324f79316b22e8437c77a50e86b +DIST unicode-width-0.1.11.crate 19187 BLAKE2B 6baf7f3b32eb838925e591792abfe11968206d177facefb89ef51daf44c18f3fef1e41c19a47b88b81be50667af626af2024ccc540b240fb6e1d83fdea57076f SHA512 ee06f4144525424327a17578642565f396802f0eea539b3bebc8d9627376a8bc6c5376d83a6ee577068e99fe75815bd765e6d49fb9ab9b253d00594bb15a5ffe +DIST wasi-0.11.0+wasi-snapshot-preview1.crate 28131 BLAKE2B fe501889f25d65e2d032f885cc50c4f8bf7dd70fd5cbc438de349838370d8699e9627b0a4fc76030ea9fe6d508f41d0c9928a875fdbc47e73bfb17241cf7b155 SHA512 043500ab28cd9cb779475255da5d109ebab7fccca72b64873dc28d77bc5a157ba8d96b9e8f05223b5b36c7089bb7b4ba87657fc69bac16b78972f897294a865f +DIST winapi-0.3.9.crate 1200382 BLAKE2B cb5799749ccd935ea2d7068d953cecf19f543d9db7dc16ad4584bb7005373ada34937a3ced7225544d8bc765da599911c7a3190efefb3a25b7c1bb7123b4f673 SHA512 ff8b7b78065f3d8999ec03c725a0460ebc059771bf071c7a3df3f0ecd733edf3b0a2450024d4e24e1aedddaecd9038ce1376c0d8bbf45132068cf45cf4a53a97 +DIST winapi-i686-pc-windows-gnu-0.4.0.crate 2918815 BLAKE2B 4d357e4d30f9552972170d65b9a5358b69c46a3e772fe05efc22f3d4ffc1caeeaad7aacdc7abd503a7ad0545f8bd7d22bf351dcb6df76f812fa4d45c34d65df0 SHA512 a672ccefd0730a8166fef1d4e39f9034d9ae426a3f5e28d1f4169fa5c5790767693f281d890e7804773b34acdb0ae1febac33cde8c50c0044a5a6152c7209ec2 +DIST winapi-x86_64-pc-windows-gnu-0.4.0.crate 2947998 BLAKE2B 2ad1ea8b5fa07d544e910ccba043ae925269b76b26c9da356305b34b86741dd8b9aff0b9ffe3d562db4fcd7d7c46a11ce9e3168b782b1d89ae6881742b7ede82 SHA512 4a654af6a5d649dc87e00497245096b35a2894ae66f155cb62389902c3b93ddcc5cf7d0d8b9dd97b291d2d80bc686af2298e80abef6ac69883f4a54e79712513 +DIST windows-sys-0.52.0.crate 2576877 BLAKE2B 69d6b560ccfc8f679e2678663ba606060d71fa28efa82c8aef8cceaa2c63b06f2052764d60163964f939649a26bbec6361ee4b094555e941fae92070db566980 SHA512 24ee0df246c2b456a4987a9124786a28acd358768cc7d1305bccd81bc5bb8822b81a03fb18d35174a520b911c6d9b685f81a34ab319fee13da3b985273584f03 +DIST windows-targets-0.52.0.crate 6229 BLAKE2B 4b1efdd32202f112d3782b586ce60667f5d3b6f97ccae0d7da833aee2ae81ceece88b5ef4126db2448c9019de3f77e4fe66ed4286bb6275d9a5e8ab74725b804 SHA512 0ea09552d89b802ec0d419b640fa02d0af7af602704a0e88ba10f81d123dee0c907460f6ec91224177ec9a948970abd7414740eb219148a4d66c269c2362740e +DIST windows_aarch64_gnullvm-0.52.0.crate 430182 BLAKE2B f23370c62c4ab3fd885e3ee22e8ec2fb5a3a837a57044c1df3f9986dd4e7e9d0a44ec58be1648a41e1ea4d037afa3077f0f03de0204199a82fb8395731815a4a SHA512 b7c3fe0a2ad5149be0df48fc7a4d15879eb130bd9441c58c25fc71b8a91483f0b553fb1bf29a9302acd348e9083a547430a840b059b0cfe19867ecaffcae986f +DIST windows_aarch64_msvc-0.52.0.crate 821663 BLAKE2B e6f772858205f7cd871722136aec4d00daea4793ff9dcae53e6311e74526c46aa11c2b3df7a85e6c577757254cbfa5a713e68c694625ca274b64e7a1c5532c23 SHA512 8446bfe5b9fe538415762c8129ab3bf2fe45482e045bce367475747786602ad4ae1187c6e508dd9d7b6be81bfc8d430e0db9c624e35c7cc52e823023e46f5cf1 +DIST windows_i686_gnu-0.52.0.crate 870285 BLAKE2B a7688062a128a1b1394b3978210334e4e2aaa10dce131457c4a11ce0cb3f551e7f4962d1ece1846d8e9526983ced0e0a3ee8c933858e9314b62e76381e086ef9 SHA512 fe993f5bb6e039c257be9b35337e0221f718d23866818bfd19c76aaae236aafc2de4bb5014fcdf919563b5901cdaa14a2136cd086eeed3c83e46a5d02f6aa77e +DIST windows_i686_msvc-0.52.0.crate 888693 BLAKE2B 7a6e9d03e503c8f543e80a8c7bcf3f50cfa7eed462e487ae7b581746d7cc4d871b33e307110d3a3a75226d88e837f9452ac56bf3baf71b66cfab2626cc15558a SHA512 817ac796fd00bed51d80133ec873cf3d3d582ba41fec8a6f6407fbd7544f198e928aa5d710f70c13bbf74a1dde4c91c54e65eb9d3b7518a7f011ea42725eb671 +DIST windows_x86_64_gnu-0.52.0.crate 826213 BLAKE2B 3ca03285ef289fc844261142154e710e996c29940b1c0a7dc3016906ff6452fa50b24f8668fce0ca44bf169ab1228c217fece9f7bddac9ab8bdc54fddafaf8a8 SHA512 2d81af56ad0bc9536f6e066776642a546ce6c6d99551edc0603ffcafe6db15d5d5a32a642b204bbfadf34231daa3894ad7897a9c0c575c2b6bc1e3e58a9a3eb7 +DIST windows_x86_64_gnullvm-0.52.0.crate 430165 BLAKE2B af9345a1f6e0ed1392ca1534c68d23f3be0fbb6a42b3c5518cee14373e645038526da15e849d14abe45c53766a30c6c2042a626482ba4a05409f325eb6aa36b1 SHA512 e88af35fd1c694dc189783e5c81aafa61aeffbddce4d7130e1125d0ce3d932fafeb345990ffd98477c41b578b7f5090f4f9c0457b02146309b95549c9f8f44f0 +DIST windows_x86_64_msvc-0.52.0.crate 821600 BLAKE2B cc448b65f98fc0fc4949ae622b7020d2dae927ae45310649f6ef71809740eda9d3db0fc035676c201fd9ab9639e9e7f21e2e992b4c789542f12b419d2c752179 SHA512 3aaee31533a1a48a6ab5cd15b3cadfbd906a93a153e53919d0aa74e440d11e29830554e4e014c215f5b88a475bb733fa8ba4ce9d773d3e23a40ea9ad37ddd0a7 +EBUILD thin-provisioning-tools-1.0.10-r1.ebuild 3620 BLAKE2B cf1671cd53b270b77504eed05d334d57151fa2d9a06d3fea74e5bb52564b762d9912476b986ccf9f12006937421851a2022617977b277e25f106c1c20305e91e SHA512 a8b9f75a529c383dabd89b06d52955ae41a333863697f721c5aa6cfd661bb27f8f63c8680d5076c6230ae1798f26a7670822f9e7189238e27f0b2cc5f785e4db diff --git a/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-1.0.10-stdsimd-fix.patch b/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-1.0.10-stdsimd-fix.patch new file mode 100644 index 0000000..0c45e58 --- /dev/null +++ b/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-1.0.10-stdsimd-fix.patch @@ -0,0 +1,16 @@ +diff --git a/Cargo.lock b/Cargo.lock +index cc06e8a..ca9a311 100644 +--- a/Cargo.lock ++++ b/Cargo.lock +@@ -129,9 +129,9 @@ dependencies = [ + + [[package]] + name = "crc32c" +-version = "0.6.4" ++version = "0.6.5" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "d8f48d60e5b4d2c53d5c2b1d8a58c849a70ae5e5509b08a48d047e3b65714a74" ++checksum = "89254598aa9b9fa608de44b3ae54c810f0f06d755e24c50177f1f8f31ff50ce2" + dependencies = [ + "rustc_version", + ] diff --git a/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-1.0.6-build-with-cargo.patch b/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-1.0.6-build-with-cargo.patch new file mode 100644 index 0000000..5e06583 --- /dev/null +++ b/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-1.0.6-build-with-cargo.patch @@ -0,0 +1,21 @@ +For USE=debug to work, portage needs to run cargo_src_compile(), but if `emake` +is used in src_install(), it will trigger a rebuild without debug. If +cargo_src_install() is used instead, manpages and symlinks won't be installed +and the binary would have to be moved since there's no way to make cargo install +to /usr/sbin. So remove $(PDATA_TOOLS) dependency in Makefile instead. Might as +well patch out $(STRIP) too. + +--- a/Makefile ++++ b/Makefile +@@ -56,10 +56,9 @@ + + MANPAGES:=$(patsubst %,man8/%.8,$(TOOLS)) + +-install: $(PDATA_TOOLS) $(MANPAGES) ++install: $(MANPAGES) + $(INSTALL_DIR) $(BINDIR) + $(INSTALL_PROGRAM) $(PDATA_TOOLS) $(BINDIR) +- $(STRIP) $(BINDIR)/pdata_tools + ln -s -f pdata_tools $(BINDIR)/cache_check + ln -s -f pdata_tools $(BINDIR)/cache_dump + ln -s -f pdata_tools $(BINDIR)/cache_metadata_size diff --git a/sys-block/thin-provisioning-tools/thin-provisioning-tools-1.0.10-r1.ebuild b/sys-block/thin-provisioning-tools/thin-provisioning-tools-1.0.10-r1.ebuild new file mode 100644 index 0000000..235fcbe --- /dev/null +++ b/sys-block/thin-provisioning-tools/thin-provisioning-tools-1.0.10-r1.ebuild @@ -0,0 +1,185 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +if [[ ${PV} != *9999 ]]; then +CRATES=" + adler@1.0.2 + aho-corasick@1.1.2 + anstyle@1.0.4 + anyhow@1.0.79 + atty@0.2.14 + autocfg@1.1.0 + base64@0.21.7 + bitflags@1.3.2 + bitflags@2.4.1 + bytemuck@1.14.0 + byteorder@1.5.0 + cassowary@0.3.0 + cfg-if@1.0.0 + clap@4.4.16 + clap_builder@4.4.16 + clap_lex@0.6.0 + console@0.15.8 + crc32c@0.6.5 + crc32fast@1.3.2 + data-encoding@2.5.0 + downcast@0.11.0 + duct@0.13.7 + either@1.9.0 + encode_unicode@0.3.6 + env_logger@0.8.4 + errno@0.3.8 + exitcode@1.1.2 + fastrand@2.0.1 + fixedbitset@0.4.2 + flate2@1.0.28 + fragile@2.0.0 + getrandom@0.2.12 + hermit-abi@0.1.19 + hermit-abi@0.3.3 + indicatif@0.17.7 + instant@0.1.12 + iovec@0.1.4 + itertools@0.11.0 + lazy_static@1.4.0 + libc@0.2.152 + linux-raw-sys@0.4.12 + log@0.4.20 + memchr@2.7.1 + minimal-lexical@0.2.1 + miniz_oxide@0.7.1 + mockall@0.12.1 + mockall_derive@0.12.1 + nom@7.1.3 + num-derive@0.4.1 + num-traits@0.2.17 + num_cpus@1.16.0 + number_prefix@0.4.0 + numtoa@0.1.0 + once_cell@1.19.0 + os_pipe@1.1.5 + portable-atomic@1.6.0 + ppv-lite86@0.2.17 + predicates-core@1.0.6 + predicates-tree@1.0.9 + predicates@3.0.4 + proc-macro2@1.0.76 + quick-xml@0.31.0 + quickcheck@1.0.3 + quickcheck_macros@1.0.0 + quote@1.0.35 + rand@0.8.5 + rand_chacha@0.3.1 + rand_core@0.6.4 + rangemap@1.4.0 + redox_syscall@0.2.16 + redox_syscall@0.4.1 + redox_termios@0.1.3 + regex-automata@0.4.3 + regex-syntax@0.8.2 + regex@1.10.2 + retain_mut@0.1.7 + roaring@0.10.2 + rustc_version@0.4.0 + rustix@0.38.30 + safemem@0.3.3 + semver@1.0.21 + shared_child@1.0.0 + strsim@0.10.0 + syn@1.0.109 + syn@2.0.48 + tempfile@3.9.0 + termion@1.5.6 + termtree@0.4.1 + thiserror-impl@1.0.56 + thiserror@1.0.56 + threadpool@1.8.1 + tui@0.19.0 + unicode-ident@1.0.12 + unicode-segmentation@1.10.1 + unicode-width@0.1.11 + wasi@0.11.0+wasi-snapshot-preview1 + winapi-i686-pc-windows-gnu@0.4.0 + winapi-x86_64-pc-windows-gnu@0.4.0 + winapi@0.3.9 + windows-sys@0.52.0 + windows-targets@0.52.0 + windows_aarch64_gnullvm@0.52.0 + windows_aarch64_msvc@0.52.0 + windows_i686_gnu@0.52.0 + windows_i686_msvc@0.52.0 + windows_x86_64_gnu@0.52.0 + windows_x86_64_gnullvm@0.52.0 + windows_x86_64_msvc@0.52.0 +" + +declare -A GIT_CRATES=( + [rio]='https://github.com/jthornber/rio;2979a720f671e836302c01546f9cc9f7988610c8;rio-%commit%' +) + declare -A GIT_CRATES=( + [rio]="https://github.com/jthornber/rio;2979a720f671e836302c01546f9cc9f7988610c8" + ) +fi + +inherit cargo + +DESCRIPTION="A suite of tools for thin provisioning on Linux" +HOMEPAGE="https://github.com/jthornber/thin-provisioning-tools" + +if [[ ${PV} == *9999 ]]; then + EGIT_REPO_URI="https://github.com/jthornber/thin-provisioning-tools.git" + inherit git-r3 +else + SRC_URI=" + https://github.com/jthornber/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz + ${CARGO_CRATE_URIS} + " + KEYWORDS="amd64 arm arm64 ~loong ~mips ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux" +fi + +LICENSE="GPL-3" +# Dependent crate licenses +LICENSE+=" Apache-2.0 BSD GPL-3 MIT Unicode-DFS-2016" +SLOT="0" +IUSE="io-uring" + +PATCHES=( + "${FILESDIR}/${PN}-1.0.6-build-with-cargo.patch" + "${FILESDIR}/${PN}-1.0.10-stdsimd-fix.patch" +) +DOCS=( + CHANGES + COPYING + README.md + doc/TODO.md + doc/thinp-version-2/notes.md +) + +# Rust +QA_FLAGS_IGNORED="usr/sbin/pdata_tools" + +src_unpack() { + if [[ ${PV} == 9999 ]] ; then + git-r3_src_unpack + cargo_live_src_unpack + else + cargo_src_unpack + fi +} + +src_configure() { + local myfeatures=( $(usev io-uring io_uring) ) + cargo_src_configure +} + +src_install() { + emake \ + DESTDIR="${D}" \ + DATADIR="${ED}/usr/share" \ + PDATA_TOOLS="target/$(usex debug debug release)/pdata_tools" \ + install + + einstalldocs +} diff --git a/www-client/chromium/Manifest b/www-client/chromium/Manifest index e160a61..98f981a 100644 --- a/www-client/chromium/Manifest +++ b/www-client/chromium/Manifest @@ -1,28 +1,33 @@ -AUX chromium-105-protobuf-RepeatedPtrField-export.patch 682 BLAKE2B e67ff20391876c24fd5a268fda448190dd7dcf54e13deab21313775efd030c6072afa558d4cd446c3cdf476ee1e2bee50308ca5ef1d7dfd31759e445ae6f005a SHA512 31f1e0263916f460ca72d719c6d79bdad1840d36be13214cf0a3c16283b42f0e5791cb0f0fa07b97a6979025791aa8cb0dd71671de953d6b13106bee6f458af6 -AUX chromium-109-minizip.patch 6865 BLAKE2B e7b73fa960b695b352d81f1e3cda8ad11d8a9d55633747ac5f2e848c94d66b7b504dd9967c51feee62c1c4bd2316c4e4aa6028ebdba446b57bfd81abd3989214 SHA512 bf8f7df347d94c7782ab2f7764010ad0f134e184cfaa21488ee11b2392697c3a83a0fbd801454dc773232c5ddb263e7564c149b66f110580ebd66305ff02dbe7 AUX chromium-111-InkDropHost-crash.patch 1114 BLAKE2B 2481e068e77f28c2ec0cfbb55641462e7a3f81e8ae719fe797a44a9385898afbbedb129a5138f54fc46b4b0f533a1c6cc43ac76461f6aebeb670ff8e195c38d1 SHA512 13ca2958c15c2e9a571cff588cabb6756e14180136f670112f6e406a3cb7f8661e78fa053e821f4a3f48944f024d580ddcb14e4be84a129b873e637650cb360f AUX chromium-118-material-color-utils.patch 2088 BLAKE2B 9776e46268b427d5ac651a9e509c392e79fe420b569146b4839d22f1b9c524a5626a023dab12b3ff8ec8db2ceb7047a2da1933af168294ce6aaeb437eeafa8dc SHA512 a7934f42f9b2eb3eefe35c2363d28a4d653730f9068f40fb9ee54ee25051be23fbfcda3407743da20b7a2bf36aa6c97ade371ecc6df59c2e739616f4622129c7 AUX chromium-119-minizip.patch 6867 BLAKE2B 50dcf02d6095fc75c2033afba39bae6386e4bf9d34e3a284e6eb1ba949cbe983c4ef546abc4e475f2433d608676d94855103b49bd78916085170e0cb5475ec6e SHA512 6a701b8b34e9b56d1ff03f6cc1c8542568c543299f9b60648cf1aa7d56e5958e293057d3f251634479841724e179733bd3ed2320ee5fbb56e1cb66b8fc7f70fb -AUX chromium-122-VirtualCursor-std-layout.patch 8472 BLAKE2B 872bd935eb702967dbbaf6045722f6f34b768ff607c6a53c42b92fd38dad6a8dc9d286f0e1f05ff30f03d402a04ee196f02d5fc977ea97b8ea1245c0aae1c428 SHA512 bdcaa80e36e0f9938b7e2f782baf1de8714cd1f5a032cdabbd885678ff2c77a98c69d4436cb01726e160bdb3ef4b10155f3a3b92b8b54a0726a25cc8c65b1393 -AUX chromium-123-EnumTable-crash.patch 2978 BLAKE2B 44b18e702b82f4839a8a4cc639d1f91b6a4ed96fe266a4ee690c766361c36e7bce49e32455388eacd76ad408b72e6d458d9653a841b8483afa739df163621730 SHA512 5b56cb55aa1aef874963ce656ed610eddd0e09d6ab320f55ecac609c5ee26406c67295a96adcbcc6c2f4e1d86df46da0610c555a61c65215a486f448541fe136 -AUX chromium-123-compiler.patch 11238 BLAKE2B 2cd6a2dc550f952685db63062d7d90f688d29fb391b52646880c50d1884913a29e88f7e706a16b8a2954373f020d8488995dd9ced5c3a4aff044774a6b5a2320 SHA512 709ad3c413308a7e50ae95b433f52868c93a96682dacdeb82310e166af0b56afa7b98a1c0dfd147a34be0d9ba78c174ff547d95b429b4734aa3a11b736b3cf9f AUX chromium-124-metrics-histograms-nodepotbin.patch 533 BLAKE2B 2dee74b4c10b4d8280ba0b0dcdea0c8f7896422c190bbf31b7ee147a6ac81b34033a156c9fd66cf8e875aaa02a8ebeb4e04d7164f7e6701836539300297f25f3 SHA512 a1ecd84d7433542779da17e79fe73a63f4bff94c49b13c51947ade9ed27f82e8fca94b08d628e7cd8853c2e9ffc11078b02fab81fba98635390805b0230035f4 -AUX chromium-125-compiler.patch 11174 BLAKE2B 72d9ba637c1d726edcb4a9ff695b34f6a70e39c775ac34bc6b3bd9151ac390c9840429bef82bac1ff32502dd5dee49754bbc868eed1c28562b07ca33cf136189 SHA512 7e17a17947025ae992882828ccea0dd85d0a749c7dd27b1423ea436f0da379fe846b4808df6186f74df161f69c6b8802881ab3569511580e121aea359c4f90e3 -AUX chromium-125-revert-8a3bec6.patch 17037 BLAKE2B d2fa1845fb0a634428ff676c4cbec59d37bd1b668e1d80d17bc0a040a049160186132ac91d2202719e4936f241c3362e664d877401742b0755c49f388c2afe90 SHA512 04c2e0b6ebdc88d079f0caa6a101f306073c65c294ab8ec2bb6ab4eba216eb9fbaf5698e5db4f6c489472c5e1b9621f05bd3448f6ae7c68a23e82371342e62ab -AUX chromium-126-EnumTable-crash.patch 2981 BLAKE2B 76b2ca1dbe45c10a7c37479d1b854b6f71dc50e3a1fa6a7d477af2a7311c2f5b6330e9a58e12d471f610490d9c9f40e4d756a4c067f896b19e72f86f35163a80 SHA512 87b392dcaf372b9ee266831c4af2876fdeee3030649ba982d0e8006964af77bf3fb8f9f8b86e2e60f29ebf054c00269410f593413d96cd257c1da8640a1c9a77 -AUX chromium-126-compiler-r1.patch 11307 BLAKE2B 84de23b6497871370dde01ea476b22eb9039f780713143efccc0a5d6a607f3f9180ba10d0da10e95d9289a72751a40a62a3ec5aca847ba72c6bd88fc5d1a8432 SHA512 d44488f1ae747a4d2449624702c0265d618037b3a71f078a9ea13ff45528e1bf00348d2d12a38cac7bffc5cb8898b14f9a5f3a0681f59b11b70b38e47e84daf0 -AUX chromium-126-compiler.patch 11310 BLAKE2B 037b37d78669acc23c32cd6f643cba7f2e4d4cc2990d13bdea1fd9e3328876941fb557924026730fe0d75fa96a873d6cec03539aca277dc22849063b4c5be432 SHA512 26ac52b4563f200f10680a0161516fd4d2365aea2807db28028f40aa74860ddb8578367f15566845783c22ccb5fe6ff5f03012a3ee31f1771b02607c2758bc9d AUX chromium-126-freetype-blink.patch 532 BLAKE2B 68cebd58a1e00b2603c3aec90339d5b02b2aa504ddad61833016cc65386b992fbc8e91538b13f9b6fc24d4c4ac1da6c0c31061e8fc7638a70b3716971d90a0d5 SHA512 e2bda2f8338bcd8bf7d45d7b8fb680793efce88698ff84b659b60494fce0ae31375a014e0b0815cabab9ddafc55224769f568f64f8d220392c53b07051d66be7 -AUX chromium-126-use-oauth2-client-switches-as-default-r1.patch 1089 BLAKE2B 42f9b433b05c979bc6b689392e78f2207b8a2fa0131cb9b5d12198fb289f0e16d39bd4b1fc53bf0f3b5e5b9094e21c1838920c41d975aac34749f6c4c8c9ac65 SHA512 29113c2454f02b9c93553430de256df410c6cf103dbb10162693c64b045356c762c655e39f771236b8a34afd9b0b1a1f1d3405290a663e1dc2f221d895fdafdc -AUX chromium-126-use-oauth2-client-switches-as-default.patch 976 BLAKE2B 87ab9134e56e99ca8c52edfdf7afcc77f827532a24b96b44b75fa702d22296d60b850332982bab29499163050d89b8c37194db83f4c00b3a42b2441327e4366f SHA512 7dbe772471c2c0eddb5babca2f291cf7ac45ae0ab4931e3e3afed5586e8efdd23536161d2e74bb59bfd67685892966fd65e553acbf82f03df417939c3021e938 +AUX chromium-131-use-oauth2-client-switches-as-default.patch 1194 BLAKE2B 040f8161c659d015bfda3f8f2f9c3f904b0b1318233569550c80b4c1a6cfeca8e3d39998e8ebec87880948ec2444214fd0551f0a65111363c3c40fe3c0d717c8 SHA512 20621cc7ee69bb0e53d1806f6e78381357fb31c99d339ed9b385a669dcdc92b800f2b3c2d6833bb36e94348793afe790a6f3f3d5d2f330c57407305fa8095a5a +AUX chromium-134-EnumTable-crash.patch 3068 BLAKE2B 8b3bad8e20d6c3477495792279b1c58aa599e5934380d6efb26285a4348be8b98fe5869dc9ce9c83049e35f20f73ab9de7eb819002e6753aecd16ef7de734194 SHA512 5cd2da1407d150218595b3da7e76a2df7e12675e91c9bc2dce793f3801ed53705dada351865ead578ad6516ee5d19423f25021ab213bd9305eea8860f92f42b0 +AUX chromium-138-gn-exec_script_allowlist.patch 1828 BLAKE2B 9717369b1e89321d06c94757bab5e281b06d8f711f418c33cf68d1d6c2027b2743bd92d1aee97747546030902359766352fa06793b45485b5a1ba30fb7898436 SHA512 dc117e296daa8a02252450078c5aa25cb8dd447a61fe06b2f430708c69f8e429be99ba808f36464e57f8be0b5855be4c83d9e576a9e2d4282fc8bce213787b2d +AUX chromium-139-compiler-r1.patch 17928 BLAKE2B 6a4e3b57ad55b65e50c361b0dff4111c6a3fbffdf2b9b8d9799f537197ed7b2f718641b67d483f7a1284e032d99a290a31d238dcce619efa4dba432239be28c5 SHA512 5e8293f75bfa6d3445b9084a85cd19e6b41bf1f1bc47bd2d5559eb5d85d14709a0f3fafea7d9a6fec3c87af0c596161621e451a529572f912d16537d6925113e +AUX chromium-139-compiler.patch 17165 BLAKE2B b9ffbe4bb34d21819ea0ff3f2447e9e9ea56b93745d6e85e1e924d5fd05b7675bc9ef97be7f37c87049a892a6a82a5ae8daf51aa99332fe3e88fb1265b5f288e SHA512 0ef18d5a6856a96966b44085cf983c5e657533e21940ed830c5bf338908f2d495fab10d0c633c8f1a5017293e0bb5ca1ffcaaa3e6f16a5b5c4eaf849ab9af786 +AUX chromium-139-mv2-ungoogled-r1.patch 7358 BLAKE2B 5f48c890e4fe1c22071ee9e4275203318b90143d9e4996688409f7df0232b3dc3dde7ef1a9c55ef75ac83c2aa411ed687321ac54da466f6b2c70b34fa6bcfd92 SHA512 d30c4b341774c2afa95ca466d879ccad38ee599476b56f30a5fdbfcd014c8ef463cc38a032af344e0d93cd958468305de24b9ec7ca49834be598bf92578b80a2 +AUX chromium-139-mv2-ungoogled.patch 7365 BLAKE2B bec1adf79214352df32e2e7dc2ba27b773e840f8d8ef70d79096b3bf5822f5116591dae436bcb8caaf0ea3669004a9638719ec4947a704d536df3b83af05da21 SHA512 857f2ad5b4f0b9ede6018142fbced266fb09065f35f1609e66f6da0e128d40917f242923516c048d9341debdb02ef4acee33181eefcb51e797aa0754f1c94821 +AUX chromium-139-protobuf-RepeatedPtrField-export.patch 776 BLAKE2B aa491b162f812832eb03785fa14e969f87fffbaa0d61d04c3a16132f84e407aee49fdcd1e83d8ca944923f6631abdf22c13a5a52353e33f381bf208ee3401934 SHA512 a3e1e70876176ee239f548cf92da9f5bf678d568a50b3cb1e64bce7d1c61be2d3ee6edd0e6189e6cc2a21f59f3b0393280b280fdde5e4c3c0337a2327f6a515a +AUX chromium-140-compiler-r1.patch 17997 BLAKE2B b116858756b692550bb087497a5c3492307e4387390c6cd7b7a8e71862398baaa229116e3d8dad3300c594a5347b625e10098bc52f62d9d12540b3d0f6209f85 SHA512 296685ba8dc911029e46369b506d3478547208e563a060ade3a86b14fdc9b5074d85a9e6a55d6525ba7514f6133b1b773cc1b863449f3fefb3e0875456904d75 +AUX chromium-140-compiler.patch 17875 BLAKE2B 92f700b2c0b40c382e588eb41a965947b2e45f2893c7991a2749057c39b2aa16b9a88ad086d06ef89b11705ff2b0eb356f307910d196fe39decd7f327347f8fa SHA512 58e1240cdea826b0679db67f70a34b1c3e7e667415e0a98b8d33ce6f3125cdc1c0e2a60ae8a363964e0407e12e03fd4b3dc652f45da0f3a70dc959d53355ad19 +AUX chromium-140-gni-lf.patch 1242 BLAKE2B 3686048909b6f4417951c1709b3d757ec6e732b1ed12e757e7004948169af06f6c747d44cc6b29e56e41d495b64d8ca9e4b4d9211b824f6794d70eb23c972a88 SHA512 8ad0b2c0184c86081e8693ac4c533e962707409b77256a222dab7116dd38dfec55a813c52ff294aca8c81334579dbf463e0355a2addb5323a896946f5069f403 +AUX chromium-140-rust-1.8x.patch 626 BLAKE2B 3dcd6ace2bd8e8072e0a12eb8035bfc060f59fe55b20e623ff16897bf79596991773eab4f1e7a1d1b8334a2b3193f208524f4397ba1ff10e78a70f94c7ff7723 SHA512 ecc8cdef7409f6fc2a0af5ea8f9909d30b267457120e0a87702726a213446607c9473b521420d6738d1113c6697bd0a0716d9a2097d70b9d396b3dc35d7c7660 +AUX chromium-141-compiler.patch 18130 BLAKE2B 371c035b27eabf9724a195e5d8d5a9472d0e6e7161484147da0e1230a30381b056bb195bdd8b0d354b0c5c0d0dc4712fbe0a75c45f8e189800181e7016dd90a5 SHA512 209c2398f646b07e2f0a742709e66db11fae169d5e10a1a360821f416c62e529b2516a1a61d05b753ade25f35956c72012d874fb94d6f8c1e7cbbff58cbabb34 +AUX chromium-141-mv2-ungoogled.patch 7180 BLAKE2B 5d4c0aa6c85aa62d77691b64ef9f99054977674fd05462f7eaa5612f8372ed0c9f8a92f480bcf6a152657c21f266f1449814f070f6510773214e2b55a8a868f2 SHA512 7dd646188b4db14cba565a3a91dbb8a0c101c74d46b23d43647dde57ba1abef80196d46623f7f66049fb80ac14c3dff872cf0bb78a7a59e073701899f8b235fb +AUX chromium-142-blink-observable_array-css.patch 631 BLAKE2B 24b1cc54353bcb61da6e7986ee2d7c7e64ec53c296d3bd346287bf354465ac36928f0f989f699624a7dff18f73aa3141e3d4d2860c4044f99231bcb0c611b731 SHA512 2812e8def0186293889067b5b7a65860e9d852f3b1661c3306101b7f97a38ea9c383dab08cbaa23a00212ccd0c3af7eeb73c1e5029f4f7c9866707b14541ada8 +AUX chromium-142-compiler.patch 19923 BLAKE2B 02a8d8708291b35902019ce37f2b790f336e7e4fcfc89aabdedfc0e088cf4dde87244f93381e8a5c5b71a22f2aa6eaa92d93afdec92b22a8a0714cb54067a1e5 SHA512 af051a3691693a6cc39fa6b0f7a8084a019cb72e9b9b49d1aff48ef2c32bdcbc68144ef8ecc7375702a7d5433d443c7ae33d10bd633565cfd4b2316b93375319 +AUX chromium-142-rust-1.8x.patch 644 BLAKE2B b1d78eb9693a7b73aace188d1c6d1ef634eeb4a8c4d15f4b9be8535a00e8d30f3c5005e487870bb597633bb86413c098f588c72d70a4fc931f7123aafeb68a65 SHA512 38472810fbafd948df461ff20b0a8065bbc7cd044d1e54bf332ed92c8546524487eec929c0369957fc18046ca95687b906b3104d3c3e56ed585b44308cbeaf4f AUX chromium-browser.xml 407 BLAKE2B 168d78b0855546ca559cfb51aff0bc85d5e6ae974c25eb76e4a02f6d11659489c6e40397a0b2f7bc1fda336fd2c6dd8c863fccc3340719210b41c7fef51927f4 SHA512 b767fb4fd1925029d95560fc14cb7ab12ae43b2fe923e92d75e733b9723cbe1dcdf6df041a2b62554e98b79b47ef3f6028c773e72e6fd53166a021d49657aeca AUX chromium-cross-compile.patch 323 BLAKE2B 8d5091ce5287422c9688ede2563360a96b8bd34b9750dc1c8f0b6ca9aeff2c066fac2da169396baa131d971c087c78f9af53999df0e102d1f57176f5e8d3dd57 SHA512 06d3afc1aa19e57daac0e4bad37e1f365a68408240430e5e818e5a4f12e3b7519214eafa463633e447e7029f4ae13ea864ca347ad1fac117702a0be88718a954 AUX chromium-launcher-r7.sh 1631 BLAKE2B ae28d758264446511fd2b64ba69fe920144b351e8833e0e98f43d00633e850094c288b5d97d1a84801ea13aceb294623692c86c1b9be5811b7b97fa8a07a1ecd SHA512 1e97f8394bd8bb4b29570b1b85176efe6258314a596f079bee1c4018113e0023aa54a93690ba8de2a00d127af10dbe2cc3fb3127b72b841c6f28f9e7bed820e0 AUX chromium-shim_headers.patch 1510 BLAKE2B 9716cd250b249c6255aca01a385ef8a2a6f1df9ea3cf7499715543c14f8be62fd323b6048b890aa2be45891e7a765d92de3f41c3b3a88c08dae4b806c048e20f SHA512 c74bcf690a41b4f9b364477d23408d493aa674e3bd014940098a594471297c2a425241f908510061b5f11c9cfe009c4a803370edd757d3c0ab8d9c0cc128135c AUX chromium-use-oauth2-client-switches-as-default.patch 1085 BLAKE2B baf3c463305934c126af4f7c5be305863edc7eec3add5b5ada30565b49b5944021eb40f1a9643e7eec3f973c502d9b02426f00b760570fcea5f1509219e41c6f SHA512 fe2878ee45778bac894ea17a668511d27ad2ca40988d5f11439790b700bfefd6560f3931415b4e6c543fcbbfc7cfef55cc757ed4ace1d111039ae78c46b81945 AUX chromium.default 148 BLAKE2B 5ee5b582c59a6e4bef87bbb0e232e2470ad412b1fbbb3b9af6ef7153edb55c5b9080cc16a5a115b0c5b3c381aa87ce57a7b12bdd2070e67dac10a6c2995ddbaf SHA512 0d4849e03592fb58b05e62a43021eca7e61615616c8907c3b2e445402e03adaf9e8fa25b0a745d6c31eb037456215cc02b59e345a3a06d932e76cf990c92d739 -DIST chromium-126.0.6423.2.tar.xz 3435816032 BLAKE2B bebc1cf6dbcf74b5080e202732409ad05bd3936083034c4d8608a9f04355564ddab0551b26e4ded783a4364e3cd30c809e749968140d3138c64d360015d24c67 SHA512 d062f5b0c0aa9ada556e6ea4fcd38141abb72920bbe0a6559eb53a4c11800cf08ee426675de0c531a008074cd05c547fb3d4e7b6951472e2d785441767f0822c -DIST chromium-126.0.6452.3.tar.xz 4027440964 BLAKE2B bb8c2d6bab6c1a806fce0bf523874d8b9d1132a7bd84b74817c73e8483d79e28763a976758aba56ad33f718aaf26e68fd518ddb2c37affc7482445f2463d3840 SHA512 5b04b3500406a6114e7d85e5d0585dc5fa719dd89099726cbc9af1d6015c0dcee0b24fa0c6c2e09f1a686ba575da70806798b0df41df43707b119c649c1d98dd +DIST chromium-141.0.7367.0.tar.xz 7401337484 BLAKE2B 901201cc8d1f2fd320367f2023feb1ee53d1305209e3462a79673ed5894b35b04a490b65ceb05d7f745983b62d05cf963db2d5b85b18b35ba009bf448e0afc85 SHA512 c6289f9d331d2419a03e202b0346e9a1cd394e1b7be4ae50d18f50e70f45afb44b2938c83d8dbd3fe37f31a3ce6c6a0d1036d1d18e77f3648d9945338bde94a1 +DIST chromium-142.0.7393.6.tar.xz 7482130636 BLAKE2B 5f6c584fda683a95200bae72b7d65aab305d76ab947fc2a22b18f9f95b29443d6b8f4e634bc00c55384595b725b7212ecf92722af25bf6af1249df0e6dc8db34 SHA512 78561a9d90e69fa094f59d9e63d7efaf17717171a025b8ba9b5c43691ebd7ba657cbf79def100d3a5d0770ae01b2bdc6458d0862dd21961f205c5a8d7b7a6976 DIST chromium-profiler-0.2.tar 259952640 BLAKE2B 5e82389fce00b267280d633b26551231c558b80f0c92cd7d60271095a3503365ab673e7a46dc5f74f8a82db1f21262cb24dcc0531d954bab5fb3b175dab3394d SHA512 9fa89a5ab728419683e7495ae676567480987d68a2d589f2aa97bfcbcf123f3c8f97f8bca5f65e5e3f6e41475535add473ded83b9c7a33bb4746a9d05b298a6c -EBUILD chromium-126.0.6423.2.ebuild 39606 BLAKE2B 763d0a738d13e24ca82f4fe7dcdfe70e7384998c327cb386faa874d0161736d581f8f9ce6a52a6be7329d68c4639b313a69ec1d6bdebb408c364691423d0d77d SHA512 a33c752707e8769841575b3dee75ba51831362390fb70e119136b4c3eb7d550cdcbb2f23b0e092335a252e975f2ffb1c1a29fd1168978eed97325b69a80e2ae3 -EBUILD chromium-126.0.6452.3.ebuild 39627 BLAKE2B 460d4a4c341d1831649b69495b092503ef5381d3007739ed18ee9064ef5d09a5a1fd753797d65fa3888190b1619391d22f71d5414701c94b2373d8f9241e646d SHA512 5f09db1c8fabc17c55768b0b37f502cfc02d2958d06c483e9210f414e662f5a009bc796b6e37c189dd3b2d45104627b9691d64a7975c8e097b5a078eb8e96c70 +EBUILD chromium-141.0.7367.0.ebuild 40692 BLAKE2B bb1bdc0f747f5f5eb0ceaacf4d00360758877289d8552cc8b48fb7f0cc12dc21da6f973890bc22457de95f8169cb69455bd64b35904f00b5ca1e15c9743915a0 SHA512 abda5deb9db400528deb2a5b460cd96bd7cc407a96d734cde71462607072a82ec1ce8059b010b014e89ed7cad6b5649790e9eaa5a42ec6b5105ca5ada056a6fc +EBUILD chromium-142.0.7393.6.ebuild 40694 BLAKE2B 3b3d20c639ed3e604dbff478eeb486c5819915ed1177297a667d0581468a1ed992019935015e37c3e01ef57b93987402ddf6296e62078f5d6d1906084194d810 SHA512 f33c79537e9a39e1685b9d3159d860e7fdec083c8dbedccfd18dc333fa05ce8acbe619368d9ee033b439b075f58857d5e9e749fadb20db7b3679e990933660f5 diff --git a/www-client/chromium/chromium-126.0.6452.3.ebuild b/www-client/chromium/chromium-141.0.7367.0.ebuild index c69ebfc..11ff367 100644 --- a/www-client/chromium/chromium-126.0.6452.3.ebuild +++ b/www-client/chromium/chromium-141.0.7367.0.ebuild @@ -2,10 +2,12 @@ # Distributed under the terms of the GNU General Public License v2 EAPI=8 -PYTHON_COMPAT=( python3_{9..11} ) +PYTHON_COMPAT=( python3_{12..13} ) PYTHON_REQ_USE="xml(+)" -LLVM_MAX_SLOT=17 -RUST_MIN_VER=1.72.0 +LLVM_COMPAT=( 20 ) +RUST_MIN_VER=1.87.0 +RUST_NEEDS_LLVM="yes please" +GN_MIN_VER=0.2235 CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he hi hr hu id it ja kn ko lt lv ml mr ms nb nl pl pt-BR pt-PT ro ru sk sl sr @@ -13,8 +15,8 @@ CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu VIRTUALX_REQUIRED="pgo" -inherit check-reqs chromium-2 desktop flag-o-matic llvm ninja-utils pax-utils -inherit python-any-r1 qmake-utils readme.gentoo-r1 toolchain-funcs virtualx xdg-utils +inherit check-reqs chromium-2 desktop flag-o-matic llvm-r1 ninja-utils pax-utils +inherit python-any-r1 qmake-utils readme.gentoo-r1 rust toolchain-funcs virtualx xdg-utils DESCRIPTION="Open-source version of Google Chrome web browser" HOMEPAGE="https://chromium.org/" @@ -24,7 +26,7 @@ SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P} LICENSE="BSD" SLOT="0/dev" KEYWORDS="~amd64 ~arm64" -IUSE="+X component-build cups cpu_flags_arm_neon debug gtk4 +hangouts headless +js-type-check kerberos libcxx lto +official pgo pic +proprietary-codecs pulseaudio qt5 screencast selinux +suid +system-av1 +system-ffmpeg +system-harfbuzz +system-icu +system-png vaapi wayland widevine" +IUSE="+X component-build cups cpu_flags_arm_neon debug gtk4 +hangouts headless kerberos libcxx lto +official pgo pic +proprietary-codecs pulseaudio qt6 screencast selinux +suid +system-av1 +system-ffmpeg +system-harfbuzz +system-icu +system-png vaapi wayland widevine" REQUIRED_USE=" component-build? ( !suid !libcxx ) screencast? ( wayland ) @@ -64,7 +66,6 @@ COMMON_SNAPSHOT_DEPEND=" >=media-libs/libaom-3.4.0:= ) sys-libs/zlib:= - x11-libs/libdrm:= !headless? ( dev-libs/glib:2 >=media-libs/alsa-lib-1.0.19:= @@ -110,10 +111,7 @@ COMMON_DEPEND=" x11-libs/cairo:= x11-libs/gdk-pixbuf:2 x11-libs/pango:= - qt5? ( - dev-qt/qtcore:5 - dev-qt/qtwidgets:5 - ) + qt6? ( dev-qt/qtbase:6[gui,widgets] ) ) " RDEPEND="${COMMON_DEPEND} @@ -122,7 +120,7 @@ RDEPEND="${COMMON_DEPEND} x11-libs/gtk+:3[X?,wayland?] gui-libs/gtk:4[X?,wayland?] ) - qt5? ( dev-qt/qtgui:5[X?,wayland?] ) + qt6? ( dev-qt/qtbase:6[gui,widgets] ) ) virtual/ttf-fonts selinux? ( sec-policy/selinux-chromium ) @@ -135,9 +133,9 @@ DEPEND="${COMMON_DEPEND} " depend_clang_llvm_version() { - echo "sys-devel/clang:$1" - echo "sys-devel/llvm:$1" - echo "=sys-devel/lld-$1*" + echo "llvm-core/clang:$1" + echo "llvm-core/llvm:$1" + echo "=llvm-core/lld-$1*" } depend_clang_llvm_versions() { @@ -163,18 +161,18 @@ BDEPEND=" ') >=app-arch/gzip-1.7 !headless? ( - qt5? ( dev-qt/qtcore:5 ) + qt6? ( dev-qt/qtbase:6 ) ) - libcxx? ( >=sys-devel/clang-13 ) - lto? ( $(depend_clang_llvm_versions 17) ) + libcxx? ( >=llvm-core/clang-13 ) + lto? ( $(depend_clang_llvm_versions 19) ) pgo? ( >=dev-python/selenium-3.141.0 >=dev-util/web_page_replay_go-20220314 - $(depend_clang_llvm_versions 17) + $(depend_clang_llvm_versions 19) ) - >=dev-lang/rust-${RUST_MIN_VER}[profiler] + dev-util/bindgen dev-lang/perl - >=dev-build/gn-0.2122 + >=dev-build/gn-${GN_MIN_VER} >=dev-util/gperf-3.0.3 >=dev-build/ninja-1.7.2 dev-vcs/git @@ -182,14 +180,13 @@ BDEPEND=" >=sys-devel/bison-2.4.3 sys-devel/flex virtual/pkgconfig - js-type-check? ( virtual/jre ) " # These are intended for ebuild maintainer use to force clang if GCC is broken. : ${CHROMIUM_FORCE_CLANG=yes} if [[ ${CHROMIUM_FORCE_CLANG} == yes ]]; then - BDEPEND+=" >=sys-devel/clang-13" + BDEPEND+=" >=llvm-core/clang-13" fi if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then @@ -234,13 +231,13 @@ needs_clang() { } llvm_check_deps() { - if ! has_version -b "sys-devel/clang:${LLVM_SLOT}" ; then - einfo "sys-devel/clang:${LLVM_SLOT} is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 + if ! has_version -b "llvm-core/clang:${LLVM_SLOT}" ; then + einfo "llvm-core/clang:${LLVM_SLOT} is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 return 1 fi - if ( use lto || use pgo ) && ! has_version -b "=sys-devel/lld-${LLVM_SLOT}*" ; then - einfo "=sys-devel/lld-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 + if ( use lto || use pgo ) && ! has_version -b "=llvm-core/lld-${LLVM_SLOT}*" ; then + einfo "=llvm-core/lld-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 return 1 fi @@ -249,7 +246,7 @@ llvm_check_deps() { pre_build_checks() { if [[ ${MERGE_TYPE} != binary ]]; then - [[ ${EBUILD_PHASE_FUNC} == pkg_setup ]] && ( use lto || use pgo ) && llvm_pkg_setup + [[ ${EBUILD_PHASE_FUNC} == pkg_setup ]] && ( use lto || use pgo ) && llvm-r1_pkg_setup local -x CPP="$(tc-getCXX) -E" if tc-is-gcc && ! ver_test "$(gcc-version)" -ge 10.4; then @@ -261,12 +258,6 @@ pre_build_checks() { if needs_clang || tc-is-clang; then tc-is-cross-compiler && CPP=${CBUILD}-clang++ || CPP=${CHOST}-clang++ CPP+=" -E" - if ! ver_test "$(clang-major-version)" -ge 13; then - die "At least clang 13 is required" - fi - fi - if [[ ${EBUILD_PHASE_FUNC} == pkg_setup ]] && use js-type-check; then - "${BROOT}"/usr/bin/java -version 2>1 > /dev/null || die "Java VM not setup correctly" fi fi @@ -295,7 +286,7 @@ pkg_pretend() { pre_build_checks if use headless; then - local headless_unused_flags=("cups" "kerberos" "pulseaudio" "qt5" "vaapi" "wayland") + local headless_unused_flags=("cups" "kerberos" "pulseaudio" "qt6" "vaapi" "wayland") for myiuse in ${headless_unused_flags[@]}; do use ${myiuse} && ewarn "Ignoring USE=${myiuse} since USE=headless is set." done @@ -312,6 +303,9 @@ pkg_setup() { ewarn "Proprietary nVidia driver does not work with Wayland. You can disable" ewarn "Wayland by setting DISABLE_OZONE_PLATFORM=true in /etc/chromium/default." fi + + llvm-r1_pkg_setup + rust_pkg_setup } src_prepare() { @@ -319,27 +313,42 @@ src_prepare() { python_setup local PATCHES=( - "${FILESDIR}/chromium-105-protobuf-RepeatedPtrField-export.patch" - "${FILESDIR}/chromium-126-compiler-r1.patch" + "${FILESDIR}/chromium-139-protobuf-RepeatedPtrField-export.patch" + "${FILESDIR}/chromium-141-compiler.patch" "${FILESDIR}/chromium-119-minizip.patch" "${FILESDIR}/chromium-118-material-color-utils.patch" "${FILESDIR}/chromium-126-freetype-blink.patch" "${FILESDIR}/chromium-124-metrics-histograms-nodepotbin.patch" + "${FILESDIR}/chromium-138-gn-exec_script_allowlist.patch" + "${FILESDIR}/chromium-140-rust-1.8x.patch" + "${FILESDIR}/chromium-141-mv2-ungoogled.patch" "${FILESDIR}/chromium-111-InkDropHost-crash.patch" - "${FILESDIR}/chromium-126-EnumTable-crash.patch" - "${FILESDIR}/chromium-126-use-oauth2-client-switches-as-default-r1.patch" + "${FILESDIR}/chromium-134-EnumTable-crash.patch" "${FILESDIR}/chromium-cross-compile.patch" ) sed -i -e \ "/if (is_clang && toolchain_has_rust) {/,+2d" \ build/config/compiler/BUILD.gn || die "Failed to disable bundled compiler builtins" + sed -i -e \ + "/\`--sysroot\` flag/i\ \ \ \ args += [ \"-I\" + rebase_path(sysroot + \"/usr/lib/clang/${LLVM_SLOT}/include/\", root_build_dir) ]" \ + -e \ + "/clang_resource_dir =/,+2d" \ + -e \ + "s/clang_resource_dir,/rebase_path(sysroot + \"\/usr\/lib\/clang\/${LLVM_SLOT}\/\", root_build_dir)/" \ + build/rust/rust_bindgen.gni || die "Failed to append include dir for bindgen" default - mkdir -p third_party/node/linux/node-linux-x64/bin || die - ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die + #mkdir -p third_party/node/linux/node-linux-x64/bin || die + #ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die + + # I don't know how to do this properly + rm -r third_party/rust-toolchain || die + mkdir -p third_party/rust-toolchain/bin || die + ln -s "${EPREFIX}"/usr/bin/bindgen third_party/rust-toolchain/bin/bindgen || die + ln -s "${EPREFIX}/usr/lib/llvm/${LLVM_SLOT}/lib64" third_party/rust-toolchain/lib || die # adjust python interpreter version sed -i -e "s|\(^script_executable = \).*|\1\"${EPYTHON}\"|g" .gn || die @@ -352,12 +361,9 @@ src_prepare() { base/third_party/nspr base/third_party/superfasthash base/third_party/symbolize - base/third_party/valgrind base/third_party/xdg_user_dirs buildtools/third_party/libc++ buildtools/third_party/libc++abi - chrome/third_party/mozilla_security_manager - courgette/third_party net/third_party/mozilla_security_manager net/third_party/nss net/third_party/quic @@ -393,17 +399,18 @@ src_prepare() { third_party/catapult/tracing/third_party/oboe third_party/catapult/tracing/third_party/pako third_party/ced + third_party/compiler-rt third_party/content_analysis_sdk third_party/cld_3 third_party/closure_compiler third_party/cpuinfo + third_party/crabbyavif third_party/crashpad third_party/crashpad/crashpad/third_party/lss third_party/crashpad/crashpad/third_party/zlib third_party/crc32c third_party/cros_system_api third_party/d3 - third_party/darts_clone third_party/dawn third_party/dawn/third_party/gn/webgpu-cts third_party/dawn/third_party/khronos @@ -419,20 +426,26 @@ src_prepare() { third_party/devtools-frontend/src/front_end/third_party/diff third_party/devtools-frontend/src/front_end/third_party/i18n third_party/devtools-frontend/src/front_end/third_party/intl-messageformat + third_party/devtools-frontend/src/front_end/third_party/json5 + third_party/devtools-frontend/src/front_end/third_party/legacy-javascript third_party/devtools-frontend/src/front_end/third_party/lighthouse third_party/devtools-frontend/src/front_end/third_party/lit - third_party/devtools-frontend/src/front_end/third_party/lodash-isequal third_party/devtools-frontend/src/front_end/third_party/marked third_party/devtools-frontend/src/front_end/third_party/puppeteer third_party/devtools-frontend/src/front_end/third_party/puppeteer/package/lib/esm/third_party/mitt + third_party/devtools-frontend/src/front_end/third_party/puppeteer/package/lib/esm/third_party/parsel-js third_party/devtools-frontend/src/front_end/third_party/puppeteer/package/lib/esm/third_party/rxjs + third_party/devtools-frontend/src/front_end/third_party/source-map-scopes-codec + third_party/devtools-frontend/src/front_end/third_party/third-party-web third_party/devtools-frontend/src/front_end/third_party/vscode.web-custom-data third_party/devtools-frontend/src/front_end/third_party/wasmparser + third_party/devtools-frontend/src/front_end/third_party/web-vitals third_party/devtools-frontend/src/third_party - third_party/distributed_point_functions third_party/dom_distiller_js + third_party/dragonbox third_party/eigen3 third_party/emoji-segmenter + third_party/fast_float third_party/farmhash third_party/fdlibm third_party/fft2d @@ -449,25 +462,25 @@ src_prepare() { third_party/google_input_tools/third_party/closure_library third_party/google_input_tools/third_party/closure_library/third_party/closure third_party/googletest + third_party/harfbuzz-ng third_party/hunspell - third_party/iccjpeg + third_party/ink third_party/inspector_protocol third_party/ipcz third_party/jinja2 third_party/jsoncpp - third_party/jstemplate third_party/khronos third_party/leveldatabase third_party/lens_server_proto third_party/libaddressinput - third_party/libavif + third_party/libdrm third_party/libgav1 third_party/libjingle third_party/libphonenumber third_party/libsecret third_party/libsrtp third_party/libsync - third_party/libudev + third_party/libtess2 third_party/libva_protected_content third_party/libvpx third_party/libvpx/source/libvpx/third_party/x86inc @@ -483,14 +496,11 @@ src_prepare() { third_party/lss third_party/lzma_sdk third_party/mako - third_party/maldoca - third_party/maldoca/src/third_party/tensorflow_protos - third_party/maldoca/src/third_party/zlibwrapper third_party/markupsafe third_party/material_color_utilities - third_party/mesa third_party/metrics_proto third_party/minigbm + third_party/ml_dtypes third_party/modp_b64 third_party/nasm third_party/nearby @@ -511,24 +521,30 @@ src_prepare() { third_party/pdfium/third_party/libtiff third_party/perfetto third_party/perfetto/protos/third_party/chromium + third_party/perfetto/protos/third_party/simpleperf third_party/pffft third_party/ply third_party/polymer third_party/private-join-and-compute third_party/private_membership third_party/protobuf + third_party/protobuf/third_party/utf8_range third_party/pthreadpool third_party/puffin third_party/pyjson5 third_party/pyyaml - third_party/qcms + third_party/rapidhash + third_party/readability third_party/rnnoise third_party/rust third_party/s2cellid + third_party/search_engines_data third_party/securemessage third_party/selenium-atoms third_party/sentencepiece + third_party/sentencepiece/src/third_party/darts_clone third_party/shell-encryption + third_party/simdutf third_party/simplejson third_party/six third_party/skia @@ -536,6 +552,8 @@ src_prepare() { third_party/skia/third_party/vulkan third_party/smhasher third_party/snappy + third_party/spirv-tools + third_party/spirv-headers third_party/sqlite third_party/swiftshader third_party/swiftshader/third_party/astc-encoder @@ -549,7 +567,6 @@ src_prepare() { third_party/tflite third_party/tflite/src/third_party/xla third_party/tflite/src/third_party/xla/third_party/tsl - third_party/tflite/src/third_party/eigen3 third_party/tflite/src/third_party/fft2d third_party/ruy third_party/six @@ -566,7 +583,6 @@ src_prepare() { third_party/webrtc/modules/third_party/fft third_party/webrtc/modules/third_party/g711 third_party/webrtc/modules/third_party/g722 - third_party/webrtc/rtc_base/third_party/base64 third_party/webrtc/rtc_base/third_party/sigslot third_party/widevine third_party/woff2 @@ -579,15 +595,15 @@ src_prepare() { third_party/zlib/google third_party/zstd url/third_party/mozilla - v8/src/third_party/siphash - v8/src/third_party/valgrind - v8/src/third_party/utf8-decoder + v8/third_party/siphash + v8/third_party/utf8-decoder + v8/third_party/valgrind v8/third_party/glibc v8/third_party/inspector_protocol + v8/third_party/rapidhash-v8 v8/third_party/v8 # gyp -> gn leftovers - third_party/libevent third_party/speech-dispatcher third_party/usb_ids third_party/xdg-utils @@ -641,10 +657,6 @@ src_prepare() { # Remove most bundled libraries. Some are still needed. build/linux/unbundle/remove_bundled_libraries.py "${keeplibs[@]}" --do-remove || die - if use js-type-check; then - ln -s "${EPREFIX}"/usr/bin/java third_party/jdk/current/bin/java || die - fi - # bundled eu-strip is for amd64 only and we don't want to pre-stripped binaries mkdir -p buildtools/third_party/eu-strip/bin || die ln -s "${EPREFIX}"/bin/true buildtools/third_party/eu-strip/bin/eu-strip || die @@ -753,6 +765,9 @@ chromium_configure() { # GN needs explicit config for Debug/Release as opposed to inferring it from build directory. myconf_gn+=" is_debug=false" + myconf_gn+=" rust_sysroot_absolute=\"$(get_rust_prefix)\"" + myconf_gn+=" rustc_version=\"${RUST_SLOT}\"" + # enable DCHECK with USE=debug only, increases chrome binary size by 30%, bug #811138. # DCHECK is fatal by default, make it configurable at runtime, #bug 807881. myconf_gn+=" dcheck_always_on=$(usex debug true false)" @@ -778,12 +793,14 @@ chromium_configure() { freetype # Need harfbuzz_from_pkgconfig target #harfbuzz-ng - libdrm + #132: system libdrm is not supported??? + #libdrm libjpeg # libwebp libxml libxslt - openh264 + #133: libva shit depends on vendored openh264 now + #openh264 zlib ) if use system-ffmpeg; then @@ -811,7 +828,6 @@ chromium_configure() { myconf_gn+=" use_gnome_keyring=false" # Optional dependencies. - myconf_gn+=" enable_js_type_check=$(usex js-type-check true false)" myconf_gn+=" enable_hangout_services_extension=$(usex hangouts true false)" myconf_gn+=" enable_widevine=$(usex widevine true false)" @@ -964,6 +980,7 @@ chromium_configure() { myconf_gn+=" use_ozone=true ozone_auto_platforms=false" myconf_gn+=" ozone_platform_headless=true" myconf_gn+=" enable_remoting=false" + myconf_gn+=" use_qt5=false" if use headless; then myconf_gn+=" ozone_platform=\"headless\"" myconf_gn+=" use_xkbcommon=false use_gtk=false use_qt=false" @@ -972,20 +989,22 @@ chromium_configure() { myconf_gn+=" use_libpci=false use_udev=false" myconf_gn+=" enable_print_preview=false" else - myconf_gn+=" use_system_libdrm=true" + # myconf_gn+=" use_system_libdrm=true" myconf_gn+=" use_system_minigbm=true" myconf_gn+=" use_xkbcommon=true" - if use qt5; then - local moc_dir="$(qt5_get_bindir)" + if use qt6; then + local cbuild_libdir + cbuild_libdir="$(get_libdir)" if tc-is-cross-compiler; then - # Hack to workaround get_libdir not being able to handle CBUILD, bug #794181 - local cbuild_libdir=$($(tc-getBUILD_PKG_CONFIG) --keep-system-libs --libs-only-L libxslt) - cbuild_libdir=${cbuild_libdir:2} - moc_dir="${EPREFIX}"/${cbuild_libdir/% }/qt5/bin + # Hack to workaround get_libdir not being able to handle CBUILD, bug #794181 + cbuild_libdir="$($(tc-getBUILD_PKG_CONFIG) --keep-system-libs --libs-only-L libxslt)" + cbuild_libdir="${cbuild_libdir:2}" + cbuild_libdir="${cbuild_libdir/% }" fi - export PATH="${PATH}:${moc_dir}" + myconf_gn+=" use_qt6=true moc_qt6_path=\"${EPREFIX}/usr/${cbuild_libdir}/qt6/libexec\"" + else + myconf_gn+=" use_qt6=false" fi - myconf_gn+=" use_qt=$(usex qt5 true false)" myconf_gn+=" ozone_platform_x11=$(usex X true false)" myconf_gn+=" ozone_platform_wayland=$(usex wayland true false)" myconf_gn+=" ozone_platform=$(usex wayland \"wayland\" \"x11\")" @@ -1056,16 +1075,17 @@ chromium_compile() { local -x PYTHONPATH= # Build mksnapshot and pax-mark it. - local x - for x in mksnapshot v8_context_snapshot_generator; do - if tc-is-cross-compiler; then - eninja -C out/Release "host/${x}" - pax-mark m "out/Release/host/${x}" - else - eninja -C out/Release "${x}" - pax-mark m "out/Release/${x}" - fi - done + # flag pax-kernel unimplemented + # local x + # for x in mksnapshot v8_context_snapshot_generator; do + # if tc-is-cross-compiler; then + # eninja -C out/Release "host/${x}" + # pax-mark m "out/Release/host/${x}" + # else + # eninja -C out/Release "${x}" + # pax-mark m "out/Release/${x}" + # fi + # done # Even though ninja autodetects number of CPUs, we respect # user's options, for debugging with -j 1 or any other reason. diff --git a/www-client/chromium/chromium-126.0.6423.2.ebuild b/www-client/chromium/chromium-142.0.7393.6.ebuild index 5b65a6a..1490a2d 100644 --- a/www-client/chromium/chromium-126.0.6423.2.ebuild +++ b/www-client/chromium/chromium-142.0.7393.6.ebuild @@ -2,10 +2,12 @@ # Distributed under the terms of the GNU General Public License v2 EAPI=8 -PYTHON_COMPAT=( python3_{9..11} ) +PYTHON_COMPAT=( python3_{12..13} ) PYTHON_REQ_USE="xml(+)" -LLVM_MAX_SLOT=17 -RUST_MIN_VER=1.72.0 +LLVM_COMPAT=( 20 ) +RUST_MIN_VER=1.87.0 +RUST_NEEDS_LLVM="yes please" +GN_MIN_VER=0.2235 CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he hi hr hu id it ja kn ko lt lv ml mr ms nb nl pl pt-BR pt-PT ro ru sk sl sr @@ -13,8 +15,8 @@ CHROMIUM_LANGS="af am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu VIRTUALX_REQUIRED="pgo" -inherit check-reqs chromium-2 desktop flag-o-matic llvm ninja-utils pax-utils -inherit python-any-r1 qmake-utils readme.gentoo-r1 toolchain-funcs virtualx xdg-utils +inherit check-reqs chromium-2 desktop flag-o-matic llvm-r1 ninja-utils pax-utils +inherit python-any-r1 qmake-utils readme.gentoo-r1 rust toolchain-funcs virtualx xdg-utils DESCRIPTION="Open-source version of Google Chrome web browser" HOMEPAGE="https://chromium.org/" @@ -24,7 +26,7 @@ SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P} LICENSE="BSD" SLOT="0/dev" KEYWORDS="~amd64 ~arm64" -IUSE="+X component-build cups cpu_flags_arm_neon debug gtk4 +hangouts headless +js-type-check kerberos libcxx lto +official pgo pic +proprietary-codecs pulseaudio qt5 screencast selinux +suid +system-av1 +system-ffmpeg +system-harfbuzz +system-icu +system-png vaapi wayland widevine" +IUSE="+X component-build cups cpu_flags_arm_neon debug gtk4 +hangouts headless kerberos libcxx lto +official pgo pic +proprietary-codecs pulseaudio qt6 screencast selinux +suid +system-av1 +system-ffmpeg +system-harfbuzz +system-icu +system-png vaapi wayland widevine" REQUIRED_USE=" component-build? ( !suid !libcxx ) screencast? ( wayland ) @@ -64,11 +66,10 @@ COMMON_SNAPSHOT_DEPEND=" >=media-libs/libaom-3.4.0:= ) sys-libs/zlib:= - x11-libs/libdrm:= !headless? ( dev-libs/glib:2 >=media-libs/alsa-lib-1.0.19:= - pulseaudio? ( media-sound/pulseaudio:= ) + pulseaudio? ( media-libs/libpulse:= ) sys-apps/pciutils:= kerberos? ( virtual/krb5 ) vaapi? ( >=media-libs/libva-2.7:=[X?,wayland?] ) @@ -110,10 +111,7 @@ COMMON_DEPEND=" x11-libs/cairo:= x11-libs/gdk-pixbuf:2 x11-libs/pango:= - qt5? ( - dev-qt/qtcore:5 - dev-qt/qtwidgets:5 - ) + qt6? ( dev-qt/qtbase:6[gui,widgets] ) ) " RDEPEND="${COMMON_DEPEND} @@ -122,7 +120,7 @@ RDEPEND="${COMMON_DEPEND} x11-libs/gtk+:3[X?,wayland?] gui-libs/gtk:4[X?,wayland?] ) - qt5? ( dev-qt/qtgui:5[X?,wayland?] ) + qt6? ( dev-qt/qtbase:6[gui,widgets] ) ) virtual/ttf-fonts selinux? ( sec-policy/selinux-chromium ) @@ -135,9 +133,9 @@ DEPEND="${COMMON_DEPEND} " depend_clang_llvm_version() { - echo "sys-devel/clang:$1" - echo "sys-devel/llvm:$1" - echo "=sys-devel/lld-$1*" + echo "llvm-core/clang:$1" + echo "llvm-core/llvm:$1" + echo "=llvm-core/lld-$1*" } depend_clang_llvm_versions() { @@ -163,18 +161,18 @@ BDEPEND=" ') >=app-arch/gzip-1.7 !headless? ( - qt5? ( dev-qt/qtcore:5 ) + qt6? ( dev-qt/qtbase:6 ) ) - libcxx? ( >=sys-devel/clang-13 ) - lto? ( $(depend_clang_llvm_versions 17) ) + libcxx? ( >=llvm-core/clang-13 ) + lto? ( $(depend_clang_llvm_versions 19) ) pgo? ( >=dev-python/selenium-3.141.0 >=dev-util/web_page_replay_go-20220314 - $(depend_clang_llvm_versions 17) + $(depend_clang_llvm_versions 19) ) - >=dev-lang/rust-${RUST_MIN_VER}[profiler] + dev-util/bindgen dev-lang/perl - >=dev-build/gn-0.2122 + >=dev-build/gn-${GN_MIN_VER} >=dev-util/gperf-3.0.3 >=dev-build/ninja-1.7.2 dev-vcs/git @@ -182,14 +180,13 @@ BDEPEND=" >=sys-devel/bison-2.4.3 sys-devel/flex virtual/pkgconfig - js-type-check? ( virtual/jre ) " # These are intended for ebuild maintainer use to force clang if GCC is broken. : ${CHROMIUM_FORCE_CLANG=yes} if [[ ${CHROMIUM_FORCE_CLANG} == yes ]]; then - BDEPEND+=" >=sys-devel/clang-13" + BDEPEND+=" >=llvm-core/clang-13" fi if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then @@ -234,13 +231,13 @@ needs_clang() { } llvm_check_deps() { - if ! has_version -b "sys-devel/clang:${LLVM_SLOT}" ; then - einfo "sys-devel/clang:${LLVM_SLOT} is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 + if ! has_version -b "llvm-core/clang:${LLVM_SLOT}" ; then + einfo "llvm-core/clang:${LLVM_SLOT} is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 return 1 fi - if ( use lto || use pgo ) && ! has_version -b "=sys-devel/lld-${LLVM_SLOT}*" ; then - einfo "=sys-devel/lld-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 + if ( use lto || use pgo ) && ! has_version -b "=llvm-core/lld-${LLVM_SLOT}*" ; then + einfo "=llvm-core/lld-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..." >&2 return 1 fi @@ -249,7 +246,7 @@ llvm_check_deps() { pre_build_checks() { if [[ ${MERGE_TYPE} != binary ]]; then - [[ ${EBUILD_PHASE_FUNC} == pkg_setup ]] && ( use lto || use pgo ) && llvm_pkg_setup + [[ ${EBUILD_PHASE_FUNC} == pkg_setup ]] && ( use lto || use pgo ) && llvm-r1_pkg_setup local -x CPP="$(tc-getCXX) -E" if tc-is-gcc && ! ver_test "$(gcc-version)" -ge 10.4; then @@ -261,12 +258,6 @@ pre_build_checks() { if needs_clang || tc-is-clang; then tc-is-cross-compiler && CPP=${CBUILD}-clang++ || CPP=${CHOST}-clang++ CPP+=" -E" - if ! ver_test "$(clang-major-version)" -ge 13; then - die "At least clang 13 is required" - fi - fi - if [[ ${EBUILD_PHASE_FUNC} == pkg_setup ]] && use js-type-check; then - "${BROOT}"/usr/bin/java -version 2>1 > /dev/null || die "Java VM not setup correctly" fi fi @@ -295,7 +286,7 @@ pkg_pretend() { pre_build_checks if use headless; then - local headless_unused_flags=("cups" "kerberos" "pulseaudio" "qt5" "vaapi" "wayland") + local headless_unused_flags=("cups" "kerberos" "pulseaudio" "qt6" "vaapi" "wayland") for myiuse in ${headless_unused_flags[@]}; do use ${myiuse} && ewarn "Ignoring USE=${myiuse} since USE=headless is set." done @@ -312,6 +303,9 @@ pkg_setup() { ewarn "Proprietary nVidia driver does not work with Wayland. You can disable" ewarn "Wayland by setting DISABLE_OZONE_PLATFORM=true in /etc/chromium/default." fi + + llvm-r1_pkg_setup + rust_pkg_setup } src_prepare() { @@ -319,27 +313,43 @@ src_prepare() { python_setup local PATCHES=( - "${FILESDIR}/chromium-105-protobuf-RepeatedPtrField-export.patch" - "${FILESDIR}/chromium-126-compiler.patch" + "${FILESDIR}/chromium-139-protobuf-RepeatedPtrField-export.patch" + "${FILESDIR}/chromium-142-compiler.patch" "${FILESDIR}/chromium-119-minizip.patch" "${FILESDIR}/chromium-118-material-color-utils.patch" "${FILESDIR}/chromium-126-freetype-blink.patch" "${FILESDIR}/chromium-124-metrics-histograms-nodepotbin.patch" + "${FILESDIR}/chromium-138-gn-exec_script_allowlist.patch" + "${FILESDIR}/chromium-142-rust-1.8x.patch" + "${FILESDIR}/chromium-142-blink-observable_array-css.patch" + "${FILESDIR}/chromium-141-mv2-ungoogled.patch" "${FILESDIR}/chromium-111-InkDropHost-crash.patch" - "${FILESDIR}/chromium-123-EnumTable-crash.patch" - "${FILESDIR}/chromium-126-use-oauth2-client-switches-as-default.patch" + "${FILESDIR}/chromium-134-EnumTable-crash.patch" "${FILESDIR}/chromium-cross-compile.patch" ) sed -i -e \ "/if (is_clang && toolchain_has_rust) {/,+2d" \ build/config/compiler/BUILD.gn || die "Failed to disable bundled compiler builtins" + sed -i -e \ + "/\`--sysroot\` flag/i\ \ \ \ args += [ \"-I\" + rebase_path(sysroot + \"/usr/lib/clang/${LLVM_SLOT}/include/\", root_build_dir) ]" \ + -e \ + "/clang_resource_dir =/,+2d" \ + -e \ + "s/clang_resource_dir,/rebase_path(sysroot + \"\/usr\/lib\/clang\/${LLVM_SLOT}\/\", root_build_dir)/" \ + build/rust/rust_bindgen.gni || die "Failed to append include dir for bindgen" default - mkdir -p third_party/node/linux/node-linux-x64/bin || die - ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die + #mkdir -p third_party/node/linux/node-linux-x64/bin || die + #ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die + + # I don't know how to do this properly + rm -r third_party/rust-toolchain || die + mkdir -p third_party/rust-toolchain/bin || die + ln -s "${EPREFIX}"/usr/bin/bindgen third_party/rust-toolchain/bin/bindgen || die + ln -s "${EPREFIX}/usr/lib/llvm/${LLVM_SLOT}/lib64" third_party/rust-toolchain/lib || die # adjust python interpreter version sed -i -e "s|\(^script_executable = \).*|\1\"${EPYTHON}\"|g" .gn || die @@ -348,17 +358,13 @@ src_prepare() { local keeplibs=( base/third_party/cityhash base/third_party/double_conversion - base/third_party/dynamic_annotations base/third_party/icu base/third_party/nspr base/third_party/superfasthash base/third_party/symbolize - base/third_party/valgrind base/third_party/xdg_user_dirs buildtools/third_party/libc++ buildtools/third_party/libc++abi - chrome/third_party/mozilla_security_manager - courgette/third_party net/third_party/mozilla_security_manager net/third_party/nss net/third_party/quic @@ -394,10 +400,12 @@ src_prepare() { third_party/catapult/tracing/third_party/oboe third_party/catapult/tracing/third_party/pako third_party/ced + third_party/compiler-rt third_party/content_analysis_sdk third_party/cld_3 third_party/closure_compiler third_party/cpuinfo + third_party/crabbyavif third_party/crashpad third_party/crashpad/crashpad/third_party/lss third_party/crashpad/crashpad/third_party/zlib @@ -419,22 +427,29 @@ src_prepare() { third_party/devtools-frontend/src/front_end/third_party/diff third_party/devtools-frontend/src/front_end/third_party/i18n third_party/devtools-frontend/src/front_end/third_party/intl-messageformat + third_party/devtools-frontend/src/front_end/third_party/json5 + third_party/devtools-frontend/src/front_end/third_party/legacy-javascript third_party/devtools-frontend/src/front_end/third_party/lighthouse third_party/devtools-frontend/src/front_end/third_party/lit - third_party/devtools-frontend/src/front_end/third_party/lodash-isequal third_party/devtools-frontend/src/front_end/third_party/marked third_party/devtools-frontend/src/front_end/third_party/puppeteer third_party/devtools-frontend/src/front_end/third_party/puppeteer/package/lib/esm/third_party/mitt + third_party/devtools-frontend/src/front_end/third_party/puppeteer/package/lib/esm/third_party/parsel-js third_party/devtools-frontend/src/front_end/third_party/puppeteer/package/lib/esm/third_party/rxjs + third_party/devtools-frontend/src/front_end/third_party/source-map-scopes-codec + third_party/devtools-frontend/src/front_end/third_party/third-party-web third_party/devtools-frontend/src/front_end/third_party/vscode.web-custom-data third_party/devtools-frontend/src/front_end/third_party/wasmparser + third_party/devtools-frontend/src/front_end/third_party/web-vitals third_party/devtools-frontend/src/third_party - third_party/distributed_point_functions third_party/dom_distiller_js + third_party/dragonbox third_party/eigen3 third_party/emoji-segmenter + third_party/fast_float third_party/farmhash third_party/fdlibm + third_party/federated_compute third_party/fft2d third_party/flatbuffers third_party/fp16 @@ -449,25 +464,25 @@ src_prepare() { third_party/google_input_tools/third_party/closure_library third_party/google_input_tools/third_party/closure_library/third_party/closure third_party/googletest + third_party/harfbuzz-ng third_party/hunspell - third_party/iccjpeg + third_party/ink third_party/inspector_protocol third_party/ipcz third_party/jinja2 third_party/jsoncpp - third_party/jstemplate third_party/khronos third_party/leveldatabase third_party/lens_server_proto third_party/libaddressinput - third_party/libavif + third_party/libdrm third_party/libgav1 third_party/libjingle third_party/libphonenumber third_party/libsecret third_party/libsrtp third_party/libsync - third_party/libudev + third_party/libtess2 third_party/libva_protected_content third_party/libvpx third_party/libvpx/source/libvpx/third_party/x86inc @@ -483,19 +498,17 @@ src_prepare() { third_party/lss third_party/lzma_sdk third_party/mako - third_party/maldoca - third_party/maldoca/src/third_party/tensorflow_protos - third_party/maldoca/src/third_party/zlibwrapper third_party/markupsafe third_party/material_color_utilities - third_party/mesa third_party/metrics_proto third_party/minigbm + third_party/ml_dtypes third_party/modp_b64 third_party/nasm third_party/nearby third_party/neon_2_sse third_party/node + third_party/oak third_party/omnibox_proto third_party/one_euro_filter third_party/openh264 @@ -511,23 +524,30 @@ src_prepare() { third_party/pdfium/third_party/libtiff third_party/perfetto third_party/perfetto/protos/third_party/chromium + third_party/perfetto/protos/third_party/simpleperf third_party/pffft third_party/ply third_party/polymer third_party/private-join-and-compute third_party/private_membership third_party/protobuf + third_party/protobuf/third_party/utf8_range third_party/pthreadpool third_party/puffin third_party/pyjson5 third_party/pyyaml - third_party/qcms + third_party/rapidhash + third_party/readability third_party/rnnoise third_party/rust third_party/s2cellid + third_party/search_engines_data third_party/securemessage third_party/selenium-atoms + third_party/sentencepiece + third_party/sentencepiece/src/third_party/darts_clone third_party/shell-encryption + third_party/simdutf third_party/simplejson third_party/six third_party/skia @@ -535,6 +555,8 @@ src_prepare() { third_party/skia/third_party/vulkan third_party/smhasher third_party/snappy + third_party/spirv-tools + third_party/spirv-headers third_party/sqlite third_party/swiftshader third_party/swiftshader/third_party/astc-encoder @@ -548,7 +570,6 @@ src_prepare() { third_party/tflite third_party/tflite/src/third_party/xla third_party/tflite/src/third_party/xla/third_party/tsl - third_party/tflite/src/third_party/eigen3 third_party/tflite/src/third_party/fft2d third_party/ruy third_party/six @@ -565,7 +586,6 @@ src_prepare() { third_party/webrtc/modules/third_party/fft third_party/webrtc/modules/third_party/g711 third_party/webrtc/modules/third_party/g722 - third_party/webrtc/rtc_base/third_party/base64 third_party/webrtc/rtc_base/third_party/sigslot third_party/widevine third_party/woff2 @@ -578,15 +598,15 @@ src_prepare() { third_party/zlib/google third_party/zstd url/third_party/mozilla - v8/src/third_party/siphash - v8/src/third_party/valgrind - v8/src/third_party/utf8-decoder + v8/third_party/siphash + v8/third_party/utf8-decoder + v8/third_party/valgrind v8/third_party/glibc v8/third_party/inspector_protocol + v8/third_party/rapidhash-v8 v8/third_party/v8 # gyp -> gn leftovers - third_party/libevent third_party/speech-dispatcher third_party/usb_ids third_party/xdg-utils @@ -640,10 +660,6 @@ src_prepare() { # Remove most bundled libraries. Some are still needed. build/linux/unbundle/remove_bundled_libraries.py "${keeplibs[@]}" --do-remove || die - if use js-type-check; then - ln -s "${EPREFIX}"/usr/bin/java third_party/jdk/current/bin/java || die - fi - # bundled eu-strip is for amd64 only and we don't want to pre-stripped binaries mkdir -p buildtools/third_party/eu-strip/bin || die ln -s "${EPREFIX}"/bin/true buildtools/third_party/eu-strip/bin/eu-strip || die @@ -752,6 +768,9 @@ chromium_configure() { # GN needs explicit config for Debug/Release as opposed to inferring it from build directory. myconf_gn+=" is_debug=false" + myconf_gn+=" rust_sysroot_absolute=\"$(get_rust_prefix)\"" + myconf_gn+=" rustc_version=\"${RUST_SLOT}\"" + # enable DCHECK with USE=debug only, increases chrome binary size by 30%, bug #811138. # DCHECK is fatal by default, make it configurable at runtime, #bug 807881. myconf_gn+=" dcheck_always_on=$(usex debug true false)" @@ -761,9 +780,6 @@ chromium_configure() { # for development and debugging. myconf_gn+=" is_component_build=$(usex component-build true false)" - # Disable nacl, we can't build without pnacl (http://crbug.com/269560). - myconf_gn+=" enable_nacl=false" - # Use system-provided libraries. # TODO: freetype -- remove sources (https://bugs.chromium.org/p/pdfium/issues/detail?id=733). # TODO: use_system_hunspell (upstream changes needed). @@ -777,12 +793,14 @@ chromium_configure() { freetype # Need harfbuzz_from_pkgconfig target #harfbuzz-ng - libdrm + #132: system libdrm is not supported??? + #libdrm libjpeg # libwebp libxml libxslt - openh264 + #133: libva shit depends on vendored openh264 now + #openh264 zlib ) if use system-ffmpeg; then @@ -810,7 +828,6 @@ chromium_configure() { myconf_gn+=" use_gnome_keyring=false" # Optional dependencies. - myconf_gn+=" enable_js_type_check=$(usex js-type-check true false)" myconf_gn+=" enable_hangout_services_extension=$(usex hangouts true false)" myconf_gn+=" enable_widevine=$(usex widevine true false)" @@ -963,6 +980,7 @@ chromium_configure() { myconf_gn+=" use_ozone=true ozone_auto_platforms=false" myconf_gn+=" ozone_platform_headless=true" myconf_gn+=" enable_remoting=false" + myconf_gn+=" use_qt5=false" if use headless; then myconf_gn+=" ozone_platform=\"headless\"" myconf_gn+=" use_xkbcommon=false use_gtk=false use_qt=false" @@ -971,20 +989,22 @@ chromium_configure() { myconf_gn+=" use_libpci=false use_udev=false" myconf_gn+=" enable_print_preview=false" else - myconf_gn+=" use_system_libdrm=true" + # myconf_gn+=" use_system_libdrm=true" myconf_gn+=" use_system_minigbm=true" myconf_gn+=" use_xkbcommon=true" - if use qt5; then - local moc_dir="$(qt5_get_bindir)" + if use qt6; then + local cbuild_libdir + cbuild_libdir="$(get_libdir)" if tc-is-cross-compiler; then - # Hack to workaround get_libdir not being able to handle CBUILD, bug #794181 - local cbuild_libdir=$($(tc-getBUILD_PKG_CONFIG) --keep-system-libs --libs-only-L libxslt) - cbuild_libdir=${cbuild_libdir:2} - moc_dir="${EPREFIX}"/${cbuild_libdir/% }/qt5/bin + # Hack to workaround get_libdir not being able to handle CBUILD, bug #794181 + cbuild_libdir="$($(tc-getBUILD_PKG_CONFIG) --keep-system-libs --libs-only-L libxslt)" + cbuild_libdir="${cbuild_libdir:2}" + cbuild_libdir="${cbuild_libdir/% }" fi - export PATH="${PATH}:${moc_dir}" + myconf_gn+=" use_qt6=true moc_qt6_path=\"${EPREFIX}/usr/${cbuild_libdir}/qt6/libexec\"" + else + myconf_gn+=" use_qt6=false" fi - myconf_gn+=" use_qt=$(usex qt5 true false)" myconf_gn+=" ozone_platform_x11=$(usex X true false)" myconf_gn+=" ozone_platform_wayland=$(usex wayland true false)" myconf_gn+=" ozone_platform=$(usex wayland \"wayland\" \"x11\")" @@ -1055,16 +1075,17 @@ chromium_compile() { local -x PYTHONPATH= # Build mksnapshot and pax-mark it. - local x - for x in mksnapshot v8_context_snapshot_generator; do - if tc-is-cross-compiler; then - eninja -C out/Release "host/${x}" - pax-mark m "out/Release/host/${x}" - else - eninja -C out/Release "${x}" - pax-mark m "out/Release/${x}" - fi - done + # flag pax-kernel unimplemented + # local x + # for x in mksnapshot v8_context_snapshot_generator; do + # if tc-is-cross-compiler; then + # eninja -C out/Release "host/${x}" + # pax-mark m "out/Release/host/${x}" + # else + # eninja -C out/Release "${x}" + # pax-mark m "out/Release/${x}" + # fi + # done # Even though ninja autodetects number of CPUs, we respect # user's options, for debugging with -j 1 or any other reason. diff --git a/www-client/chromium/files/chromium-109-minizip.patch b/www-client/chromium/files/chromium-109-minizip.patch deleted file mode 100644 index f24595c..0000000 --- a/www-client/chromium/files/chromium-109-minizip.patch +++ /dev/null @@ -1,147 +0,0 @@ -diff --git a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc -index 1b01755e1..65550e8fd 100644 ---- a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc -+++ b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_extractor.cc -@@ -27,8 +27,8 @@ limitations under the License. - #include "tensorflow_lite_support/cc/port/status_macros.h" - #include "tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h" - #include "tensorflow_lite_support/metadata/metadata_schema_generated.h" --#include "third_party/zlib/contrib/minizip/ioapi.h" --#include "third_party/zlib/contrib/minizip/unzip.h" -+#include "minizip/ioapi.h" -+#include "minizip/unzip.h" - - namespace tflite { - namespace metadata { -diff --git a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc -index 01c68515a..7a53974f2 100644 ---- a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc -+++ b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/metadata_populator.cc -@@ -26,8 +26,8 @@ limitations under the License. - #include "tensorflow_lite_support/cc/port/statusor.h" - #include "tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h" - #include "tensorflow_lite_support/metadata/metadata_schema_generated.h" --#include "third_party/zlib/contrib/minizip/ioapi.h" --#include "third_party/zlib/contrib/minizip/unzip.h" -+#include "minizip/ioapi.h" -+#include "minizip/unzip.h" - - namespace tflite { - namespace metadata { -diff --git a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc -index 525ae4a2b..80ad84900 100644 ---- a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc -+++ b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.cc -@@ -19,7 +19,7 @@ limitations under the License. - #include <cstdio> - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "third_party/zlib/contrib/minizip/ioapi.h" -+#include "minizip/ioapi.h" - - namespace tflite { - namespace metadata { -diff --git a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h -index 72413a0a5..38c9278da 100644 ---- a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h -+++ b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_readonly_mem_file.h -@@ -19,7 +19,7 @@ limitations under the License. - #include <cstdlib> - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "third_party/zlib/contrib/minizip/ioapi.h" -+#include "minizip/ioapi.h" - - namespace tflite { - namespace metadata { -diff --git a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc -index 3ba91b5e2..646822093 100644 ---- a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc -+++ b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.cc -@@ -19,7 +19,7 @@ limitations under the License. - #include <cstdio> - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "third_party/zlib/contrib/minizip/ioapi.h" -+#include "minizip/ioapi.h" - - namespace tflite { - namespace metadata { -diff --git a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h -index 3d329925d..da6ff5ad8 100644 ---- a/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h -+++ b/third_party/tflite_support/src/tensorflow_lite_support/metadata/cc/utils/zip_writable_mem_file.h -@@ -19,7 +19,7 @@ limitations under the License. - #include <cstdlib> - - #include "absl/strings/string_view.h" // from @com_google_absl --#include "third_party/zlib/contrib/minizip/ioapi.h" -+#include "minizip/ioapi.h" - - namespace tflite { - namespace metadata { -diff --git a/third_party/zlib/google/zip_internal.cc b/third_party/zlib/google/zip_internal.cc -index e65d7ce6b..1f89d931a 100644 ---- a/third_party/zlib/google/zip_internal.cc -+++ b/third_party/zlib/google/zip_internal.cc -@@ -17,7 +17,7 @@ - #include "base/strings/string_util.h" - #include "base/strings/utf_string_conversions.h" - --#if defined(USE_SYSTEM_MINIZIP) -+#if 1//defined(USE_SYSTEM_MINIZIP) - #include <minizip/ioapi.h> - #include <minizip/unzip.h> - #include <minizip/zip.h> -diff --git a/third_party/zlib/google/zip_internal.h b/third_party/zlib/google/zip_internal.h -index f107d7fe8..28ef2f636 100644 ---- a/third_party/zlib/google/zip_internal.h -+++ b/third_party/zlib/google/zip_internal.h -@@ -14,7 +14,7 @@ - #include <windows.h> - #endif - --#if defined(USE_SYSTEM_MINIZIP) -+#if 1//defined(USE_SYSTEM_MINIZIP) - #include <minizip/unzip.h> - #include <minizip/zip.h> - #else -diff --git a/third_party/zlib/google/zip_reader.cc b/third_party/zlib/google/zip_reader.cc -index e97027a0b..d6f02b1e0 100644 ---- a/third_party/zlib/google/zip_reader.cc -+++ b/third_party/zlib/google/zip_reader.cc -@@ -23,7 +23,7 @@ - #include "third_party/zlib/google/redact.h" - #include "third_party/zlib/google/zip_internal.h" - --#if defined(USE_SYSTEM_MINIZIP) -+#if 1//defined(USE_SYSTEM_MINIZIP) - #include <minizip/unzip.h> - #else - #include "third_party/zlib/contrib/minizip/unzip.h" -diff --git a/third_party/zlib/google/zip_reader.h b/third_party/zlib/google/zip_reader.h -index 48244c823..a5c0234fe 100644 ---- a/third_party/zlib/google/zip_reader.h -+++ b/third_party/zlib/google/zip_reader.h -@@ -18,7 +18,7 @@ - #include "base/numerics/safe_conversions.h" - #include "base/time/time.h" - --#if defined(USE_SYSTEM_MINIZIP) -+#if 1//defined(USE_SYSTEM_MINIZIP) - #include <minizip/unzip.h> - #else - #include "third_party/zlib/contrib/minizip/unzip.h" -diff --git a/third_party/zlib/google/zip_writer.h b/third_party/zlib/google/zip_writer.h -index dd109293d..edb1542b7 100644 ---- a/third_party/zlib/google/zip_writer.h -+++ b/third_party/zlib/google/zip_writer.h -@@ -13,7 +13,7 @@ - #include "build/build_config.h" - #include "third_party/zlib/google/zip.h" - --#if defined(USE_SYSTEM_MINIZIP) -+#if 1//defined(USE_SYSTEM_MINIZIP) - #include <minizip/unzip.h> - #include <minizip/zip.h> - #else diff --git a/www-client/chromium/files/chromium-122-VirtualCursor-std-layout.patch b/www-client/chromium/files/chromium-122-VirtualCursor-std-layout.patch deleted file mode 100644 index 5b06407..0000000 --- a/www-client/chromium/files/chromium-122-VirtualCursor-std-layout.patch +++ /dev/null @@ -1,219 +0,0 @@ -diff --git a/sql/recover_module/btree.cc b/sql/recover_module/btree.cc -index ad985a3d7c..a013c4df17 100644 ---- a/sql/recover_module/btree.cc -+++ b/sql/recover_module/btree.cc -@@ -136,16 +136,22 @@ static_assert(std::is_trivially_destructible<LeafPageDecoder>::value, - "Move the destructor to the .cc file if it's non-trival"); - #endif // !DCHECK_IS_ON() - --LeafPageDecoder::LeafPageDecoder(DatabasePageReader* db_reader) noexcept -- : page_id_(db_reader->page_id()), -- db_reader_(db_reader), -- cell_count_(ComputeCellCount(db_reader)), -- next_read_index_(0), -- last_record_size_(0) { -+LeafPageDecoder::LeafPageDecoder() noexcept = default; -+ -+void LeafPageDecoder::Initialize(DatabasePageReader* db_reader) { -+ page_id_ = db_reader->page_id(); -+ db_reader_ = db_reader; -+ cell_count_ = ComputeCellCount(db_reader); -+ next_read_index_ = 0; -+ last_record_size_ = 0; - DCHECK(IsOnValidPage(db_reader)); - DCHECK(DatabasePageReader::IsValidPageId(page_id_)); - } - -+void LeafPageDecoder::Reset() { -+ db_reader_ = nullptr; -+} -+ - bool LeafPageDecoder::TryAdvance() { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - DCHECK(CanAdvance()); -diff --git a/sql/recover_module/btree.h b/sql/recover_module/btree.h -index 155be1ef17..ed27107804 100644 ---- a/sql/recover_module/btree.h -+++ b/sql/recover_module/btree.h -@@ -104,9 +104,7 @@ class LeafPageDecoder { - public: - // Creates a decoder for a DatabasePageReader's last read page. - // -- // |db_reader| must have been used to read an inner page of a table B-tree. -- // |db_reader| must outlive this instance. -- explicit LeafPageDecoder(DatabasePageReader* db_reader) noexcept; -+ LeafPageDecoder() noexcept; - ~LeafPageDecoder() noexcept = default; - - LeafPageDecoder(const LeafPageDecoder&) = delete; -@@ -154,6 +152,17 @@ class LeafPageDecoder { - // read as long as CanAdvance() returns true. - bool TryAdvance(); - -+ // Initialize with DatabasePageReader -+ // |db_reader| must have been used to read an inner page of a table B-tree. -+ // |db_reader| must outlive this instance. -+ void Initialize(DatabasePageReader* db_reader); -+ -+ // Reset internal DatabasePageReader -+ void Reset(); -+ -+ // True if DatabasePageReader is valid -+ bool IsValid() { return (db_reader_ != nullptr); } -+ - // True if the given reader may point to an inner page in a table B-tree. - // - // The last ReadPage() call on |db_reader| must have succeeded. -@@ -167,16 +176,16 @@ class LeafPageDecoder { - static int ComputeCellCount(DatabasePageReader* db_reader); - - // The number of the B-tree page this reader is reading. -- const int64_t page_id_; -+ int64_t page_id_; - // Used to read the tree page. - // - // Raw pointer usage is acceptable because this instance's owner is expected - // to ensure that the DatabasePageReader outlives this. - // This field is not a raw_ptr<> because it caused a - // std::is_trivially_destructible static_assert failure. -- RAW_PTR_EXCLUSION DatabasePageReader* const db_reader_; -+ RAW_PTR_EXCLUSION DatabasePageReader* db_reader_; - // Caches the ComputeCellCount() value for this reader's page. -- const int cell_count_ = ComputeCellCount(db_reader_); -+ int cell_count_; - - // The reader's cursor state. - // -diff --git a/sql/recover_module/cursor.cc b/sql/recover_module/cursor.cc -index 8983af57e5..de5157c5a8 100644 ---- a/sql/recover_module/cursor.cc -+++ b/sql/recover_module/cursor.cc -@@ -28,7 +28,7 @@ VirtualCursor::~VirtualCursor() { - int VirtualCursor::First() { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - inner_decoders_.clear(); -- leaf_decoder_ = nullptr; -+ leaf_decoder_.Reset(); - - AppendPageDecoder(table_->root_page_id()); - return Next(); -@@ -38,18 +38,18 @@ int VirtualCursor::Next() { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - record_reader_.Reset(); - -- while (!inner_decoders_.empty() || leaf_decoder_.get()) { -- if (leaf_decoder_.get()) { -- if (!leaf_decoder_->CanAdvance()) { -+ while (!inner_decoders_.empty() || leaf_decoder_.IsValid()) { -+ if (leaf_decoder_.IsValid()) { -+ if (!leaf_decoder_.CanAdvance()) { - // The leaf has been exhausted. Remove it from the DFS stack. -- leaf_decoder_ = nullptr; -+ leaf_decoder_.Reset(); - continue; - } -- if (!leaf_decoder_->TryAdvance()) -+ if (!leaf_decoder_.TryAdvance()) - continue; - -- if (!payload_reader_.Initialize(leaf_decoder_->last_record_size(), -- leaf_decoder_->last_record_offset())) { -+ if (!payload_reader_.Initialize(leaf_decoder_.last_record_size(), -+ leaf_decoder_.last_record_offset())) { - continue; - } - if (!record_reader_.Initialize()) -@@ -102,13 +102,13 @@ int VirtualCursor::ReadColumn(int column_index, - int64_t VirtualCursor::RowId() { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - DCHECK(record_reader_.IsInitialized()); -- DCHECK(leaf_decoder_.get()); -- return leaf_decoder_->last_record_rowid(); -+ DCHECK(leaf_decoder_.IsValid()); -+ return leaf_decoder_.last_record_rowid(); - } - - void VirtualCursor::AppendPageDecoder(int page_id) { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); -- DCHECK(leaf_decoder_.get() == nullptr) -+ DCHECK(!leaf_decoder_.IsValid()) - << __func__ - << " must only be called when the current path has no leaf decoder"; - -@@ -116,7 +116,7 @@ void VirtualCursor::AppendPageDecoder(int page_id) { - return; - - if (LeafPageDecoder::IsOnValidPage(&db_reader_)) { -- leaf_decoder_ = std::make_unique<LeafPageDecoder>(&db_reader_); -+ leaf_decoder_.Initialize(&db_reader_); - return; - } - -diff --git a/sql/recover_module/cursor.h b/sql/recover_module/cursor.h -index 4cb0655700..4be15393e3 100644 ---- a/sql/recover_module/cursor.h -+++ b/sql/recover_module/cursor.h -@@ -128,7 +128,7 @@ class VirtualCursor { - std::vector<std::unique_ptr<InnerPageDecoder>> inner_decoders_; - - // Decodes the leaf page containing records. -- std::unique_ptr<LeafPageDecoder> leaf_decoder_; -+ LeafPageDecoder leaf_decoder_; - - SEQUENCE_CHECKER(sequence_checker_); - }; -diff --git a/sql/recover_module/pager.cc b/sql/recover_module/pager.cc -index 7f5b368e51..cb7e2fda21 100644 ---- a/sql/recover_module/pager.cc -+++ b/sql/recover_module/pager.cc -@@ -24,8 +24,7 @@ static_assert(DatabasePageReader::kMaxPageId <= std::numeric_limits<int>::max(), - "ints are not appropriate for representing page IDs"); - - DatabasePageReader::DatabasePageReader(VirtualTable* table) -- : page_data_(std::make_unique<uint8_t[]>(table->page_size())), -- table_(table) { -+ : page_data_(table->page_size()), table_(table) { - CHECK(table != nullptr); - CHECK(IsValidPageSize(table->page_size())); - } -@@ -59,7 +58,7 @@ int DatabasePageReader::ReadPage(int page_id) { - "The |read_offset| computation above may overflow"); - - int sqlite_status = -- RawRead(sqlite_file, read_size, read_offset, page_data_.get()); -+ RawRead(sqlite_file, read_size, read_offset, page_data_.data()); - - // |page_id_| needs to be set to kHighestInvalidPageId if the read failed. - // Otherwise, future ReadPage() calls with the previous |page_id_| value -diff --git a/sql/recover_module/pager.h b/sql/recover_module/pager.h -index d60c5a4f07..f39ce84d74 100644 ---- a/sql/recover_module/pager.h -+++ b/sql/recover_module/pager.h -@@ -6,8 +6,8 @@ - #define SQL_RECOVER_MODULE_PAGER_H_ - - #include <cstdint> --#include <memory> - #include <ostream> -+#include <vector> - - #include "base/check_op.h" - #include "base/memory/raw_ptr.h" -@@ -73,7 +73,7 @@ class DatabasePageReader { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - CHECK(IsValidPageId(page_id_)) - << "Successful ReadPage() required before accessing pager state"; -- return page_data_.get(); -+ return page_data_.data(); - } - - // The number of bytes in the page read by the last ReadPage() call. -@@ -140,7 +140,7 @@ class DatabasePageReader { - int page_id_ = kHighestInvalidPageId; - // Stores the bytes of the last page successfully read by ReadPage(). - // The content is undefined if the last call to ReadPage() did not succeed. -- const std::unique_ptr<uint8_t[]> page_data_; -+ std::vector<uint8_t> page_data_; - // Raw pointer usage is acceptable because this instance's owner is expected - // to ensure that the VirtualTable outlives this. - const raw_ptr<VirtualTable> table_; diff --git a/www-client/chromium/files/chromium-123-EnumTable-crash.patch b/www-client/chromium/files/chromium-123-EnumTable-crash.patch deleted file mode 100644 index 3c64789..0000000 --- a/www-client/chromium/files/chromium-123-EnumTable-crash.patch +++ /dev/null @@ -1,76 +0,0 @@ -diff --git a/components/media_router/common/providers/cast/channel/enum_table.h b/components/media_router/common/providers/cast/channel/enum_table.h -index dd58e6cfea..a0fa270bf2 100644 ---- a/components/media_router/common/providers/cast/channel/enum_table.h -+++ b/components/media_router/common/providers/cast/channel/enum_table.h -@@ -9,6 +9,7 @@ - #include <cstring> - #include <optional> - #include <ostream> -+#include <vector> - - #include "base/check_op.h" - #include "base/notreached.h" -@@ -187,7 +188,6 @@ class - inline constexpr GenericEnumTableEntry(int32_t value); - inline constexpr GenericEnumTableEntry(int32_t value, base::StringPiece str); - -- GenericEnumTableEntry(const GenericEnumTableEntry&) = delete; - GenericEnumTableEntry& operator=(const GenericEnumTableEntry&) = delete; - - private: -@@ -253,7 +253,6 @@ class EnumTable { - constexpr Entry(E value, base::StringPiece str) - : GenericEnumTableEntry(static_cast<int32_t>(value), str) {} - -- Entry(const Entry&) = delete; - Entry& operator=(const Entry&) = delete; - }; - -@@ -312,15 +311,14 @@ class EnumTable { - if (is_sorted_) { - const std::size_t index = static_cast<std::size_t>(value); - if (ANALYZER_ASSUME_TRUE(index < data_.size())) { -- const auto& entry = data_.begin()[index]; -+ const auto& entry = data_[index]; - if (ANALYZER_ASSUME_TRUE(entry.has_str())) - return entry.str(); - } - return std::nullopt; - } - return GenericEnumTableEntry::FindByValue( -- reinterpret_cast<const GenericEnumTableEntry*>(data_.begin()), -- data_.size(), static_cast<int32_t>(value)); -+ &data_[0], data_.size(), static_cast<int32_t>(value)); - } - - // This overload of GetString is designed for cases where the argument is a -@@ -348,8 +346,7 @@ class EnumTable { - // enum value directly. - std::optional<E> GetEnum(base::StringPiece str) const { - auto* entry = GenericEnumTableEntry::FindByString( -- reinterpret_cast<const GenericEnumTableEntry*>(data_.begin()), -- data_.size(), str); -+ &data_[0], data_.size(), str); - return entry ? static_cast<E>(entry->value) : std::optional<E>(); - } - -@@ -364,7 +361,7 @@ class EnumTable { - // Align the data on a cache line boundary. - alignas(64) - #endif -- std::initializer_list<Entry> data_; -+ const std::vector<Entry> data_; - bool is_sorted_; - - constexpr EnumTable(std::initializer_list<Entry> data, bool is_sorted) -@@ -376,8 +373,8 @@ class EnumTable { - - for (std::size_t i = 0; i < data.size(); i++) { - for (std::size_t j = i + 1; j < data.size(); j++) { -- const Entry& ei = data.begin()[i]; -- const Entry& ej = data.begin()[j]; -+ const Entry& ei = data[i]; -+ const Entry& ej = data[j]; - DCHECK(ei.value != ej.value) - << "Found duplicate enum values at indices " << i << " and " << j; - DCHECK(!(ei.has_str() && ej.has_str() && ei.str() == ej.str())) diff --git a/www-client/chromium/files/chromium-123-compiler.patch b/www-client/chromium/files/chromium-123-compiler.patch deleted file mode 100644 index 6faf9b7..0000000 --- a/www-client/chromium/files/chromium-123-compiler.patch +++ /dev/null @@ -1,317 +0,0 @@ -diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn -index a91928eeac..afc87ad613 100644 ---- a/build/config/compiler/BUILD.gn -+++ b/build/config/compiler/BUILD.gn -@@ -322,9 +322,6 @@ config("compiler") { - - configs += [ - # See the definitions below. -- ":clang_revision", -- ":rustc_revision", -- ":compiler_cpu_abi", - ":compiler_codegen", - ":compiler_deterministic", - ] -@@ -507,6 +504,9 @@ config("compiler") { - ldflags += [ "-fPIC" ] - rustflags += [ "-Crelocation-model=pic" ] - -+ extra_rustflags = getenv("RUSTFLAGS") -+ rustflags += [ extra_rustflags ] -+ - if (!is_clang) { - # Use pipes for communicating between sub-processes. Faster. - # (This flag doesn't do anything with Clang.) -@@ -598,55 +598,6 @@ config("compiler") { - ldflags += [ "-Wl,-z,keep-text-section-prefix" ] - } - -- if (is_clang && !is_nacl && current_os != "zos") { -- cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] -- if (save_reproducers_on_lld_crash && use_lld) { -- ldflags += [ -- "-fcrash-diagnostics=all", -- "-fcrash-diagnostics-dir=" + clang_diagnostic_dir, -- ] -- } -- -- # TODO(hans): Remove this once Clang generates better optimized debug info -- # by default. https://crbug.com/765793 -- cflags += [ -- "-mllvm", -- "-instcombine-lower-dbg-declare=0", -- ] -- if (!is_debug && use_thin_lto && is_a_target_toolchain) { -- if (is_win) { -- ldflags += [ "-mllvm:-instcombine-lower-dbg-declare=0" ] -- } else { -- ldflags += [ "-Wl,-mllvm,-instcombine-lower-dbg-declare=0" ] -- } -- } -- -- # TODO(crbug.com/1488374): This causes binary size growth and potentially -- # other problems. -- # TODO(crbug.com/1491036): This isn't supported by Cronet's mainline llvm version. -- if (default_toolchain != "//build/toolchain/cros:target" && -- !llvm_android_mainline) { -- cflags += [ -- "-mllvm", -- "-split-threshold-for-reg-with-hint=0", -- ] -- if (use_thin_lto && is_a_target_toolchain) { -- if (is_win) { -- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ] -- } else { -- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ] -- } -- } -- } -- -- # TODO(crbug.com/1235145): Investigate why/if this should be needed. -- if (is_win) { -- cflags += [ "/clang:-ffp-contract=off" ] -- } else { -- cflags += [ "-ffp-contract=off" ] -- } -- } -- - # C11/C++11 compiler flags setup. - # --------------------------- - if (is_linux || is_chromeos || is_android || (is_nacl && is_clang) || -@@ -1013,17 +964,6 @@ config("compiler") { - # `-nodefaultlibs` from the linker invocation from Rust, which would be used - # to compile dylibs on Android, such as for constructing unit test APKs. - "-Cdefault-linker-libraries", -- -- # To make Rust .d files compatible with ninja -- "-Zdep-info-omit-d-target", -- -- # If a macro panics during compilation, show which macro and where it is -- # defined. -- "-Zmacro-backtrace", -- -- # For deterministic builds, keep the local machine's current working -- # directory from appearing in build outputs. -- "-Zremap-cwd-prefix=.", - ] - - if (!is_win || force_rustc_color_output) { -@@ -1520,46 +1460,6 @@ config("compiler_deterministic") { - } - } - -- # Makes builds independent of absolute file path. -- if (is_clang && strip_absolute_paths_from_debug_symbols) { -- # If debug option is given, clang includes $cwd in debug info by default. -- # For such build, this flag generates reproducible obj files even we use -- # different build directory like "out/feature_a" and "out/feature_b" if -- # we build same files with same compile flag. -- # Other paths are already given in relative, no need to normalize them. -- if (is_nacl) { -- # TODO(https://crbug.com/1231236): Use -ffile-compilation-dir= here. -- cflags += [ -- "-Xclang", -- "-fdebug-compilation-dir", -- "-Xclang", -- ".", -- ] -- } else { -- # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= -- # and -fcoverage-compilation-dir=. -- cflags += [ "-ffile-compilation-dir=." ] -- swiftflags += [ "-file-compilation-dir=." ] -- } -- if (!is_win) { -- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) -- asmflags = [ "-Wa,-fdebug-compilation-dir,." ] -- } -- -- if (is_win && use_lld) { -- if (symbol_level == 2 || (is_clang && using_sanitizer)) { -- # Absolutize source file paths for PDB. Pass the real build directory -- # if the pdb contains source-level debug information and if linker -- # reproducibility is not critical. -- ldflags += [ "/PDBSourcePath:" + rebase_path(root_build_dir) ] -- } else { -- # Use a fake fixed base directory for paths in the pdb to make the pdb -- # output fully deterministic and independent of the build directory. -- ldflags += [ "/PDBSourcePath:o:\fake\prefix" ] -- } -- } -- } -- - # Tells the compiler not to use absolute paths when passing the default - # paths to the tools it invokes. We don't want this because we don't - # really need it and it can mess up the goma cache entries. -@@ -1578,39 +1478,6 @@ config("compiler_deterministic") { - } - } - --config("clang_revision") { -- if (is_clang && clang_base_path == default_clang_base_path) { -- update_args = [ -- "--print-revision", -- "--verify-version=$clang_version", -- ] -- if (llvm_force_head_revision) { -- update_args += [ "--llvm-force-head-revision" ] -- } -- clang_revision = exec_script("//tools/clang/scripts/update.py", -- update_args, -- "trim string") -- -- # This is here so that all files get recompiled after a clang roll and -- # when turning clang on or off. (defines are passed via the command line, -- # and build system rebuild things when their commandline changes). Nothing -- # should ever read this define. -- defines = [ "CR_CLANG_REVISION=\"$clang_revision\"" ] -- } --} -- --config("rustc_revision") { -- if (rustc_revision != "") { -- # Similar to the above config, this is here so that all files get recompiled -- # after a rustc roll. Nothing should ever read this cfg. This will not be -- # set if a custom toolchain is used. -- rustflags = [ -- "--cfg", -- "cr_rustc_revision=\"$rustc_revision\"", -- ] -- } --} -- - config("compiler_arm_fpu") { - if (current_cpu == "arm" && !is_ios && !is_nacl) { - cflags = [ "-mfpu=$arm_fpu" ] -@@ -1964,11 +1831,7 @@ config("chromium_code") { - defines = [ "_HAS_NODISCARD" ] - } - } else { -- cflags = [ "-Wall" ] -- if (is_clang) { -- # Enable extra warnings for chromium_code when we control the compiler. -- cflags += [ "-Wextra" ] -- } -+ cflags = [ ] - - # In Chromium code, we define __STDC_foo_MACROS in order to get the - # C99 macros on Mac and Linux. -@@ -1977,24 +1840,6 @@ config("chromium_code") { - "__STDC_FORMAT_MACROS", - ] - -- if (!is_debug && !using_sanitizer && current_cpu != "s390x" && -- current_cpu != "s390" && current_cpu != "ppc64" && -- current_cpu != "mips" && current_cpu != "mips64" && -- current_cpu != "riscv64" && current_cpu != "loong64") { -- # Non-chromium code is not guaranteed to compile cleanly with -- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are -- # disabled, so only do that for Release build. -- fortify_level = "2" -- -- # ChromeOS's toolchain supports a high-quality _FORTIFY_SOURCE=3 -- # implementation with a few custom glibc patches. Use that if it's -- # available. -- if (is_chromeos_device && !lacros_use_chromium_toolchain) { -- fortify_level = "3" -- } -- defines += [ "_FORTIFY_SOURCE=" + fortify_level ] -- } -- - if (is_apple) { - cflags_objc = [ "-Wimplicit-retain-self" ] - cflags_objcc = [ "-Wimplicit-retain-self" ] -@@ -2373,7 +2218,8 @@ config("default_stack_frames") { - } - - # Default "optimization on" config. --config("optimize") { -+config("optimize") { } -+config("xoptimize") { - if (is_win) { - if (chrome_pgo_phase != 2) { - # Favor size over speed, /O1 must be before the common flags. -@@ -2432,7 +2278,8 @@ config("optimize") { - } - - # Turn off optimizations. --config("no_optimize") { -+config("no_optimize") { } -+config("xno_optimize") { - if (is_win) { - cflags = [ - "/Od", # Disable optimization. -@@ -2472,7 +2319,8 @@ config("no_optimize") { - # Turns up the optimization level. On Windows, this implies whole program - # optimization and link-time code generation which is very expensive and should - # be used sparingly. --config("optimize_max") { -+config("optimize_max") { } -+config("xoptimize_max") { - if (is_nacl && is_nacl_irt) { - # The NaCl IRT is a special case and always wants its own config. - # Various components do: -@@ -2505,7 +2353,8 @@ config("optimize_max") { - # - # TODO(crbug.com/621335) - rework how all of these configs are related - # so that we don't need this disclaimer. --config("optimize_speed") { -+config("optimize_speed") { } -+config("xoptimize_speed") { - if (is_nacl && is_nacl_irt) { - # The NaCl IRT is a special case and always wants its own config. - # Various components do: -@@ -2531,7 +2380,8 @@ config("optimize_speed") { - } - } - --config("optimize_fuzzing") { -+config("optimize_fuzzing") { } -+config("xoptimize_fuzzing") { - cflags = [ "-O1" ] + common_optimize_on_cflags - rustflags = [ "-Copt-level=1" ] - ldflags = common_optimize_on_ldflags -@@ -2664,7 +2514,8 @@ config("win_pdbaltpath") { - } - - # Full symbols. --config("symbols") { -+config("symbols") { } -+config("xsymbols") { - rustflags = [] - if (is_win) { - if (is_clang) { -@@ -2813,7 +2664,8 @@ config("symbols") { - # Minimal symbols. - # This config guarantees to hold symbol for stack trace which are shown to user - # when crash happens in unittests running on buildbot. --config("minimal_symbols") { -+config("minimal_symbols") { } -+config("xminimal_symbols") { - rustflags = [] - if (is_win) { - # Functions, files, and line tables only. -@@ -2898,7 +2750,8 @@ config("minimal_symbols") { - # This configuration contains function names only. That is, the compiler is - # told to not generate debug information and the linker then just puts function - # names in the final debug information. --config("no_symbols") { -+config("no_symbols") { } -+config("xno_symbols") { - if (is_win) { - ldflags = [ "/DEBUG" ] - -diff --git a/build/config/rust.gni b/build/config/rust.gni -index 9b0ee754ba..a438ed231c 100644 ---- a/build/config/rust.gni -+++ b/build/config/rust.gni -@@ -75,7 +75,8 @@ declare_args() { - # - # TODO(https://crbug.com/1482525): Re-enable ThinLTO for Rust on LaCrOS - # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome -- toolchain_supports_rust_thin_lto = !is_chromeos -+ # toolchain_supports_rust_thin_lto = !is_chromeos -+ toolchain_supports_rust_thin_lto = false - - # Any extra std rlibs in your Rust toolchain, relative to the standard - # Rust toolchain. Typically used with 'rust_sysroot_absolute' diff --git a/www-client/chromium/files/chromium-125-compiler.patch b/www-client/chromium/files/chromium-125-compiler.patch deleted file mode 100644 index f656fcf..0000000 --- a/www-client/chromium/files/chromium-125-compiler.patch +++ /dev/null @@ -1,317 +0,0 @@ -diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn -index 2ac26091c0..75abd9a935 100644 ---- a/build/config/compiler/BUILD.gn -+++ b/build/config/compiler/BUILD.gn -@@ -319,9 +319,6 @@ config("compiler") { - - configs += [ - # See the definitions below. -- ":clang_revision", -- ":rustc_revision", -- ":compiler_cpu_abi", - ":compiler_codegen", - ":compiler_deterministic", - ] -@@ -496,6 +493,9 @@ config("compiler") { - ldflags += [ "-fPIC" ] - rustflags += [ "-Crelocation-model=pic" ] - -+ extra_rustflags = getenv("RUSTFLAGS") -+ rustflags += [ extra_rustflags ] -+ - if (!is_clang) { - # Use pipes for communicating between sub-processes. Faster. - # (This flag doesn't do anything with Clang.) -@@ -587,55 +587,6 @@ config("compiler") { - ldflags += [ "-Wl,-z,keep-text-section-prefix" ] - } - -- if (is_clang && !is_nacl && current_os != "zos") { -- cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] -- if (save_reproducers_on_lld_crash && use_lld) { -- ldflags += [ -- "-fcrash-diagnostics=all", -- "-fcrash-diagnostics-dir=" + clang_diagnostic_dir, -- ] -- } -- -- # TODO(hans): Remove this once Clang generates better optimized debug info -- # by default. https://crbug.com/765793 -- cflags += [ -- "-mllvm", -- "-instcombine-lower-dbg-declare=0", -- ] -- if (!is_debug && use_thin_lto && is_a_target_toolchain) { -- if (is_win) { -- ldflags += [ "-mllvm:-instcombine-lower-dbg-declare=0" ] -- } else { -- ldflags += [ "-Wl,-mllvm,-instcombine-lower-dbg-declare=0" ] -- } -- } -- -- # TODO(crbug.com/1488374): This causes binary size growth and potentially -- # other problems. -- # TODO(crbug.com/1491036): This isn't supported by Cronet's mainline llvm version. -- if (default_toolchain != "//build/toolchain/cros:target" && -- !llvm_android_mainline) { -- cflags += [ -- "-mllvm", -- "-split-threshold-for-reg-with-hint=0", -- ] -- if (use_thin_lto && is_a_target_toolchain) { -- if (is_win) { -- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ] -- } else { -- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ] -- } -- } -- } -- -- # TODO(crbug.com/1235145): Investigate why/if this should be needed. -- if (is_win) { -- cflags += [ "/clang:-ffp-contract=off" ] -- } else { -- cflags += [ "-ffp-contract=off" ] -- } -- } -- - # C11/C++11 compiler flags setup. - # --------------------------- - if (is_linux || is_chromeos || is_android || (is_nacl && is_clang) || -@@ -1000,17 +951,6 @@ config("compiler") { - # `-nodefaultlibs` from the linker invocation from Rust, which would be used - # to compile dylibs on Android, such as for constructing unit test APKs. - "-Cdefault-linker-libraries", -- -- # To make Rust .d files compatible with ninja -- "-Zdep-info-omit-d-target", -- -- # If a macro panics during compilation, show which macro and where it is -- # defined. -- "-Zmacro-backtrace", -- -- # For deterministic builds, keep the local machine's current working -- # directory from appearing in build outputs. -- "-Zremap-cwd-prefix=.", - ] - - if (!is_win || force_rustc_color_output) { -@@ -1518,46 +1458,6 @@ config("compiler_deterministic") { - } - } - -- # Makes builds independent of absolute file path. -- if (is_clang && strip_absolute_paths_from_debug_symbols) { -- # If debug option is given, clang includes $cwd in debug info by default. -- # For such build, this flag generates reproducible obj files even we use -- # different build directory like "out/feature_a" and "out/feature_b" if -- # we build same files with same compile flag. -- # Other paths are already given in relative, no need to normalize them. -- if (is_nacl) { -- # TODO(https://crbug.com/1231236): Use -ffile-compilation-dir= here. -- cflags += [ -- "-Xclang", -- "-fdebug-compilation-dir", -- "-Xclang", -- ".", -- ] -- } else { -- # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= -- # and -fcoverage-compilation-dir=. -- cflags += [ "-ffile-compilation-dir=." ] -- swiftflags += [ "-file-compilation-dir=." ] -- } -- if (!is_win) { -- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) -- asmflags = [ "-Wa,-fdebug-compilation-dir,." ] -- } -- -- if (is_win && use_lld) { -- if (symbol_level == 2 || (is_clang && using_sanitizer)) { -- # Absolutize source file paths for PDB. Pass the real build directory -- # if the pdb contains source-level debug information and if linker -- # reproducibility is not critical. -- ldflags += [ "/PDBSourcePath:" + rebase_path(root_build_dir) ] -- } else { -- # Use a fake fixed base directory for paths in the pdb to make the pdb -- # output fully deterministic and independent of the build directory. -- ldflags += [ "/PDBSourcePath:o:\fake\prefix" ] -- } -- } -- } -- - # Tells the compiler not to use absolute paths when passing the default - # paths to the tools it invokes. We don't want this because we don't - # really need it and it can mess up the RBE cache entries. -@@ -1576,39 +1476,6 @@ config("compiler_deterministic") { - } - } - --config("clang_revision") { -- if (is_clang && clang_base_path == default_clang_base_path) { -- update_args = [ -- "--print-revision", -- "--verify-version=$clang_version", -- ] -- if (llvm_force_head_revision) { -- update_args += [ "--llvm-force-head-revision" ] -- } -- clang_revision = exec_script("//tools/clang/scripts/update.py", -- update_args, -- "trim string") -- -- # This is here so that all files get recompiled after a clang roll and -- # when turning clang on or off. (defines are passed via the command line, -- # and build system rebuild things when their commandline changes). Nothing -- # should ever read this define. -- defines = [ "CR_CLANG_REVISION=\"$clang_revision\"" ] -- } --} -- --config("rustc_revision") { -- if (rustc_revision != "") { -- # Similar to the above config, this is here so that all files get recompiled -- # after a rustc roll. Nothing should ever read this cfg. This will not be -- # set if a custom toolchain is used. -- rustflags = [ -- "--cfg", -- "cr_rustc_revision=\"$rustc_revision\"", -- ] -- } --} -- - config("compiler_arm_fpu") { - if (current_cpu == "arm" && !is_ios && !is_nacl) { - cflags = [ "-mfpu=$arm_fpu" ] -@@ -1981,11 +1848,7 @@ config("chromium_code") { - defines = [ "_HAS_NODISCARD" ] - } - } else { -- cflags = [ "-Wall" ] -- if (is_clang) { -- # Enable extra warnings for chromium_code when we control the compiler. -- cflags += [ "-Wextra" ] -- } -+ cflags = [ ] - - # In Chromium code, we define __STDC_foo_MACROS in order to get the - # C99 macros on Mac and Linux. -@@ -1994,24 +1857,6 @@ config("chromium_code") { - "__STDC_FORMAT_MACROS", - ] - -- if (!is_debug && !using_sanitizer && current_cpu != "s390x" && -- current_cpu != "s390" && current_cpu != "ppc64" && -- current_cpu != "mips" && current_cpu != "mips64" && -- current_cpu != "riscv64" && current_cpu != "loong64") { -- # Non-chromium code is not guaranteed to compile cleanly with -- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are -- # disabled, so only do that for Release build. -- fortify_level = "2" -- -- # ChromeOS's toolchain supports a high-quality _FORTIFY_SOURCE=3 -- # implementation with a few custom glibc patches. Use that if it's -- # available. -- if (is_chromeos_device && !lacros_use_chromium_toolchain) { -- fortify_level = "3" -- } -- defines += [ "_FORTIFY_SOURCE=" + fortify_level ] -- } -- - if (is_apple) { - cflags_objc = [ "-Wimplicit-retain-self" ] - cflags_objcc = [ "-Wimplicit-retain-self" ] -@@ -2387,7 +2232,8 @@ config("default_stack_frames") { - } - - # Default "optimization on" config. --config("optimize") { -+config("optimize") { } -+config("xoptimize") { - if (is_win) { - cflags = [ "/O2" ] + common_optimize_on_cflags - -@@ -2428,7 +2274,8 @@ config("optimize") { - } - - # Turn off optimizations. --config("no_optimize") { -+config("no_optimize") { } -+config("xno_optimize") { - if (is_win) { - cflags = [ - "/Od", # Disable optimization. -@@ -2468,7 +2315,8 @@ config("no_optimize") { - # Turns up the optimization level. Used to explicitly enable -O2 instead of - # -Os for select targets on platforms that use optimize_for_size. No-op - # elsewhere. --config("optimize_max") { -+config("optimize_max") { } -+config("xoptimize_max") { - if (is_nacl && is_nacl_irt) { - # The NaCl IRT is a special case and always wants its own config. - # Various components do: -@@ -2501,7 +2349,8 @@ config("optimize_max") { - # - # TODO(crbug.com/621335) - rework how all of these configs are related - # so that we don't need this disclaimer. --config("optimize_speed") { -+config("optimize_speed") { } -+config("xoptimize_speed") { - if (is_nacl && is_nacl_irt) { - # The NaCl IRT is a special case and always wants its own config. - # Various components do: -@@ -2530,7 +2379,8 @@ config("optimize_speed") { - } - } - --config("optimize_fuzzing") { -+config("optimize_fuzzing") { } -+config("xoptimize_fuzzing") { - cflags = [ "-O1" ] + common_optimize_on_cflags - rustflags = [ "-Copt-level=1" ] - ldflags = common_optimize_on_ldflags -@@ -2663,7 +2513,8 @@ config("win_pdbaltpath") { - } - - # Full symbols. --config("symbols") { -+config("symbols") { } -+config("xsymbols") { - rustflags = [] - if (is_win) { - if (is_clang) { -@@ -2812,7 +2663,8 @@ config("symbols") { - # Minimal symbols. - # This config guarantees to hold symbol for stack trace which are shown to user - # when crash happens in unittests running on buildbot. --config("minimal_symbols") { -+config("minimal_symbols") { } -+config("xminimal_symbols") { - rustflags = [] - if (is_win) { - # Functions, files, and line tables only. -@@ -2897,7 +2749,8 @@ config("minimal_symbols") { - # This configuration contains function names only. That is, the compiler is - # told to not generate debug information and the linker then just puts function - # names in the final debug information. --config("no_symbols") { -+config("no_symbols") { } -+config("xno_symbols") { - if (is_win) { - ldflags = [ "/DEBUG" ] - -diff --git a/build/config/rust.gni b/build/config/rust.gni -index 59fa14463b..ca780602b4 100644 ---- a/build/config/rust.gni -+++ b/build/config/rust.gni -@@ -75,7 +75,8 @@ declare_args() { - # - # TODO(https://crbug.com/1482525): Re-enable ThinLTO for Rust on LaCrOS - # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome -- toolchain_supports_rust_thin_lto = !is_chromeos -+ # toolchain_supports_rust_thin_lto = !is_chromeos -+ toolchain_supports_rust_thin_lto = false - - # Any extra std rlibs in your Rust toolchain, relative to the standard - # Rust toolchain. Typically used with 'rust_sysroot_absolute' diff --git a/www-client/chromium/files/chromium-125-revert-8a3bec6.patch b/www-client/chromium/files/chromium-125-revert-8a3bec6.patch deleted file mode 100644 index 0f19d49..0000000 --- a/www-client/chromium/files/chromium-125-revert-8a3bec6.patch +++ /dev/null @@ -1,450 +0,0 @@ -diff --git a/third_party/blink/renderer/platform/BUILD.gn b/third_party/blink/renderer/platform/BUILD.gn -index 2c079c06c5..34a844659b 100644 ---- a/third_party/blink/renderer/platform/BUILD.gn -+++ b/third_party/blink/renderer/platform/BUILD.gn -@@ -118,10 +118,7 @@ blink_python_runner("color_data") { - - compiled_action("character_data") { - tool = ":character_data_generator" -- outputs = [ -- "$blink_platform_output_dir/character_property_data.cc", -- "$blink_platform_output_dir/text/break_iterator_data_inline_header.h", -- ] -+ outputs = [ "$blink_platform_output_dir/character_property_data.cc" ] - args = rebase_path(outputs, root_build_dir) - } - -diff --git a/third_party/blink/renderer/platform/runtime_enabled_features.json5 b/third_party/blink/renderer/platform/runtime_enabled_features.json5 -index 28d34020f7..45942f4e89 100644 ---- a/third_party/blink/renderer/platform/runtime_enabled_features.json5 -+++ b/third_party/blink/renderer/platform/runtime_enabled_features.json5 -@@ -509,11 +509,6 @@ - public: true, - status: "experimental", - }, -- { -- // crbug.com/41485013 -- name: "BreakIteratorDataGenerator", -- status: "stable", -- }, - { - name: "BrowserVerifiedUserActivationKeyboard", - base_feature: "none", -diff --git a/third_party/blink/renderer/platform/text/character_property_data_generator.cc b/third_party/blink/renderer/platform/text/character_property_data_generator.cc -index 70101dbf76..27e6852647 100644 ---- a/third_party/blink/renderer/platform/text/character_property_data_generator.cc -+++ b/third_party/blink/renderer/platform/text/character_property_data_generator.cc -@@ -5,19 +5,13 @@ - #include "third_party/blink/renderer/platform/text/character_property_data.h" - - #include <stdio.h> --#include <unicode/brkiter.h> --#include <unicode/locid.h> - #include <unicode/ucptrie.h> --#include <unicode/udata.h> --#include <unicode/ulocdata.h> - #include <unicode/umutablecptrie.h> - #include <unicode/uniset.h> - #include <unicode/unistr.h> - - #include <cassert> - #include <cstring> --#include <filesystem> --#include <fstream> - #include <iterator> - #include <memory> - -@@ -31,36 +25,6 @@ - namespace blink { - namespace { - --#define CHECK_U_ERROR(error, name) \ -- CHECK(U_SUCCESS(error)) << name << ": (" << error << ")" << u_errorName(error) -- --// --// Load the ICU data file and set it to the ICU. --// --void InitializeIcu(const char* exec_path) { -- // ICU can't load the data file by itself because ICU tries to load the -- // versioned data file (e.g., "icudt73l.dat"), while the Chromium build system -- // creates the unversioned data file (e.g., "icudtl.dat"). -- std::filesystem::path path{exec_path}; -- path = path.parent_path() / "icudt" U_ICUDATA_TYPE_LETTER ".dat"; -- -- std::ifstream data_ifstream(path, std::ios_base::binary); -- CHECK(data_ifstream.is_open()); -- static std::vector<uint8_t> icu_data; -- CHECK(icu_data.empty()); -- std::copy(std::istreambuf_iterator<char>(data_ifstream), -- std::istreambuf_iterator<char>(), std::back_inserter(icu_data)); -- UErrorCode error = U_ZERO_ERROR; -- udata_setCommonData(icu_data.data(), &error); -- CHECK_U_ERROR(error, "udata_setCommonData"); -- -- // Check ICU functions that need the data resources are working. -- // https://unicode-org.github.io/icu/userguide/icu/design.html#icu4c-initialization-and-termination -- UVersionInfo version; -- ulocdata_getCLDRVersion(version, &error); -- CHECK_U_ERROR(error, "ulocdata_getCLDRVersion"); --} -- - class CharacterPropertyValues { - public: - constexpr static UChar32 kMaxCodepoint = 0x10FFFF; -@@ -255,201 +219,18 @@ static void GenerateCharacterPropertyData(FILE* fp) { - GenerateUTrieSerialized(fp, serialized_size, serialized); - } - --// --// Generate a line break pair table in `break_iterator_data_inline_header.h`. --// --// See [UAX14](https://unicode.org/reports/tr14/). --// --class LineBreakData { -- public: -- LineBreakData() = default; -- -- static void Generate(FILE* fp) { -- LineBreakData data; -- data.FillFromIcu(); -- data.FillAscii(); -- data.Print(fp); -- } -- -- private: -- // Fill the pair table from the ICU BreakIterator. -- void FillFromIcu() { -- UErrorCode status = U_ZERO_ERROR; -- const icu::Locale locale("en"); -- icu::BreakIterator* break_iterator = -- icu::BreakIterator::createLineInstance(locale, status); -- CHECK_U_ERROR(status, "createLineInstance"); -- -- for (UChar ch = kMinChar; ch <= kMaxChar; ++ch) { -- const icu::UnicodeString ch_str(ch); -- for (UChar ch_next = kMinChar; ch_next <= kMaxChar; ++ch_next) { -- const icu::UnicodeString ch_next_str(ch_next); -- const icu::UnicodeString str = ch_str + ch_next_str; -- break_iterator->setText(str); -- SetPairValue(ch, ch_next, break_iterator->isBoundary(1)); -- } -- } -- } -- -- // Line breaking table for printable ASCII characters. Line breaking -- // opportunities in this table are as below: -- // - before opening punctuations such as '(', '<', '[', '{' after certain -- // characters (compatible with Firefox 3.6); -- // - after '-' and '?' (backward-compatible, and compatible with Internet -- // Explorer). -- // Please refer to <https://bugs.webkit.org/show_bug.cgi?id=37698> for line -- // breaking matrixes of different browsers and the ICU standard. -- void FillAscii() { --#define ALL_CHAR '!', 0x7F -- SetPairValue(ALL_CHAR, ALL_CHAR, false); -- SetPairValue(ALL_CHAR, '(', '(', true); -- SetPairValue(ALL_CHAR, '<', '<', true); -- SetPairValue(ALL_CHAR, '[', '[', true); -- SetPairValue(ALL_CHAR, '{', '{', true); -- SetPairValue('-', '-', ALL_CHAR, true); -- SetPairValue('?', '?', ALL_CHAR, true); -- SetPairValue('-', '-', '$', '$', false); -- SetPairValue(ALL_CHAR, '!', '!', false); -- SetPairValue('?', '?', '"', '"', false); -- SetPairValue('?', '?', '\'', '\'', false); -- SetPairValue(ALL_CHAR, ')', ')', false); -- SetPairValue(ALL_CHAR, ',', ',', false); -- SetPairValue(ALL_CHAR, '.', '.', false); -- SetPairValue(ALL_CHAR, '/', '/', false); -- // Note: Between '-' and '[0-9]' is hard-coded in `ShouldBreakFast()`. -- SetPairValue('-', '-', '0', '9', false); -- SetPairValue(ALL_CHAR, ':', ':', false); -- SetPairValue(ALL_CHAR, ';', ';', false); -- SetPairValue(ALL_CHAR, '?', '?', false); -- SetPairValue(ALL_CHAR, ']', ']', false); -- SetPairValue(ALL_CHAR, '}', '}', false); -- SetPairValue('$', '$', ALL_CHAR, false); -- SetPairValue('\'', '\'', ALL_CHAR, false); -- SetPairValue('(', '(', ALL_CHAR, false); -- SetPairValue('/', '/', ALL_CHAR, false); -- SetPairValue('0', '9', ALL_CHAR, false); -- SetPairValue('<', '<', ALL_CHAR, false); -- SetPairValue('@', '@', ALL_CHAR, false); -- SetPairValue('A', 'Z', ALL_CHAR, false); -- SetPairValue('[', '[', ALL_CHAR, false); -- SetPairValue('^', '`', ALL_CHAR, false); -- SetPairValue('a', 'z', ALL_CHAR, false); -- SetPairValue('{', '{', ALL_CHAR, false); -- SetPairValue(0x7F, 0x7F, ALL_CHAR, false); --#undef ALL_CHAR -- } -- -- // Print the C++ source code. -- void Print(FILE* fp) { -- // Print file headers. -- fprintf(fp, -- "#include <cstdint>\n" -- "#include " -- "\"third_party/blink/renderer/platform/wtf/text/wtf_uchar.h\"\n" -- "\nnamespace {\n\n"); -- -- fprintf(fp, "constexpr UChar kFastLineBreakMinChar = 0x%02X;\n", kMinChar); -- fprintf(fp, "constexpr UChar kFastLineBreakMaxChar = 0x%02X;\n", kMaxChar); -- -- // Define macros. -- fprintf(fp, -- "\n#define B(a, b, c, d, e, f, g, h)" -- " ((a) | ((b) << 1) | ((c) << 2) | ((d) << 3) |" -- " ((e) << 4) | ((f) << 5) | ((g) << 6) | ((h) << 7))\n\n"); -- -- fprintf(fp, "const uint8_t kFastLineBreakTable[%d][%d] = {\n", kNumChars, -- kNumCharsRoundUp8 / 8); -- -- // Print the column comment. -- fprintf(fp, " /*"); -- for (UChar ch = kMinChar; ch <= kMaxChar; ++ch) { -- if (ch != kMinChar && (ch - kMinChar) % 8 == 0) { -- fprintf(fp, " "); -- } -- fprintf(fp, ch < 0x7F ? " %c" : "%02X", ch); -- } -- fprintf(fp, " */\n"); -- -- // Print the data array. -- for (int y = 0; y < kNumChars; ++y) { -- const UChar ch = y + kMinChar; -- fprintf(fp, "/* %02X %c */ {B(", ch, ch < 0x7F ? ch : ' '); -- const char* prefix = ""; -- for (int x = 0; x < kNumCharsRoundUp8; ++x) { -- fprintf(fp, "%s%d", prefix, pair_[y][x]); -- prefix = (x % 8 == 7) ? "),B(" : ","; -- } -- fprintf(fp, ")},\n"); -- } -- fprintf(fp, -- "};\n\n" -- "#undef B\n\n" -- "template <typename T>\n" -- "inline uint8_t GetFastLineBreak(T ch1, T ch2) {\n" -- " const T i2 = ch2 - kFastLineBreakMinChar;\n" -- " return kFastLineBreakTable[ch1 - kFastLineBreakMinChar]" -- "[i2 / 8] & (1 << (i2 %% 8));\n" -- "}\n\n" -- "} // namespace\n"); -- } -- -- void SetPairValue(UChar ch1_min, -- UChar ch1_max, -- UChar ch2_min, -- UChar ch2_max, -- bool value) { -- for (UChar ch1 = ch1_min; ch1 <= ch1_max; ++ch1) { -- for (UChar ch2 = ch2_min; ch2 <= ch2_max; ++ch2) { -- SetPairValue(ch1, ch2, value); -- } -- } -- } -- -- // Set the breakability between `ch1` and `ch2`. -- void SetPairValue(UChar ch1, UChar ch2, bool value) { -- CHECK_GE(ch1, kMinChar); -- CHECK_LE(ch1, kMaxChar); -- CHECK_GE(ch2, kMinChar); -- CHECK_LE(ch2, kMaxChar); -- pair_[ch1 - kMinChar][ch2 - kMinChar] = value; -- } -- -- constexpr static UChar kMinChar = '!'; -- constexpr static UChar kMaxChar = 0xFF; -- constexpr static int kNumChars = kMaxChar - kMinChar + 1; -- constexpr static int kNumCharsRoundUp8 = (kNumChars + 7) / 8 * 8; -- bool pair_[kNumChars][kNumCharsRoundUp8]{}; --}; -- --void InvokeGenerator(int index, -- int argc, -- char** argv, -- void (*generator)(FILE*)) { -- if (index >= argc) { -- return; -- } -- const char* path = argv[index]; -- if (!*path) { -- return; -- } -- -- if (strcmp(path, "-") == 0) { -- (*generator)(stdout); -- return; -- } -- -- FILE* fp = fopen(path, "wb"); -- (*generator)(fp); -- fclose(fp); --} -- - } // namespace - } // namespace blink - - int main(int argc, char** argv) { -- blink::InitializeIcu(argv[0]); -- blink::InvokeGenerator(1, argc, argv, blink::GenerateCharacterPropertyData); -- blink::InvokeGenerator(2, argc, argv, blink::LineBreakData::Generate); -+ // Write the serialized array to the source file. -+ if (argc <= 1) { -+ blink::GenerateCharacterPropertyData(stdout); -+ } else { -+ FILE* fp = fopen(argv[1], "wb"); -+ blink::GenerateCharacterPropertyData(fp); -+ fclose(fp); -+ } - - return 0; - } -diff --git a/third_party/blink/renderer/platform/text/text_break_iterator.cc b/third_party/blink/renderer/platform/text/text_break_iterator.cc -index 650eb760b2..14de47d9fe 100644 ---- a/third_party/blink/renderer/platform/text/text_break_iterator.cc -+++ b/third_party/blink/renderer/platform/text/text_break_iterator.cc -@@ -26,8 +26,6 @@ - #include <unicode/uchar.h> - #include <unicode/uvernum.h> - --#include "third_party/blink/renderer/platform/runtime_enabled_features.h" --#include "third_party/blink/renderer/platform/text/break_iterator_data_inline_header.h" - #include "third_party/blink/renderer/platform/wtf/std_lib_extras.h" - #include "third_party/blink/renderer/platform/wtf/text/ascii_ctype.h" - #include "third_party/blink/renderer/platform/wtf/text/character_names.h" -@@ -113,9 +111,6 @@ static const UChar kAsciiLineBreakTableLastChar = 127; - - #define F 0xFF - --// Check if the generated table match the `kAsciiLineBreakTable` table. --#define CHECK_ASCII_LINE_BRAEK_TABLE 0 -- - // Line breaking table for printable ASCII characters. Line breaking - // opportunities in this table are as below: - // - before opening punctuations such as '(', '<', '[', '{' after certain -@@ -166,24 +161,6 @@ static const unsigned char kAsciiLineBreakTable[][(kAsciiLineBreakTableLastChar - }; - // clang-format on - --#if CHECK_ASCII_LINE_BRAEK_TABLE --void CheckAsciiLineBreakTable() { -- for (UChar ch2 = kAsciiLineBreakTableFirstChar; -- ch2 <= kAsciiLineBreakTableLastChar; ++ch2) { -- for (UChar ch1 = kAsciiLineBreakTableFirstChar; -- ch1 <= kAsciiLineBreakTableLastChar; ++ch1) { -- const UChar i2 = ch2 - kAsciiLineBreakTableFirstChar; -- const bool ascii = -- kAsciiLineBreakTable[ch1 - kAsciiLineBreakTableFirstChar][i2 / 8] & -- (1 << (i2 % 8)); -- const bool fast = GetFastLineBreak(ch1, ch2); -- CHECK_EQ(ascii, fast) -- << String::Format("%02X/%02X (%c/%c)", ch1, ch2, ch1, ch2); -- } -- } --} --#endif // CHECK_ASCII_LINE_BRAEK_TABLE -- - #define BA_LB_COUNT U_LB_COUNT - // Line breaking table for CSS word-break: break-all. This table differs from - // asciiLineBreakTable in: -@@ -298,13 +275,7 @@ static inline bool ShouldKeepAfterKeepAll(UChar last_ch, - } - - inline bool NeedsLineBreakIterator(UChar ch) { -- if (UNLIKELY(!RuntimeEnabledFeatures::BreakIteratorDataGeneratorEnabled())) { -- return ch > kAsciiLineBreakTableLastChar && ch != kNoBreakSpaceCharacter; -- } -- static_assert(kFastLineBreakMaxChar >= kAsciiLineBreakTableLastChar); -- static_assert(kNoBreakSpaceCharacter <= kFastLineBreakMaxChar, -- "Include NBSP for the performance."); -- return ch > kFastLineBreakMaxChar; -+ return ch > kAsciiLineBreakTableLastChar && ch != kNoBreakSpaceCharacter; - } - - template <typename CharacterType> -@@ -349,61 +320,31 @@ struct LazyLineBreakIterator::Context { - last = current; - } - -- bool ShouldBreakFast(bool disable_soft_hyphen) const { --#if CHECK_ASCII_LINE_BRAEK_TABLE -- DEFINE_STATIC_LOCAL(bool, is_check_done, (false)); -- if (!is_check_done) { -- is_check_done = true; -- CheckAsciiLineBreakTable(); -- LOG(INFO) << "CheckAsciiLineBreakTable() completed."; -- } --#endif // CHECK_ASCII_LINE_BRAEK_TABLE -- -+ bool ShouldBreakFast() const { - const UChar last_ch = last.ch; - const UChar ch = current.ch; -- static_assert(kFastLineBreakMinChar == kAsciiLineBreakTableFirstChar); -- if (UNLIKELY(last_ch < kFastLineBreakMinChar || -- ch < kFastLineBreakMinChar)) { -+ if (UNLIKELY(last_ch < kAsciiLineBreakTableFirstChar || -+ ch < kAsciiLineBreakTableFirstChar)) { - return false; - } - - // Don't allow line breaking between '-' and a digit if the '-' may mean a - // minus sign in the context, while allow breaking in 'ABCD-1234' and - // '1234-5678' which may be in long URLs. -- static_assert('-' >= kFastLineBreakMinChar); -+ static_assert('-' >= kAsciiLineBreakTableFirstChar); - if (last_ch == '-' && IsASCIIDigit(ch)) { - return IsASCIIAlphanumeric(last_last_ch); - } - -- if (UNLIKELY( -- !RuntimeEnabledFeatures::BreakIteratorDataGeneratorEnabled())) { -- // If both `last_ch` and `ch` are ASCII characters, use a lookup table for -- // enhanced speed and for compatibility with other browsers (see comments -- // for asciiLineBreakTable for details). -- if (last_ch <= kAsciiLineBreakTableLastChar && -- ch <= kAsciiLineBreakTableLastChar) { -- const unsigned char* table_row = -- kAsciiLineBreakTable[last_ch - kAsciiLineBreakTableFirstChar]; -- int ch_index = ch - kAsciiLineBreakTableFirstChar; -- return table_row[ch_index / 8] & (1 << (ch_index % 8)); -- } -- -- // Otherwise defer to the Unicode algorithm by returning false. -- return false; -- } -- -- // If both characters are in the fast line break table, use it for enhanced -- // speed. For ASCII characters, it is also for compatibility. The table is -- // generated at the build time, see the `LineBreakData` class. -- if (last_ch <= kFastLineBreakMaxChar && ch <= kFastLineBreakMaxChar) { -- if (!GetFastLineBreak(last_ch, ch)) { -- return false; -- } -- static_assert(kSoftHyphenCharacter <= kFastLineBreakMaxChar); -- if (UNLIKELY(disable_soft_hyphen && last_ch == kSoftHyphenCharacter)) { -- return false; -- } -- return true; -+ // If both `last_ch` and `ch` are ASCII characters, use a lookup table for -+ // enhanced speed and for compatibility with other browsers (see comments -+ // for asciiLineBreakTable for details). -+ if (last_ch <= kAsciiLineBreakTableLastChar && -+ ch <= kAsciiLineBreakTableLastChar) { -+ const unsigned char* table_row = -+ kAsciiLineBreakTable[last_ch - kAsciiLineBreakTableFirstChar]; -+ int ch_index = ch - kAsciiLineBreakTableFirstChar; -+ return table_row[ch_index / 8] & (1 << (ch_index % 8)); - } - - // Otherwise defer to the Unicode algorithm by returning false. -@@ -452,7 +393,7 @@ inline int LazyLineBreakIterator::NextBreakablePosition( - break; - } - -- if (context.ShouldBreakFast(disable_soft_hyphen_)) { -+ if (context.ShouldBreakFast()) { - return i; - } - diff --git a/www-client/chromium/files/chromium-126-use-oauth2-client-switches-as-default-r1.patch b/www-client/chromium/files/chromium-126-use-oauth2-client-switches-as-default-r1.patch deleted file mode 100644 index cd39907..0000000 --- a/www-client/chromium/files/chromium-126-use-oauth2-client-switches-as-default-r1.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff --git a/google_apis/google_api_keys-inc.cc b/google_apis/google_api_keys-inc.cc -index 4d13e697a5..61aac7b486 100644 ---- a/google_apis/google_api_keys-inc.cc -+++ b/google_apis/google_api_keys-inc.cc -@@ -193,11 +193,11 @@ class APIKeyCache { - std::string default_client_id = CalculateKeyValue( - GOOGLE_DEFAULT_CLIENT_ID, - STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_ID), std::string(), -- nullptr, std::string(), environment.get(), command_line, gaia_config); -+ ::switches::kOAuth2ClientID, std::string(), environment.get(), command_line, gaia_config); - std::string default_client_secret = CalculateKeyValue( - GOOGLE_DEFAULT_CLIENT_SECRET, - STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_SECRET), std::string(), -- nullptr, std::string(), environment.get(), command_line, gaia_config); -+ ::switches::kOAuth2ClientSecret, std::string(), environment.get(), command_line, gaia_config); - - // We currently only allow overriding the baked-in values for the - // default OAuth2 client ID and secret using a command-line diff --git a/www-client/chromium/files/chromium-126-use-oauth2-client-switches-as-default.patch b/www-client/chromium/files/chromium-126-use-oauth2-client-switches-as-default.patch deleted file mode 100644 index dd7a643..0000000 --- a/www-client/chromium/files/chromium-126-use-oauth2-client-switches-as-default.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff --git a/google_apis/google_api_keys-inc.cc b/google_apis/google_api_keys-inc.cc -index 49c396d69d..9493e7e5aa 100644 ---- a/google_apis/google_api_keys-inc.cc -+++ b/google_apis/google_api_keys-inc.cc -@@ -182,11 +182,11 @@ class APIKeyCache { - - std::string default_client_id = CalculateKeyValue( - GOOGLE_DEFAULT_CLIENT_ID, -- STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_ID), nullptr, -+ STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_ID), ::switches::kOAuth2ClientID, - std::string(), environment.get(), command_line, gaia_config); - std::string default_client_secret = CalculateKeyValue( - GOOGLE_DEFAULT_CLIENT_SECRET, -- STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_SECRET), nullptr, -+ STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_SECRET), ::switches::kOAuth2ClientSecret, - std::string(), environment.get(), command_line, gaia_config); - - // We currently only allow overriding the baked-in values for the diff --git a/www-client/chromium/files/chromium-131-use-oauth2-client-switches-as-default.patch b/www-client/chromium/files/chromium-131-use-oauth2-client-switches-as-default.patch new file mode 100644 index 0000000..27c38c3 --- /dev/null +++ b/www-client/chromium/files/chromium-131-use-oauth2-client-switches-as-default.patch @@ -0,0 +1,21 @@ +diff --git a/google_apis/api_key_cache.cc b/google_apis/api_key_cache.cc +index 93dfca27ec..4212f7a24a 100644 +--- a/google_apis/api_key_cache.cc ++++ b/google_apis/api_key_cache.cc +@@ -214,14 +214,14 @@ ApiKeyCache::ApiKeyCache(const DefaultApiKeys& default_api_keys) { + + std::string default_client_id = CalculateKeyValue( + default_api_keys.google_default_client_id, +- STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_ID), std::string(), nullptr, ++ STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_ID), std::string(), ::switches::kOAuth2ClientID, + std::string(), environment.get(), command_line, gaia_config, + default_api_keys.allow_override_via_environment, + default_api_keys.allow_unset_values); + std::string default_client_secret = CalculateKeyValue( + default_api_keys.google_default_client_secret, + STRINGIZE_NO_EXPANSION(GOOGLE_DEFAULT_CLIENT_SECRET), std::string(), +- nullptr, std::string(), environment.get(), command_line, gaia_config, ++ ::switches::kOAuth2ClientSecret, std::string(), environment.get(), command_line, gaia_config, + default_api_keys.allow_override_via_environment, + default_api_keys.allow_unset_values); + diff --git a/www-client/chromium/files/chromium-126-EnumTable-crash.patch b/www-client/chromium/files/chromium-134-EnumTable-crash.patch index 468cbf0..491b10e 100644 --- a/www-client/chromium/files/chromium-126-EnumTable-crash.patch +++ b/www-client/chromium/files/chromium-134-EnumTable-crash.patch @@ -1,8 +1,8 @@ diff --git a/components/media_router/common/providers/cast/channel/enum_table.h b/components/media_router/common/providers/cast/channel/enum_table.h -index 3f2ec76729..4e9c562113 100644 +index fdf8941c32..cf0df1dc46 100644 --- a/components/media_router/common/providers/cast/channel/enum_table.h +++ b/components/media_router/common/providers/cast/channel/enum_table.h -@@ -10,6 +10,7 @@ +@@ -16,6 +16,7 @@ #include <optional> #include <ostream> #include <string_view> @@ -10,7 +10,7 @@ index 3f2ec76729..4e9c562113 100644 #include "base/check_op.h" #include "base/notreached.h" -@@ -187,7 +188,6 @@ class +@@ -193,7 +194,6 @@ class inline constexpr GenericEnumTableEntry(int32_t value); inline constexpr GenericEnumTableEntry(int32_t value, std::string_view str); @@ -18,7 +18,7 @@ index 3f2ec76729..4e9c562113 100644 GenericEnumTableEntry& operator=(const GenericEnumTableEntry&) = delete; private: -@@ -253,7 +253,6 @@ class EnumTable { +@@ -259,7 +259,6 @@ class EnumTable { constexpr Entry(E value, std::string_view str) : GenericEnumTableEntry(static_cast<int32_t>(value), str) {} @@ -26,15 +26,16 @@ index 3f2ec76729..4e9c562113 100644 Entry& operator=(const Entry&) = delete; }; -@@ -312,15 +311,14 @@ class EnumTable { +@@ -318,7 +317,7 @@ class EnumTable { if (is_sorted_) { const std::size_t index = static_cast<std::size_t>(value); if (ANALYZER_ASSUME_TRUE(index < data_.size())) { - const auto& entry = data_.begin()[index]; + const auto& entry = data_[index]; - if (ANALYZER_ASSUME_TRUE(entry.has_str())) + if (ANALYZER_ASSUME_TRUE(entry.has_str())) { return entry.str(); - } + } +@@ -326,8 +325,7 @@ class EnumTable { return std::nullopt; } return GenericEnumTableEntry::FindByValue( @@ -44,7 +45,7 @@ index 3f2ec76729..4e9c562113 100644 } // This overload of GetString is designed for cases where the argument is a -@@ -348,8 +346,7 @@ class EnumTable { +@@ -355,8 +353,7 @@ class EnumTable { // enum value directly. std::optional<E> GetEnum(std::string_view str) const { auto* entry = GenericEnumTableEntry::FindByString( @@ -54,16 +55,19 @@ index 3f2ec76729..4e9c562113 100644 return entry ? static_cast<E>(entry->value) : std::optional<E>(); } -@@ -364,7 +361,7 @@ class EnumTable { - // Align the data on a cache line boundary. - alignas(64) +@@ -368,9 +365,9 @@ class EnumTable { + + private: + #ifdef ARCH_CPU_64_BITS +- alignas(std::hardware_destructive_interference_size) ++ alignas(64) #endif - std::initializer_list<Entry> data_; + const std::vector<Entry> data_; bool is_sorted_; constexpr EnumTable(std::initializer_list<Entry> data, bool is_sorted) -@@ -376,8 +373,8 @@ class EnumTable { +@@ -382,8 +379,8 @@ class EnumTable { for (std::size_t i = 0; i < data.size(); i++) { for (std::size_t j = i + 1; j < data.size(); j++) { diff --git a/www-client/chromium/files/chromium-138-gn-exec_script_allowlist.patch b/www-client/chromium/files/chromium-138-gn-exec_script_allowlist.patch new file mode 100644 index 0000000..e5d6f15 --- /dev/null +++ b/www-client/chromium/files/chromium-138-gn-exec_script_allowlist.patch @@ -0,0 +1,52 @@ +diff --git a/.gn b/.gn +index ae58a0b0a6..e34034d383 100644 +--- a/.gn ++++ b/.gn +@@ -146,25 +146,25 @@ no_check_targets = [ + # this situation much easier to create. if the build always lists the + # files and passes them to a script, it will always be correct. + +-exec_script_allowlist = +- build_dotfile_settings.exec_script_allowlist + +- angle_dotfile_settings.exec_script_allowlist + +- [ +- # Allowlist entries for //build should go into +- # //build/dotfile_settings.gni instead, so that they can be shared +- # with other repos. The entries in this list should be only for files +- # in the Chromium repo outside of //build. +- "//build_overrides/build.gni", +- +- "//chrome/version.gni", +- +- "//google_apis/BUILD.gn", +- "//printing/BUILD.gn", +- +- "//remoting/host/installer/linux/BUILD.gn", +- "//remoting/remoting_version.gni", +- "//remoting/host/installer/win/generate_clsids.gni", +- +- "//tools/grit/grit_rule.gni", +- "//tools/gritsettings/BUILD.gn", +- ] ++#exec_script_allowlist = ++# build_dotfile_settings.exec_script_allowlist + ++# angle_dotfile_settings.exec_script_allowlist + ++# [ ++# # Allowlist entries for //build should go into ++# # //build/dotfile_settings.gni instead, so that they can be shared ++# # with other repos. The entries in this list should be only for files ++# # in the Chromium repo outside of //build. ++# "//build_overrides/build.gni", ++# ++# "//chrome/version.gni", ++# ++# "//google_apis/BUILD.gn", ++# "//printing/BUILD.gn", ++# ++# "//remoting/host/installer/linux/BUILD.gn", ++# "//remoting/remoting_version.gni", ++# "//remoting/host/installer/win/generate_clsids.gni", ++# ++# "//tools/grit/grit_rule.gni", ++# "//tools/gritsettings/BUILD.gn", ++# ] diff --git a/www-client/chromium/files/chromium-126-compiler.patch b/www-client/chromium/files/chromium-139-compiler-r1.patch index d93c82a..4a1e8fe 100644 --- a/www-client/chromium/files/chromium-126-compiler.patch +++ b/www-client/chromium/files/chromium-139-compiler-r1.patch @@ -1,8 +1,25 @@ diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn -index 973d8bcbd2..9be41363ff 100644 +index 0c04c90368..6cebd33c44 100644 --- a/build/config/compiler/BUILD.gn +++ b/build/config/compiler/BUILD.gn -@@ -319,9 +319,6 @@ config("compiler") { +@@ -241,16 +241,6 @@ declare_args() { + assert(!(llvm_force_head_revision && use_remoteexec && host_os != "linux"), + "rbe with locally built clang only works on linux") + +-# Whether or not we should pass the warning_suppression.txt file to clang +-# compilations. This file allows us to suppress warnings that originate from +-# specific file paths, typically third_party headers. +-# +-# Since this is referenced both when passing the file and when deciding which +-# warnings to enable, store it in a separate variable here. +-use_clang_warning_suppression_file = +- !is_nacl && default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline && is_clang && clang_warning_suppression_file != "" +- + # default_include_dirs --------------------------------------------------------- + # + # This is a separate config so that third_party code (which would not use the +@@ -320,12 +310,8 @@ config("compiler") { configs += [ # See the definitions below. @@ -11,8 +28,11 @@ index 973d8bcbd2..9be41363ff 100644 - ":compiler_cpu_abi", ":compiler_codegen", ":compiler_deterministic", +- ":clang_warning_suppression", ] -@@ -496,6 +493,9 @@ config("compiler") { + + # TODO(https://crbug.com/404297941): Disable clang_warning_suppression +@@ -515,6 +501,9 @@ config("compiler") { ldflags += [ "-fPIC" ] rustflags += [ "-Crelocation-model=pic" ] @@ -22,11 +42,11 @@ index 973d8bcbd2..9be41363ff 100644 if (!is_clang) { # Use pipes for communicating between sub-processes. Faster. # (This flag doesn't do anything with Clang.) -@@ -587,55 +587,6 @@ config("compiler") { +@@ -602,63 +591,6 @@ config("compiler") { ldflags += [ "-Wl,-z,keep-text-section-prefix" ] } -- if (is_clang && !is_nacl && current_os != "zos") { +- if (is_clang && !is_nacl) { - cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] - if (save_reproducers_on_lld_crash && use_lld) { - ldflags += [ @@ -49,9 +69,9 @@ index 973d8bcbd2..9be41363ff 100644 - } - } - -- # TODO(crbug.com/1488374): This causes binary size growth and potentially +- # TODO(crbug.com/40283598): This causes binary size growth and potentially - # other problems. -- # TODO(crbug.com/1491036): This isn't supported by Cronet's mainline llvm version. +- # TODO(crbug.com/40284925): This isn't supported by Cronet's mainline llvm version. - if (default_toolchain != "//build/toolchain/cros:target" && - !llvm_android_mainline) { - cflags += [ @@ -67,18 +87,26 @@ index 973d8bcbd2..9be41363ff 100644 - } - } - -- # TODO(crbug.com/1235145): Investigate why/if this should be needed. +- # TODO(crbug.com/40192287): Investigate why/if this should be needed. - if (is_win) { - cflags += [ "/clang:-ffp-contract=off" ] - } else { - cflags += [ "-ffp-contract=off" ] - } +- +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF +- # (excluding toolchains that use an older version of LLVM). +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. +- if (is_linux && use_lld && !llvm_android_mainline && current_cpu != "arm" && +- default_toolchain != "//build/toolchain/cros:target") { +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] +- } - } - # C11/C++11 compiler flags setup. # --------------------------- if (is_linux || is_chromeos || is_android || (is_nacl && is_clang) || -@@ -1023,17 +974,6 @@ config("compiler") { +@@ -1083,20 +1015,6 @@ config("compiler") { # `-nodefaultlibs` from the linker invocation from Rust, which would be used # to compile dylibs on Android, such as for constructing unit test APKs. "-Cdefault-linker-libraries", @@ -93,10 +121,22 @@ index 973d8bcbd2..9be41363ff 100644 - # For deterministic builds, keep the local machine's current working - # directory from appearing in build outputs. - "-Zremap-cwd-prefix=.", +- +- # We use clang-rt sanitizer runtimes. +- "-Zexternal-clangrt", ] if (!is_win || force_rustc_color_output) { -@@ -1541,46 +1481,6 @@ config("compiler_deterministic") { +@@ -1151,7 +1069,7 @@ config("compiler") { + # Don't allow unstable features to be enabled by `#![feature()]` without + # additional command line flags. + config("disallow_unstable_features") { +- rustflags = [ "-Zallow-features=" ] ++ #rustflags = [ "-Zallow-features=" ] + } + + config("libcxx_hardening") { +@@ -1631,52 +1549,6 @@ config("compiler_deterministic") { } } @@ -119,7 +159,13 @@ index 973d8bcbd2..9be41363ff 100644 - # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= - # and -fcoverage-compilation-dir=. - cflags += [ "-ffile-compilation-dir=." ] -- swiftflags += [ "-file-compilation-dir=." ] +- +- # Convert absolute paths to relative paths. Expands to, for example: +- # -file-prefix-map /path/to/chromium/src=../.. +- swiftflags += [ +- "-file-prefix-map", +- rebase_path("//.", "") + "=" + rebase_path("//.", root_build_dir), +- ] - } - if (!is_win) { - # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) @@ -143,28 +189,108 @@ index 973d8bcbd2..9be41363ff 100644 # Tells the compiler not to use absolute paths when passing the default # paths to the tools it invokes. We don't want this because we don't # really need it and it can mess up the RBE cache entries. -@@ -1599,39 +1499,6 @@ config("compiler_deterministic") { +@@ -1703,119 +1575,6 @@ config("compiler_deterministic") { } } -config("clang_revision") { -- if (is_clang && clang_base_path == default_clang_base_path) { -- update_args = [ -- "--print-revision", -- "--verify-version=$clang_version", -- ] +- if (is_clang && clang_base_path == default_clang_base_path && +- current_os != "zos") { +- _perform_consistency_checks = current_toolchain == default_toolchain - if (llvm_force_head_revision) { -- update_args += [ "--llvm-force-head-revision" ] +- _head_revision_stamp_path = "//third_party/llvm-build/force_head_revision" +- _head_revision = "" +- if (path_exists(_head_revision_stamp_path)) { +- _head_revision = read_file(_head_revision_stamp_path, "trim string") +- } +- assert( +- _head_revision != "", +- "llvm_force_head_revision=true, but no locally built version was detected.") +- _clang_revision = _head_revision +- } else { +- _clang_revision = read_file( +- "//third_party/llvm-build/Release+Asserts/cr_build_revision", +- "trim string") +- +- # Ensure that the synced clang version matches what's in git. +- if (_perform_consistency_checks) { +- # Parse the clang version from the Python script. +- _clang_version_lines = filter_include( +- read_file("//tools/clang/scripts/update.py", "list lines"), +- [ "CLANG_*REVISION = *" ]) +- _py_revision = +- string_replace(_clang_version_lines[0], "CLANG_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_clang_version_lines[1], "CLANG_SUB_REVISION = ", "") +- _expected_clang_revision = "$_py_revision-$_py_subrevision" +- +- # TODO(agrieve): Change filter_include to _clang_revision == +- # _expected_clang_revision once angle & webrtc use a GCS DEPS entry +- # rather than a update.py runhook. +- assert( +- filter_include([ _clang_revision ], +- [ +- _expected_clang_revision, +- "$_expected_clang_revision,*", +- ]) != [], +- "clang_revision=\"$_clang_revision\" but update.py expected \"$_expected_clang_revision\". Did you forget to gclient sync?") +- } +- } +- +- if (_perform_consistency_checks) { +- # Ensure that the revision matches the version major expected by GN. +- _versions_match = filter_include([ _clang_revision ], +- [ "llvmorg-$clang_version-*" ]) != [] +- assert( +- _versions_match, +- "clang_revision=\"$_clang_revision\" but clang_version=\"$clang_version\". clang_version in build/toolchain/toolchain.gni is likely outdated.") +- } +- +- if (toolchain_has_rust && _perform_consistency_checks) { +- # Ensure that the synced rust version matches what's in git. +- _rust_revision_lines = +- filter_include(read_file("//tools/rust/update_rust.py", "list lines"), +- [ "RUST_*REVISION = *" ]) +- _py_revision = +- string_replace(_rust_revision_lines[0], "RUST_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_rust_revision_lines[1], "RUST_SUB_REVISION = ", "") +- _expected_rust_revision = "$_py_revision-$_py_subrevision" +- +- # Ensure the rust version matches the clang version. +- assert( +- filter_include([ rustc_revision ], +- [ "*-$_expected_rust_revision-*" ]) != [], +- "rustc_revision=\"$rustc_revision\" but update_rust.py expected \"$_expected_rust_revision\". Run \"gclient sync\"?") - } -- clang_revision = exec_script("//tools/clang/scripts/update.py", -- update_args, -- "trim string") - - # This is here so that all files get recompiled after a clang roll and - # when turning clang on or off. (defines are passed via the command line, - # and build system rebuild things when their commandline changes). Nothing - # should ever read this define. -- defines = [ "CR_CLANG_REVISION=\"$clang_revision\"" ] +- defines = [ "CR_CLANG_REVISION=\"$_clang_revision\"" ] +- } +-} +- +-# Controls the usage of a warning suppression mapping (WSM) file to suppress +-# warnings based on the path of the file they come from. It's controlled by the +-# `clang_warning_suppression_file` gn argument , which points to a text file +-# defining which warnings should be suppressed where. +-# See //build/config/warning_suppression.txt for an example file; this is the +-# file used by Chromium. +-# +-# To use a different file, or to use this functionality outside of chromium, +-# set the `clang_warning_suppression_file` argument to point to the new file, +-# e.g. by setting in the the project's .gn file. +-config("clang_warning_suppression") { +- # Some build configs use older versions of clang that don't support WSMs +- if (use_clang_warning_suppression_file) { +- from_build_root = +- rebase_path(clang_warning_suppression_file, root_build_dir) +- inputs = [ clang_warning_suppression_file ] +- cflags = [ "--warning-suppression-mappings=" + from_build_root ] - } -} - @@ -183,7 +309,7 @@ index 973d8bcbd2..9be41363ff 100644 config("compiler_arm_fpu") { if (current_cpu == "arm" && !is_ios && !is_nacl) { cflags = [ "-mfpu=$arm_fpu" ] -@@ -2007,11 +1874,7 @@ config("chromium_code") { +@@ -2279,11 +2038,7 @@ config("chromium_code") { defines = [ "_HAS_NODISCARD" ] } } else { @@ -196,7 +322,7 @@ index 973d8bcbd2..9be41363ff 100644 # In Chromium code, we define __STDC_foo_MACROS in order to get the # C99 macros on Mac and Linux. -@@ -2020,24 +1883,6 @@ config("chromium_code") { +@@ -2292,24 +2047,6 @@ config("chromium_code") { "__STDC_FORMAT_MACROS", ] @@ -221,7 +347,7 @@ index 973d8bcbd2..9be41363ff 100644 if (is_apple) { cflags_objc = [ "-Wimplicit-retain-self" ] cflags_objcc = [ "-Wimplicit-retain-self" ] -@@ -2427,7 +2272,8 @@ config("default_stack_frames") { +@@ -2734,7 +2471,8 @@ config("default_stack_frames") { # [0]: https://pinpoint-dot-chromeperf.appspot.com/job/147634a8be0000 # [1]: https://pinpoint-dot-chromeperf.appspot.com/job/132bc772be0000 # [2]: https://crrev.com/c/5447532 @@ -229,9 +355,9 @@ index 973d8bcbd2..9be41363ff 100644 +config("optimize") { } +config("xoptimize") { if (is_win) { - cflags = [ "/O2" ] + common_optimize_on_cflags - -@@ -2468,7 +2314,8 @@ config("optimize") { + # clang-cl's /O2 corresponds to clang's -O3, and really want -O2 for + # consistency with the other platforms. +@@ -2783,7 +2521,8 @@ config("optimize") { } # Turn off optimizations. @@ -241,7 +367,7 @@ index 973d8bcbd2..9be41363ff 100644 if (is_win) { cflags = [ "/Od", # Disable optimization. -@@ -2508,7 +2355,8 @@ config("no_optimize") { +@@ -2818,7 +2557,8 @@ config("no_optimize") { # Turns up the optimization level. Used to explicitly enable -O2 instead of # -Os for select targets on platforms that use optimize_for_size. No-op # elsewhere. @@ -251,9 +377,9 @@ index 973d8bcbd2..9be41363ff 100644 if (is_nacl && is_nacl_irt) { # The NaCl IRT is a special case and always wants its own config. # Various components do: -@@ -2541,7 +2389,8 @@ config("optimize_max") { +@@ -2851,7 +2591,8 @@ config("optimize_max") { # - # TODO(crbug.com/621335) - rework how all of these configs are related + # TODO(crbug.com/41259697) - rework how all of these configs are related # so that we don't need this disclaimer. -config("optimize_speed") { +config("optimize_speed") { } @@ -261,7 +387,7 @@ index 973d8bcbd2..9be41363ff 100644 if (is_nacl && is_nacl_irt) { # The NaCl IRT is a special case and always wants its own config. # Various components do: -@@ -2570,7 +2419,8 @@ config("optimize_speed") { +@@ -2880,7 +2621,8 @@ config("optimize_speed") { } } @@ -271,7 +397,7 @@ index 973d8bcbd2..9be41363ff 100644 cflags = [ "-O1" ] + common_optimize_on_cflags rustflags = [ "-Copt-level=1" ] ldflags = common_optimize_on_ldflags -@@ -2703,7 +2553,8 @@ config("win_pdbaltpath") { +@@ -3011,7 +2753,8 @@ config("win_pdbaltpath") { } # Full symbols. @@ -279,9 +405,9 @@ index 973d8bcbd2..9be41363ff 100644 +config("symbols") { } +config("xsymbols") { rustflags = [] + configs = [] if (is_win) { - if (is_clang) { -@@ -2852,7 +2703,8 @@ config("symbols") { +@@ -3185,7 +2928,8 @@ config("symbols") { # Minimal symbols. # This config guarantees to hold symbol for stack trace which are shown to user # when crash happens in unittests running on buildbot. @@ -291,7 +417,7 @@ index 973d8bcbd2..9be41363ff 100644 rustflags = [] if (is_win) { # Functions, files, and line tables only. -@@ -2937,7 +2789,8 @@ config("minimal_symbols") { +@@ -3270,7 +3014,8 @@ config("minimal_symbols") { # This configuration contains function names only. That is, the compiler is # told to not generate debug information and the linker then just puts function # names in the final debug information. @@ -301,13 +427,26 @@ index 973d8bcbd2..9be41363ff 100644 if (is_win) { ldflags = [ "/DEBUG" ] +diff --git a/build/config/gcc/BUILD.gn b/build/config/gcc/BUILD.gn +index a659210b19..bde0e1b273 100644 +--- a/build/config/gcc/BUILD.gn ++++ b/build/config/gcc/BUILD.gn +@@ -32,7 +32,7 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ # rustflags = [ "-Zdefault-visibility=hidden" ] + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { diff --git a/build/config/rust.gni b/build/config/rust.gni -index 59fa14463b..ca780602b4 100644 +index bd18d13119..6687b7cb2f 100644 --- a/build/config/rust.gni +++ b/build/config/rust.gni -@@ -75,7 +75,8 @@ declare_args() { +@@ -77,7 +77,8 @@ declare_args() { # - # TODO(https://crbug.com/1482525): Re-enable ThinLTO for Rust on LaCrOS + # TODO(crbug.com/40281834): Re-enable ThinLTO for Rust on LaCrOS # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome - toolchain_supports_rust_thin_lto = !is_chromeos + # toolchain_supports_rust_thin_lto = !is_chromeos diff --git a/www-client/chromium/files/chromium-126-compiler-r1.patch b/www-client/chromium/files/chromium-139-compiler.patch index 6140453..fec48c7 100644 --- a/www-client/chromium/files/chromium-126-compiler-r1.patch +++ b/www-client/chromium/files/chromium-139-compiler.patch @@ -1,8 +1,8 @@ diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn -index d39de9bc56..4b37db6c59 100644 +index a17fae7220..5e763dc668 100644 --- a/build/config/compiler/BUILD.gn +++ b/build/config/compiler/BUILD.gn -@@ -305,9 +305,6 @@ config("compiler") { +@@ -310,12 +310,8 @@ config("compiler") { configs += [ # See the definitions below. @@ -11,8 +11,11 @@ index d39de9bc56..4b37db6c59 100644 - ":compiler_cpu_abi", ":compiler_codegen", ":compiler_deterministic", +- ":clang_warning_suppression", ] -@@ -483,6 +480,9 @@ config("compiler") { + + # TODO(https://crbug.com/404297941): Disable clang_warning_suppression +@@ -505,6 +501,9 @@ config("compiler") { ldflags += [ "-fPIC" ] rustflags += [ "-Crelocation-model=pic" ] @@ -22,11 +25,11 @@ index d39de9bc56..4b37db6c59 100644 if (!is_clang) { # Use pipes for communicating between sub-processes. Faster. # (This flag doesn't do anything with Clang.) -@@ -545,55 +545,6 @@ config("compiler") { +@@ -581,63 +580,6 @@ config("compiler") { ldflags += [ "-Wl,-z,keep-text-section-prefix" ] } -- if (is_clang && !is_nacl && current_os != "zos") { +- if (is_clang && !is_nacl) { - cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] - if (save_reproducers_on_lld_crash && use_lld) { - ldflags += [ @@ -73,12 +76,20 @@ index d39de9bc56..4b37db6c59 100644 - } else { - cflags += [ "-ffp-contract=off" ] - } +- +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF +- # (excluding toolchains that use an older version of LLVM). +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. +- if (is_linux && use_lld && !llvm_android_mainline && current_cpu != "arm" && +- default_toolchain != "//build/toolchain/cros:target") { +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] +- } - } - # C11/C++11 compiler flags setup. # --------------------------- if (is_linux || is_chromeos || is_android || (is_nacl && is_clang) || -@@ -998,17 +949,6 @@ config("compiler") { +@@ -1062,20 +1004,6 @@ config("compiler") { # `-nodefaultlibs` from the linker invocation from Rust, which would be used # to compile dylibs on Android, such as for constructing unit test APKs. "-Cdefault-linker-libraries", @@ -93,10 +104,22 @@ index d39de9bc56..4b37db6c59 100644 - # For deterministic builds, keep the local machine's current working - # directory from appearing in build outputs. - "-Zremap-cwd-prefix=.", +- +- # We use clang-rt sanitizer runtimes. +- "-Zexternal-clangrt", ] if (!is_win || force_rustc_color_output) { -@@ -1516,46 +1456,6 @@ config("compiler_deterministic") { +@@ -1130,7 +1058,7 @@ config("compiler") { + # Don't allow unstable features to be enabled by `#![feature()]` without + # additional command line flags. + config("disallow_unstable_features") { +- rustflags = [ "-Zallow-features=" ] ++ #rustflags = [ "-Zallow-features=" ] + } + + config("libcxx_hardening") { +@@ -1610,52 +1538,6 @@ config("compiler_deterministic") { } } @@ -119,7 +142,13 @@ index d39de9bc56..4b37db6c59 100644 - # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= - # and -fcoverage-compilation-dir=. - cflags += [ "-ffile-compilation-dir=." ] -- swiftflags += [ "-file-compilation-dir=." ] +- +- # Convert absolute paths to relative paths. Expands to, for example: +- # -file-prefix-map /path/to/chromium/src=../.. +- swiftflags += [ +- "-file-prefix-map", +- rebase_path("//.", "") + "=" + rebase_path("//.", root_build_dir), +- ] - } - if (!is_win) { - # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) @@ -143,28 +172,110 @@ index d39de9bc56..4b37db6c59 100644 # Tells the compiler not to use absolute paths when passing the default # paths to the tools it invokes. We don't want this because we don't # really need it and it can mess up the RBE cache entries. -@@ -1574,39 +1474,6 @@ config("compiler_deterministic") { +@@ -1682,121 +1564,6 @@ config("compiler_deterministic") { } } -config("clang_revision") { -- if (is_clang && clang_base_path == default_clang_base_path) { -- update_args = [ -- "--print-revision", -- "--verify-version=$clang_version", -- ] +- if (is_clang && clang_base_path == default_clang_base_path && +- current_os != "zos") { +- _perform_consistency_checks = current_toolchain == default_toolchain - if (llvm_force_head_revision) { -- update_args += [ "--llvm-force-head-revision" ] +- _head_revision_stamp_path = "//third_party/llvm-build/force_head_revision" +- _head_revision = "" +- if (path_exists(_head_revision_stamp_path)) { +- _head_revision = read_file(_head_revision_stamp_path, "trim string") +- } +- assert( +- _head_revision != "", +- "llvm_force_head_revision=true, but no locally built version was detected.") +- _clang_revision = _head_revision +- } else { +- _clang_revision = read_file( +- "//third_party/llvm-build/Release+Asserts/cr_build_revision", +- "trim string") +- +- # Ensure that the synced clang version matches what's in git. +- if (_perform_consistency_checks) { +- # Parse the clang version from the Python script. +- _clang_version_lines = filter_include( +- read_file("//tools/clang/scripts/update.py", "list lines"), +- [ "CLANG_*REVISION = *" ]) +- _py_revision = +- string_replace(_clang_version_lines[0], "CLANG_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_clang_version_lines[1], "CLANG_SUB_REVISION = ", "") +- _expected_clang_revision = "$_py_revision-$_py_subrevision" +- +- # TODO(agrieve): Change filter_include to _clang_revision == +- # _expected_clang_revision once angle & webrtc use a GCS DEPS entry +- # rather than a update.py runhook. +- assert( +- filter_include([ _clang_revision ], +- [ +- _expected_clang_revision, +- "$_expected_clang_revision,*", +- ]) != [], +- "clang_revision=\"$_clang_revision\" but update.py expected \"$_expected_clang_revision\". Did you forget to gclient sync?") +- } +- } +- +- if (_perform_consistency_checks) { +- # Ensure that the revision matches the version major expected by GN. +- _versions_match = filter_include([ _clang_revision ], +- [ "llvmorg-$clang_version-*" ]) != [] +- assert( +- _versions_match, +- "clang_revision=\"$_clang_revision\" but clang_version=\"$clang_version\". clang_version in build/toolchain/toolchain.gni is likely outdated.") +- } +- +- if (toolchain_has_rust && _perform_consistency_checks) { +- # Ensure that the synced rust version matches what's in git. +- _rust_revision_lines = +- filter_include(read_file("//tools/rust/update_rust.py", "list lines"), +- [ "RUST_*REVISION = *" ]) +- _py_revision = +- string_replace(_rust_revision_lines[0], "RUST_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_rust_revision_lines[1], "RUST_SUB_REVISION = ", "") +- _expected_rust_revision = "$_py_revision-$_py_subrevision" +- +- # Ensure the rust version matches the clang version. +- assert( +- filter_include([ rustc_revision ], +- [ "*-$_expected_rust_revision-*" ]) != [], +- "rustc_revision=\"$rustc_revision\" but update_rust.py expected \"$_expected_rust_revision\". Run \"gclient sync\"?") - } -- clang_revision = exec_script("//tools/clang/scripts/update.py", -- update_args, -- "trim string") - - # This is here so that all files get recompiled after a clang roll and - # when turning clang on or off. (defines are passed via the command line, - # and build system rebuild things when their commandline changes). Nothing - # should ever read this define. -- defines = [ "CR_CLANG_REVISION=\"$clang_revision\"" ] +- defines = [ "CR_CLANG_REVISION=\"$_clang_revision\"" ] +- } +-} +- +-# Controls the usage of a warning suppression mapping (WSM) file to suppress +-# warnings based on the path of the file they come from. It's controlled by the +-# `clang_warning_suppression_file` gn argument , which points to a text file +-# defining which warnings should be suppressed where. +-# See //build/config/warning_suppression.txt for an example file; this is the +-# file used by Chromium. +-# +-# To use a different file, or to use this functionality outside of chromium, +-# set the `clang_warning_suppression_file` argument to point to the new file, +-# e.g. by setting in the the project's .gn file. +-config("clang_warning_suppression") { +- # Some build configs use older versions of clang that don't support WSMs +- if (!is_nacl && default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline && is_clang && +- clang_warning_suppression_file != "") { +- from_build_root = +- rebase_path(clang_warning_suppression_file, root_build_dir) +- inputs = [ clang_warning_suppression_file ] +- cflags = [ "--warning-suppression-mappings=" + from_build_root ] - } -} - @@ -183,7 +294,7 @@ index d39de9bc56..4b37db6c59 100644 config("compiler_arm_fpu") { if (current_cpu == "arm" && !is_ios && !is_nacl) { cflags = [ "-mfpu=$arm_fpu" ] -@@ -1982,11 +1849,7 @@ config("chromium_code") { +@@ -2248,11 +2015,7 @@ config("chromium_code") { defines = [ "_HAS_NODISCARD" ] } } else { @@ -196,7 +307,7 @@ index d39de9bc56..4b37db6c59 100644 # In Chromium code, we define __STDC_foo_MACROS in order to get the # C99 macros on Mac and Linux. -@@ -1995,24 +1858,6 @@ config("chromium_code") { +@@ -2261,24 +2024,6 @@ config("chromium_code") { "__STDC_FORMAT_MACROS", ] @@ -221,7 +332,7 @@ index d39de9bc56..4b37db6c59 100644 if (is_apple) { cflags_objc = [ "-Wimplicit-retain-self" ] cflags_objcc = [ "-Wimplicit-retain-self" ] -@@ -2402,7 +2247,8 @@ config("default_stack_frames") { +@@ -2703,7 +2448,8 @@ config("default_stack_frames") { # [0]: https://pinpoint-dot-chromeperf.appspot.com/job/147634a8be0000 # [1]: https://pinpoint-dot-chromeperf.appspot.com/job/132bc772be0000 # [2]: https://crrev.com/c/5447532 @@ -229,9 +340,9 @@ index d39de9bc56..4b37db6c59 100644 +config("optimize") { } +config("xoptimize") { if (is_win) { - cflags = [ "/O2" ] + common_optimize_on_cflags - -@@ -2443,7 +2289,8 @@ config("optimize") { + # clang-cl's /O2 corresponds to clang's -O3, and really want -O2 for + # consistency with the other platforms. +@@ -2752,7 +2498,8 @@ config("optimize") { } # Turn off optimizations. @@ -241,7 +352,7 @@ index d39de9bc56..4b37db6c59 100644 if (is_win) { cflags = [ "/Od", # Disable optimization. -@@ -2483,7 +2330,8 @@ config("no_optimize") { +@@ -2787,7 +2534,8 @@ config("no_optimize") { # Turns up the optimization level. Used to explicitly enable -O2 instead of # -Os for select targets on platforms that use optimize_for_size. No-op # elsewhere. @@ -251,7 +362,7 @@ index d39de9bc56..4b37db6c59 100644 if (is_nacl && is_nacl_irt) { # The NaCl IRT is a special case and always wants its own config. # Various components do: -@@ -2516,7 +2364,8 @@ config("optimize_max") { +@@ -2820,7 +2568,8 @@ config("optimize_max") { # # TODO(crbug.com/41259697) - rework how all of these configs are related # so that we don't need this disclaimer. @@ -261,7 +372,7 @@ index d39de9bc56..4b37db6c59 100644 if (is_nacl && is_nacl_irt) { # The NaCl IRT is a special case and always wants its own config. # Various components do: -@@ -2545,7 +2394,8 @@ config("optimize_speed") { +@@ -2849,7 +2598,8 @@ config("optimize_speed") { } } @@ -271,7 +382,7 @@ index d39de9bc56..4b37db6c59 100644 cflags = [ "-O1" ] + common_optimize_on_cflags rustflags = [ "-Copt-level=1" ] ldflags = common_optimize_on_ldflags -@@ -2678,7 +2528,8 @@ config("win_pdbaltpath") { +@@ -2980,7 +2730,8 @@ config("win_pdbaltpath") { } # Full symbols. @@ -279,9 +390,9 @@ index d39de9bc56..4b37db6c59 100644 +config("symbols") { } +config("xsymbols") { rustflags = [] + configs = [] if (is_win) { - if (is_clang) { -@@ -2828,7 +2679,8 @@ config("symbols") { +@@ -3154,7 +2905,8 @@ config("symbols") { # Minimal symbols. # This config guarantees to hold symbol for stack trace which are shown to user # when crash happens in unittests running on buildbot. @@ -291,7 +402,7 @@ index d39de9bc56..4b37db6c59 100644 rustflags = [] if (is_win) { # Functions, files, and line tables only. -@@ -2913,7 +2765,8 @@ config("minimal_symbols") { +@@ -3239,7 +2991,8 @@ config("minimal_symbols") { # This configuration contains function names only. That is, the compiler is # told to not generate debug information and the linker then just puts function # names in the final debug information. @@ -301,11 +412,24 @@ index d39de9bc56..4b37db6c59 100644 if (is_win) { ldflags = [ "/DEBUG" ] +diff --git a/build/config/gcc/BUILD.gn b/build/config/gcc/BUILD.gn +index a659210b19..bde0e1b273 100644 +--- a/build/config/gcc/BUILD.gn ++++ b/build/config/gcc/BUILD.gn +@@ -32,7 +32,7 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ # rustflags = [ "-Zdefault-visibility=hidden" ] + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { diff --git a/build/config/rust.gni b/build/config/rust.gni -index e99d7d08e1..898b3e6630 100644 +index bd18d13119..6687b7cb2f 100644 --- a/build/config/rust.gni +++ b/build/config/rust.gni -@@ -75,7 +75,8 @@ declare_args() { +@@ -77,7 +77,8 @@ declare_args() { # # TODO(crbug.com/40281834): Re-enable ThinLTO for Rust on LaCrOS # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome diff --git a/www-client/chromium/files/chromium-139-mv2-ungoogled-r1.patch b/www-client/chromium/files/chromium-139-mv2-ungoogled-r1.patch new file mode 100644 index 0000000..36d3419 --- /dev/null +++ b/www-client/chromium/files/chromium-139-mv2-ungoogled-r1.patch @@ -0,0 +1,163 @@ +diff --git a/chrome/browser/extensions/api/developer_private/extension_info_generator.cc b/chrome/browser/extensions/api/developer_private/extension_info_generator.cc +index 99e7a64fee..924592d366 100644 +--- a/chrome/browser/extensions/api/developer_private/extension_info_generator.cc ++++ b/chrome/browser/extensions/api/developer_private/extension_info_generator.cc +@@ -595,17 +595,6 @@ void ExtensionInfoGenerator::FillExtensionInfo(const Extension& extension, + info.controlled_info.emplace(); + info.controlled_info->text = + l10n_util::GetStringUTF8(IDS_EXTENSIONS_INSTALL_LOCATION_ENTERPRISE); +- } else { +- // Create Safety Hub information for any non-enterprise extension. +- developer::SafetyCheckWarningReason warning_reason = +- ExtensionSafetyCheckUtils::GetSafetyCheckWarningReason(extension, +- profile); +- if (warning_reason != developer::SafetyCheckWarningReason::kNone) { +- info.safety_check_warning_reason = warning_reason; +- info.safety_check_text = +- ExtensionSafetyCheckUtils::GetSafetyCheckWarningStrings( +- warning_reason, state); +- } + } + + bool is_enabled = state == developer::ExtensionState::kEnabled; +diff --git a/chrome/browser/extensions/extension_management.cc b/chrome/browser/extensions/extension_management.cc +index 7d55128c57..1f0e2b931a 100644 +--- a/chrome/browser/extensions/extension_management.cc ++++ b/chrome/browser/extensions/extension_management.cc +@@ -355,31 +355,7 @@ bool ExtensionManagement::IsAllowedManifestVersion( + int manifest_version, + const std::string& extension_id, + Manifest::Type manifest_type) { +- bool enabled_by_default = +- !base::FeatureList::IsEnabled( +- extensions_features::kExtensionsManifestV3Only) || +- manifest_version >= 3; +- +- // Manifest version policy only supports normal extensions and Chrome OS login +- // screen extension. +- if (manifest_type != Manifest::Type::TYPE_EXTENSION && +- manifest_type != Manifest::Type::TYPE_LOGIN_SCREEN_EXTENSION) { +- return enabled_by_default; +- } +- switch (global_settings_->manifest_v2_setting) { +- case internal::GlobalSettings::ManifestV2Setting::kDefault: +- return enabled_by_default; +- case internal::GlobalSettings::ManifestV2Setting::kDisabled: +- return manifest_version >= 3; +- case internal::GlobalSettings::ManifestV2Setting::kEnabled: + return true; +- case internal::GlobalSettings::ManifestV2Setting::kEnabledForForceInstalled: +- auto installation_mode = +- GetInstallationMode(extension_id, /*update_url=*/std::string()); +- return manifest_version >= 3 || +- installation_mode == ManagedInstallationMode::kForced || +- installation_mode == ManagedInstallationMode::kRecommended; +- } + } + + bool ExtensionManagement::IsAllowedManifestVersion(const Extension* extension) { +@@ -400,26 +376,8 @@ bool ExtensionManagement::IsExemptFromMV2DeprecationByPolicy( + return false; + } + +- switch (global_settings_->manifest_v2_setting) { +- case internal::GlobalSettings::ManifestV2Setting::kDefault: +- // Default browser behavior. Not exempt. +- return false; +- case internal::GlobalSettings::ManifestV2Setting::kDisabled: +- // All MV2 extensions are disallowed. Not exempt. +- return false; +- case internal::GlobalSettings::ManifestV2Setting::kEnabled: + // All MV2 extensions are allowed. Exempt. + return true; +- case internal::GlobalSettings::ManifestV2Setting::kEnabledForForceInstalled: +- // Force-installed MV2 extensions are allowed. Exempt if it's a force- +- // installed extension only. +- auto installation_mode = +- GetInstallationMode(extension_id, /*update_url=*/std::string()); +- return installation_mode == ManagedInstallationMode::kForced || +- installation_mode == ManagedInstallationMode::kRecommended; +- } +- +- return false; + } + + bool ExtensionManagement::IsAllowedByUnpublishedAvailabilityPolicy( +diff --git a/chrome/browser/extensions/manifest_v2_experiment_manager.cc b/chrome/browser/extensions/manifest_v2_experiment_manager.cc +index 08b7de6995..47ff0885ad 100644 +--- a/chrome/browser/extensions/manifest_v2_experiment_manager.cc ++++ b/chrome/browser/extensions/manifest_v2_experiment_manager.cc +@@ -145,22 +145,6 @@ bool ManifestV2ExperimentManagerFactory::ServiceIsCreatedWithBrowserContext() + + // Determines the current stage of the MV2 deprecation experiments. + MV2ExperimentStage CalculateCurrentExperimentStage() { +- // Return the "highest" stage that is currently active for the user. +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2Unsupported)) { +- return MV2ExperimentStage::kUnsupported; +- } +- +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2Disabled)) { +- return MV2ExperimentStage::kDisableWithReEnable; +- } +- +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2DeprecationWarning)) { +- return MV2ExperimentStage::kWarning; +- } +- + return MV2ExperimentStage::kNone; + } + +@@ -200,19 +184,7 @@ PrefMap GetGlobalNoticeAcknowledgedPrefFor( + // Returns true if legacy extensions should be disabled, looking at both + // experiment stage and global state. + bool ShouldDisableLegacyExtensions(MV2ExperimentStage stage) { +- if (g_allow_mv2_for_testing) { +- // We allow legacy MV2 extensions for testing purposes. +- return false; +- } +- +- switch (stage) { +- case MV2ExperimentStage::kNone: +- case MV2ExperimentStage::kWarning: + return false; +- case MV2ExperimentStage::kDisableWithReEnable: +- case MV2ExperimentStage::kUnsupported: +- return true; +- } + } + + // Returns true if the given `stage` is one in which extension enablement should +diff --git a/chrome/browser/ui/webui/extensions/extensions_ui.cc b/chrome/browser/ui/webui/extensions/extensions_ui.cc +index 7f00cde25c..64bb58da80 100644 +--- a/chrome/browser/ui/webui/extensions/extensions_ui.cc ++++ b/chrome/browser/ui/webui/extensions/extensions_ui.cc +@@ -482,7 +482,7 @@ content::WebUIDataSource* CreateAndAddExtensionsSource(Profile* profile, + extensions_features::kExtensionsMenuAccessControlWithPermittedSites)); + source->AddBoolean( + "safetyHubThreeDotDetails", +- base::FeatureList::IsEnabled(features::kSafetyHubThreeDotDetails)); ++ false); + + // MV2 deprecation. + auto* mv2_experiment_manager = ManifestV2ExperimentManager::Get(profile); +diff --git a/extensions/common/extension.cc b/extensions/common/extension.cc +index d92362bb78..626edc0b64 100644 +--- a/extensions/common/extension.cc ++++ b/extensions/common/extension.cc +@@ -104,13 +104,6 @@ bool IsManifestSupported(int manifest_version, + // Supported versions are always safe. + if (manifest_version >= kMinimumSupportedManifestVersion && + manifest_version <= kMaximumSupportedManifestVersion) { +- // Emit a warning for unpacked extensions on Manifest V2 warning that +- // MV2 is deprecated. +- if (type == Manifest::TYPE_EXTENSION && manifest_version == 2 && +- Manifest::IsUnpackedLocation(location) && +- !g_silence_deprecated_manifest_version_warnings) { +- *warning = errors::kManifestV2IsDeprecatedWarning; +- } + return true; + } + diff --git a/www-client/chromium/files/chromium-139-mv2-ungoogled.patch b/www-client/chromium/files/chromium-139-mv2-ungoogled.patch new file mode 100644 index 0000000..9450773 --- /dev/null +++ b/www-client/chromium/files/chromium-139-mv2-ungoogled.patch @@ -0,0 +1,163 @@ +diff --git a/chrome/browser/extensions/api/developer_private/extension_info_generator_shared.cc b/chrome/browser/extensions/api/developer_private/extension_info_generator_shared.cc +index 3950614ed7..fecfe19744 100644 +--- a/chrome/browser/extensions/api/developer_private/extension_info_generator_shared.cc ++++ b/chrome/browser/extensions/api/developer_private/extension_info_generator_shared.cc +@@ -596,17 +596,6 @@ void ExtensionInfoGeneratorShared::FillExtensionInfo( + info.controlled_info.emplace(); + info.controlled_info->text = + l10n_util::GetStringUTF8(IDS_EXTENSIONS_INSTALL_LOCATION_ENTERPRISE); +- } else { +- // Create Safety Hub information for any non-enterprise extension. +- developer::SafetyCheckWarningReason warning_reason = +- ExtensionSafetyCheckUtils::GetSafetyCheckWarningReason(extension, +- profile); +- if (warning_reason != developer::SafetyCheckWarningReason::kNone) { +- info.safety_check_warning_reason = warning_reason; +- info.safety_check_text = +- ExtensionSafetyCheckUtils::GetSafetyCheckWarningStrings( +- warning_reason, state); +- } + } + + bool is_enabled = state == developer::ExtensionState::kEnabled; +diff --git a/chrome/browser/extensions/extension_management.cc b/chrome/browser/extensions/extension_management.cc +index ae782891ad..b0b82002e2 100644 +--- a/chrome/browser/extensions/extension_management.cc ++++ b/chrome/browser/extensions/extension_management.cc +@@ -322,31 +322,7 @@ bool ExtensionManagement::IsAllowedManifestVersion( + int manifest_version, + const std::string& extension_id, + Manifest::Type manifest_type) { +- bool enabled_by_default = +- !base::FeatureList::IsEnabled( +- extensions_features::kExtensionsManifestV3Only) || +- manifest_version >= 3; +- +- // Manifest version policy only supports normal extensions and Chrome OS login +- // screen extension. +- if (manifest_type != Manifest::Type::TYPE_EXTENSION && +- manifest_type != Manifest::Type::TYPE_LOGIN_SCREEN_EXTENSION) { +- return enabled_by_default; +- } +- switch (global_settings_->manifest_v2_setting) { +- case internal::GlobalSettings::ManifestV2Setting::kDefault: +- return enabled_by_default; +- case internal::GlobalSettings::ManifestV2Setting::kDisabled: +- return manifest_version >= 3; +- case internal::GlobalSettings::ManifestV2Setting::kEnabled: + return true; +- case internal::GlobalSettings::ManifestV2Setting::kEnabledForForceInstalled: +- auto installation_mode = +- GetInstallationMode(extension_id, /*update_url=*/std::string()); +- return manifest_version >= 3 || +- installation_mode == ManagedInstallationMode::kForced || +- installation_mode == ManagedInstallationMode::kRecommended; +- } + } + + bool ExtensionManagement::IsAllowedManifestVersion(const Extension* extension) { +@@ -367,26 +343,8 @@ bool ExtensionManagement::IsExemptFromMV2DeprecationByPolicy( + return false; + } + +- switch (global_settings_->manifest_v2_setting) { +- case internal::GlobalSettings::ManifestV2Setting::kDefault: +- // Default browser behavior. Not exempt. +- return false; +- case internal::GlobalSettings::ManifestV2Setting::kDisabled: +- // All MV2 extensions are disallowed. Not exempt. +- return false; +- case internal::GlobalSettings::ManifestV2Setting::kEnabled: + // All MV2 extensions are allowed. Exempt. + return true; +- case internal::GlobalSettings::ManifestV2Setting::kEnabledForForceInstalled: +- // Force-installed MV2 extensions are allowed. Exempt if it's a force- +- // installed extension only. +- auto installation_mode = +- GetInstallationMode(extension_id, /*update_url=*/std::string()); +- return installation_mode == ManagedInstallationMode::kForced || +- installation_mode == ManagedInstallationMode::kRecommended; +- } +- +- return false; + } + + bool ExtensionManagement::IsAllowedByUnpublishedAvailabilityPolicy( +diff --git a/chrome/browser/extensions/manifest_v2_experiment_manager.cc b/chrome/browser/extensions/manifest_v2_experiment_manager.cc +index 08b7de6995..47ff0885ad 100644 +--- a/chrome/browser/extensions/manifest_v2_experiment_manager.cc ++++ b/chrome/browser/extensions/manifest_v2_experiment_manager.cc +@@ -145,22 +145,6 @@ bool ManifestV2ExperimentManagerFactory::ServiceIsCreatedWithBrowserContext() + + // Determines the current stage of the MV2 deprecation experiments. + MV2ExperimentStage CalculateCurrentExperimentStage() { +- // Return the "highest" stage that is currently active for the user. +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2Unsupported)) { +- return MV2ExperimentStage::kUnsupported; +- } +- +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2Disabled)) { +- return MV2ExperimentStage::kDisableWithReEnable; +- } +- +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2DeprecationWarning)) { +- return MV2ExperimentStage::kWarning; +- } +- + return MV2ExperimentStage::kNone; + } + +@@ -200,19 +184,7 @@ PrefMap GetGlobalNoticeAcknowledgedPrefFor( + // Returns true if legacy extensions should be disabled, looking at both + // experiment stage and global state. + bool ShouldDisableLegacyExtensions(MV2ExperimentStage stage) { +- if (g_allow_mv2_for_testing) { +- // We allow legacy MV2 extensions for testing purposes. +- return false; +- } +- +- switch (stage) { +- case MV2ExperimentStage::kNone: +- case MV2ExperimentStage::kWarning: + return false; +- case MV2ExperimentStage::kDisableWithReEnable: +- case MV2ExperimentStage::kUnsupported: +- return true; +- } + } + + // Returns true if the given `stage` is one in which extension enablement should +diff --git a/chrome/browser/ui/webui/extensions/extensions_ui.cc b/chrome/browser/ui/webui/extensions/extensions_ui.cc +index 7a4d1338c4..9c599a5e7d 100644 +--- a/chrome/browser/ui/webui/extensions/extensions_ui.cc ++++ b/chrome/browser/ui/webui/extensions/extensions_ui.cc +@@ -490,7 +490,7 @@ content::WebUIDataSource* CreateAndAddExtensionsSource(Profile* profile, + extensions_features::kExtensionsMenuAccessControlWithPermittedSites)); + source->AddBoolean( + "safetyHubThreeDotDetails", +- base::FeatureList::IsEnabled(features::kSafetyHubThreeDotDetails)); ++ false); + + // MV2 deprecation. + auto* mv2_experiment_manager = ManifestV2ExperimentManager::Get(profile); +diff --git a/extensions/common/extension.cc b/extensions/common/extension.cc +index f82aaf92ad..48041098a8 100644 +--- a/extensions/common/extension.cc ++++ b/extensions/common/extension.cc +@@ -104,13 +104,6 @@ bool IsManifestSupported(int manifest_version, + // Supported versions are always safe. + if (manifest_version >= kMinimumSupportedManifestVersion && + manifest_version <= kMaximumSupportedManifestVersion) { +- // Emit a warning for unpacked extensions on Manifest V2 warning that +- // MV2 is deprecated. +- if (type == Manifest::TYPE_EXTENSION && manifest_version == 2 && +- Manifest::IsUnpackedLocation(location) && +- !g_silence_deprecated_manifest_version_warnings) { +- *warning = errors::kManifestV2IsDeprecatedWarning; +- } + return true; + } + diff --git a/www-client/chromium/files/chromium-105-protobuf-RepeatedPtrField-export.patch b/www-client/chromium/files/chromium-139-protobuf-RepeatedPtrField-export.patch index e20bc22..948eede 100644 --- a/www-client/chromium/files/chromium-105-protobuf-RepeatedPtrField-export.patch +++ b/www-client/chromium/files/chromium-139-protobuf-RepeatedPtrField-export.patch @@ -1,13 +1,13 @@ diff --git a/third_party/protobuf/src/google/protobuf/repeated_ptr_field.h b/third_party/protobuf/src/google/protobuf/repeated_ptr_field.h -index e81b2c7e4..df3811563 100644 +index e98f8df605..6035b0b84b 100644 --- a/third_party/protobuf/src/google/protobuf/repeated_ptr_field.h +++ b/third_party/protobuf/src/google/protobuf/repeated_ptr_field.h -@@ -847,7 +847,7 @@ class StringTypeHandler { +@@ -944,7 +944,7 @@ class GenericTypeHandler<std::string> { // RepeatedPtrField is like RepeatedField, but used for repeated strings or // Messages. template <typename Element> --class RepeatedPtrField final : private internal::RepeatedPtrFieldBase { -+class PROTOBUF_EXPORT RepeatedPtrField final : private internal::RepeatedPtrFieldBase { - - public: - constexpr RepeatedPtrField(); +-class ABSL_ATTRIBUTE_WARN_UNUSED RepeatedPtrField final ++class PROTOBUF_EXPORT ABSL_ATTRIBUTE_WARN_UNUSED RepeatedPtrField final + : private internal::RepeatedPtrFieldBase { + static_assert(!std::is_const<Element>::value, + "We do not support const value types."); diff --git a/www-client/chromium/files/chromium-140-compiler-r1.patch b/www-client/chromium/files/chromium-140-compiler-r1.patch new file mode 100644 index 0000000..04bb6eb --- /dev/null +++ b/www-client/chromium/files/chromium-140-compiler-r1.patch @@ -0,0 +1,457 @@ +diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn +index c015cf2..bc128b9 100644 +--- a/build/config/compiler/BUILD.gn ++++ b/build/config/compiler/BUILD.gn +@@ -265,16 +265,6 @@ declare_args() { + assert(!(llvm_force_head_revision && use_remoteexec && host_os != "linux"), + "rbe with locally built clang only works on linux") + +-# Whether or not we should pass the warning_suppression.txt file to clang +-# compilations. This file allows us to suppress warnings that originate from +-# specific file paths, typically third_party headers. +-# +-# Since this is referenced both when passing the file and when deciding which +-# warnings to enable, store it in a separate variable here. +-use_clang_warning_suppression_file = +- default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline && is_clang && clang_warning_suppression_file != "" +- + # default_include_dirs --------------------------------------------------------- + # + # This is a separate config so that third_party code (which would not use the +@@ -342,12 +332,8 @@ config("compiler") { + + configs += [ + # See the definitions below. +- ":clang_revision", +- ":rustc_revision", +- ":compiler_cpu_abi", + ":compiler_codegen", + ":compiler_deterministic", +- ":clang_warning_suppression", + ] + + # TODO(https://crbug.com/404297941): Disable clang_warning_suppression +@@ -548,6 +534,9 @@ config("compiler") { + ldflags += [ "-fPIC" ] + rustflags += [ "-Crelocation-model=pic" ] + ++ extra_rustflags = getenv("RUSTFLAGS") ++ rustflags += [ extra_rustflags ] ++ + if (!is_clang) { + # Use pipes for communicating between sub-processes. Faster. + # (This flag doesn't do anything with Clang.) +@@ -639,66 +628,6 @@ config("compiler") { + ldflags += [ "-Wl,-z,keep-text-section-prefix" ] + } + +- if (is_clang) { +- cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] +- if (save_reproducers_on_lld_crash && use_lld) { +- ldflags += [ +- "-fcrash-diagnostics=all", +- "-fcrash-diagnostics-dir=" + clang_diagnostic_dir, +- ] +- } +- +- # TODO(hans): Remove this once Clang generates better optimized debug info +- # by default. https://crbug.com/765793 +- cflags += [ +- "-mllvm", +- "-instcombine-lower-dbg-declare=0", +- ] +- if (!is_debug && use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-instcombine-lower-dbg-declare=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-instcombine-lower-dbg-declare=0" ] +- } +- } +- +- # TODO(crbug.com/40283598): This causes binary size growth and potentially +- # other problems. +- # TODO(crbug.com/40284925): This isn't supported by Cronet's mainline llvm version. +- if (default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline) { +- cflags += [ +- "-mllvm", +- "-split-threshold-for-reg-with-hint=0", +- ] +- if (use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ] +- } +- } +- } +- +- # TODO(crbug.com/40192287): Investigate why/if this should be needed. +- if (is_win) { +- cflags += [ "/clang:-ffp-contract=off" ] +- } else { +- cflags += [ "-ffp-contract=off" ] +- } +- +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF +- # (excluding toolchains that use an older version of LLVM). +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. +- # It also causes segfault on Linux s390x: +- # https://github.com/llvm/llvm-project/issues/149511 +- if (is_linux && use_lld && !llvm_android_mainline && current_cpu != "arm" && +- current_cpu != "s390x" && +- default_toolchain != "//build/toolchain/cros:target") { +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] +- } +- } +- + # C11/C++11 compiler flags setup. + # --------------------------- + if (is_linux || is_chromeos || is_android || current_os == "aix") { +@@ -1111,20 +1040,6 @@ config("compiler") { + # `-nodefaultlibs` from the linker invocation from Rust, which would be used + # to compile dylibs on Android, such as for constructing unit test APKs. + "-Cdefault-linker-libraries", +- +- # To make Rust .d files compatible with ninja +- "-Zdep-info-omit-d-target", +- +- # If a macro panics during compilation, show which macro and where it is +- # defined. +- "-Zmacro-backtrace", +- +- # For deterministic builds, keep the local machine's current working +- # directory from appearing in build outputs. +- "-Zremap-cwd-prefix=.", +- +- # We use clang-rt sanitizer runtimes. +- "-Zexternal-clangrt", + ] + + if (!is_win || force_rustc_color_output) { +@@ -1179,7 +1094,7 @@ config("compiler") { + # Don't allow unstable features to be enabled by `#![feature()]` without + # additional command line flags. + config("disallow_unstable_features") { +- rustflags = [ "-Zallow-features=" ] ++ #rustflags = [ "-Zallow-features=" ] + } + + config("libcxx_hardening") { +@@ -1649,43 +1564,6 @@ config("compiler_deterministic") { + } + } + +- # Makes builds independent of absolute file path. +- if (is_clang && strip_absolute_paths_from_debug_symbols) { +- # If debug option is given, clang includes $cwd in debug info by default. +- # For such build, this flag generates reproducible obj files even we use +- # different build directory like "out/feature_a" and "out/feature_b" if +- # we build same files with same compile flag. +- # Other paths are already given in relative, no need to normalize them. +- +- # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= +- # and -fcoverage-compilation-dir=. +- cflags += [ "-ffile-compilation-dir=." ] +- +- # Convert absolute paths to relative paths. Expands to, for example: +- # -file-prefix-map /path/to/chromium/src=../.. +- swiftflags += [ +- "-file-prefix-map", +- rebase_path("//.", "") + "=" + rebase_path("//.", root_build_dir), +- ] +- if (!is_win) { +- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) +- asmflags = [ "-Wa,-fdebug-compilation-dir,." ] +- } +- +- if (is_win && use_lld) { +- if (symbol_level == 2 || (is_clang && using_sanitizer)) { +- # Absolutize source file paths for PDB. Pass the real build directory +- # if the pdb contains source-level debug information and if linker +- # reproducibility is not critical. +- ldflags += [ "/PDBSourcePath:" + rebase_path(root_build_dir) ] +- } else { +- # Use a fake fixed base directory for paths in the pdb to make the pdb +- # output fully deterministic and independent of the build directory. +- ldflags += [ "/PDBSourcePath:o:\fake\prefix" ] +- } +- } +- } +- + # Tells the compiler not to use absolute paths when passing the default + # paths to the tools it invokes. We don't want this because we don't + # really need it and it can mess up the RBE cache entries. +@@ -1712,107 +1590,6 @@ config("compiler_deterministic") { + } + } + +-config("clang_revision") { +- if (is_clang && clang_base_path == default_clang_base_path && +- current_os != "zos") { +- _perform_consistency_checks = current_toolchain == default_toolchain +- if (llvm_force_head_revision) { +- _head_revision_stamp_path = "//third_party/llvm-build/force_head_revision" +- _head_revision = "" +- if (path_exists(_head_revision_stamp_path)) { +- _head_revision = read_file(_head_revision_stamp_path, "trim string") +- } +- assert( +- _head_revision != "", +- "llvm_force_head_revision=true, but no locally built version was detected.") +- _clang_revision = _head_revision +- } else { +- _clang_revision = read_file( +- "//third_party/llvm-build/Release+Asserts/cr_build_revision", +- "trim string") +- +- # Ensure that the synced clang version matches what's in git. +- if (_perform_consistency_checks) { +- # Parse the clang version from the Python script. +- _clang_version_lines = filter_include( +- read_file("//tools/clang/scripts/update.py", "list lines"), +- [ "CLANG_*REVISION = *" ]) +- _py_revision = +- string_replace(_clang_version_lines[0], "CLANG_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_clang_version_lines[1], "CLANG_SUB_REVISION = ", "") +- _expected_clang_revision = "$_py_revision-$_py_subrevision" +- +- # TODO(agrieve): Change filter_include to _clang_revision == +- # _expected_clang_revision once angle & webrtc use a GCS DEPS entry +- # rather than a update.py runhook. +- assert( +- filter_include([ _clang_revision ], +- [ +- _expected_clang_revision, +- "$_expected_clang_revision,*", +- ]) != [], +- "clang_revision=\"$_clang_revision\" but update.py expected \"$_expected_clang_revision\". Did you forget to gclient sync?") +- } +- } +- +- if (_perform_consistency_checks) { +- # Ensure that the revision matches the version major expected by GN. +- _versions_match = filter_include([ _clang_revision ], +- [ "llvmorg-$clang_version-*" ]) != [] +- assert( +- _versions_match, +- "clang_revision=\"$_clang_revision\" but clang_version=\"$clang_version\". clang_version in build/toolchain/toolchain.gni is likely outdated.") +- } +- +- if (toolchain_has_rust && _perform_consistency_checks) { +- # Ensure that the synced rust version matches what's in git. +- _rust_revision_lines = +- filter_include(read_file("//tools/rust/update_rust.py", "list lines"), +- [ "RUST_*REVISION = *" ]) +- _py_revision = +- string_replace(_rust_revision_lines[0], "RUST_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_rust_revision_lines[1], "RUST_SUB_REVISION = ", "") +- _expected_rust_revision = "$_py_revision-$_py_subrevision" +- +- # Ensure the rust version matches the clang version. +- assert( +- filter_include([ rustc_revision ], +- [ "*-$_expected_rust_revision-*" ]) != [], +- "rustc_revision=\"$rustc_revision\" but update_rust.py expected \"$_expected_rust_revision\". Run \"gclient sync\"?") +- } +- +- # This is here so that all files get recompiled after a clang roll and +- # when turning clang on or off. (defines are passed via the command line, +- # and build system rebuild things when their commandline changes). Nothing +- # should ever read this define. +- defines = [ "CR_CLANG_REVISION=\"$_clang_revision\"" ] +- } +-} +- +-# Controls the usage of a warning suppression mapping (WSM) file to suppress +-# warnings based on the path of the file they come from. It's controlled by the +-# `clang_warning_suppression_file` gn argument , which points to a text file +-# defining which warnings should be suppressed where. +-# See //build/config/warning_suppression.txt for an example file; this is the +-# file used by Chromium. +-# +-# To use a different file, or to use this functionality outside of chromium, +-# set the `clang_warning_suppression_file` argument to point to the new file, +-# e.g. by setting in the the project's .gn file. +-config("clang_warning_suppression") { +- # Some build configs use older versions of clang that don't support WSMs +- if (use_clang_warning_suppression_file) { +- from_build_root = +- rebase_path(clang_warning_suppression_file, root_build_dir) +- inputs = [ clang_warning_suppression_file ] +- cflags = [ "--warning-suppression-mappings=" + from_build_root ] +- } +-} +- + # Enable bounds checks when indexing directly (i.e. not via a pointer) + # into C arrays. This aligns with libc++ hardening for + # `std::array::operator[]`. +@@ -1836,18 +1613,6 @@ config("sanitize_c_array_bounds") { + } + } + +-config("rustc_revision") { +- if (rustc_revision != "") { +- # Similar to the above config, this is here so that all files get recompiled +- # after a rustc roll. Nothing should ever read this cfg. This will not be +- # set if a custom toolchain is used. +- rustflags = [ +- "--cfg", +- "cr_rustc_revision=\"$rustc_revision\"", +- ] +- } +-} +- + config("compiler_arm_fpu") { + if (current_cpu == "arm" && !is_ios) { + cflags = [ "-mfpu=$arm_fpu" ] +@@ -2290,11 +2055,7 @@ config("chromium_code") { + defines = [ "_HAS_NODISCARD" ] + } + } else { +- cflags = [ "-Wall" ] +- if (is_clang) { +- # Enable extra warnings for chromium_code when we control the compiler. +- cflags += [ "-Wextra" ] +- } ++ cflags = [ ] + + # In Chromium code, we define __STDC_foo_MACROS in order to get the + # C99 macros on Mac and Linux. +@@ -2303,24 +2064,6 @@ config("chromium_code") { + "__STDC_FORMAT_MACROS", + ] + +- if (!is_debug && !using_sanitizer && current_cpu != "s390x" && +- current_cpu != "s390" && current_cpu != "ppc64" && +- current_cpu != "mips" && current_cpu != "mips64" && +- current_cpu != "riscv64" && current_cpu != "loong64") { +- # Non-chromium code is not guaranteed to compile cleanly with +- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are +- # disabled, so only do that for Release build. +- fortify_level = "2" +- +- # ChromeOS's toolchain supports a high-quality _FORTIFY_SOURCE=3 +- # implementation with a few custom glibc patches. Use that if it's +- # available. +- if (is_chromeos_device && !lacros_use_chromium_toolchain) { +- fortify_level = "3" +- } +- defines += [ "_FORTIFY_SOURCE=" + fortify_level ] +- } +- + if (is_apple) { + cflags_objc = [ "-Wimplicit-retain-self" ] + cflags_objcc = [ "-Wimplicit-retain-self" ] +@@ -2736,7 +2479,8 @@ config("default_stack_frames") { + # [0]: https://pinpoint-dot-chromeperf.appspot.com/job/147634a8be0000 + # [1]: https://pinpoint-dot-chromeperf.appspot.com/job/132bc772be0000 + # [2]: https://crrev.com/c/5447532 +-config("optimize") { ++config("optimize") { } ++config("xoptimize") { + if (is_win) { + # clang-cl's /O2 corresponds to clang's -O3, and really want -O2 for + # consistency with the other platforms. +@@ -2785,7 +2529,8 @@ config("optimize") { + } + + # Turn off optimizations. +-config("no_optimize") { ++config("no_optimize") { } ++config("xno_optimize") { + if (is_win) { + cflags = [ + "/Od", # Disable optimization. +@@ -2820,7 +2565,8 @@ config("no_optimize") { + # Turns up the optimization level. Used to explicitly enable -O2 instead of + # -Os for select targets on platforms that use optimize_for_size. No-op + # elsewhere. +-config("optimize_max") { ++config("optimize_max") { } ++config("xoptimize_max") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2841,7 +2587,8 @@ config("optimize_max") { + # + # TODO(crbug.com/41259697) - rework how all of these configs are related + # so that we don't need this disclaimer. +-config("optimize_speed") { ++config("optimize_speed") { } ++config("xoptimize_speed") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2858,7 +2605,8 @@ config("optimize_speed") { + rustflags = [ "-Copt-level=3" ] + } + +-config("optimize_fuzzing") { ++config("optimize_fuzzing") { } ++config("xoptimize_fuzzing") { + cflags = [ "-O1" ] + common_optimize_on_cflags + rustflags = [ "-Copt-level=1" ] + ldflags = common_optimize_on_ldflags +@@ -2985,7 +2733,8 @@ config("win_pdbaltpath") { + } + + # Full symbols. +-config("symbols") { ++config("symbols") { } ++config("xsymbols") { + rustflags = [] + configs = [] + if (is_win) { +@@ -3141,7 +2890,8 @@ config("symbols") { + # Minimal symbols. + # This config guarantees to hold symbol for stack trace which are shown to user + # when crash happens in unittests running on buildbot. +-config("minimal_symbols") { ++config("minimal_symbols") { } ++config("xminimal_symbols") { + rustflags = [] + if (is_win) { + # Functions, files, and line tables only. +@@ -3217,7 +2967,8 @@ config("minimal_symbols") { + # This configuration contains function names only. That is, the compiler is + # told to not generate debug information and the linker then just puts function + # names in the final debug information. +-config("no_symbols") { ++config("no_symbols") { } ++config("xno_symbols") { + if (is_win) { + ldflags = [ "/DEBUG" ] + +diff --git a/build/config/gcc/BUILD.gn b/build/config/gcc/BUILD.gn +index a659210..bde0e1b 100644 +--- a/build/config/gcc/BUILD.gn ++++ b/build/config/gcc/BUILD.gn +@@ -32,7 +32,7 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ # rustflags = [ "-Zdefault-visibility=hidden" ] + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { +diff --git a/build/config/rust.gni b/build/config/rust.gni +index 7b09b0d..e4abdce 100644 +--- a/build/config/rust.gni ++++ b/build/config/rust.gni +@@ -73,7 +73,8 @@ declare_args() { + # + # TODO(crbug.com/40281834): Re-enable ThinLTO for Rust on LaCrOS + # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome +- toolchain_supports_rust_thin_lto = !is_chromeos ++ # toolchain_supports_rust_thin_lto = !is_chromeos ++ toolchain_supports_rust_thin_lto = false + + # Any extra std rlibs in your Rust toolchain, relative to the standard + # Rust toolchain. Typically used with 'rust_sysroot_absolute' diff --git a/www-client/chromium/files/chromium-140-compiler.patch b/www-client/chromium/files/chromium-140-compiler.patch new file mode 100644 index 0000000..d2a500d --- /dev/null +++ b/www-client/chromium/files/chromium-140-compiler.patch @@ -0,0 +1,454 @@ +diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn +index 29c284ee01..4985cec79a 100644 +--- a/build/config/compiler/BUILD.gn ++++ b/build/config/compiler/BUILD.gn +@@ -245,16 +245,6 @@ declare_args() { + assert(!(llvm_force_head_revision && use_remoteexec && host_os != "linux"), + "rbe with locally built clang only works on linux") + +-# Whether or not we should pass the warning_suppression.txt file to clang +-# compilations. This file allows us to suppress warnings that originate from +-# specific file paths, typically third_party headers. +-# +-# Since this is referenced both when passing the file and when deciding which +-# warnings to enable, store it in a separate variable here. +-use_clang_warning_suppression_file = +- default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline && is_clang && clang_warning_suppression_file != "" +- + # default_include_dirs --------------------------------------------------------- + # + # This is a separate config so that third_party code (which would not use the +@@ -322,12 +312,8 @@ config("compiler") { + + configs += [ + # See the definitions below. +- ":clang_revision", +- ":rustc_revision", +- ":compiler_cpu_abi", + ":compiler_codegen", + ":compiler_deterministic", +- ":clang_warning_suppression", + ] + + # TODO(https://crbug.com/404297941): Disable clang_warning_suppression +@@ -514,6 +500,9 @@ config("compiler") { + ldflags += [ "-fPIC" ] + rustflags += [ "-Crelocation-model=pic" ] + ++ extra_rustflags = getenv("RUSTFLAGS") ++ rustflags += [ extra_rustflags ] ++ + if (!is_clang) { + # Use pipes for communicating between sub-processes. Faster. + # (This flag doesn't do anything with Clang.) +@@ -605,63 +594,6 @@ config("compiler") { + ldflags += [ "-Wl,-z,keep-text-section-prefix" ] + } + +- if (is_clang) { +- cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] +- if (save_reproducers_on_lld_crash && use_lld) { +- ldflags += [ +- "-fcrash-diagnostics=all", +- "-fcrash-diagnostics-dir=" + clang_diagnostic_dir, +- ] +- } +- +- # TODO(hans): Remove this once Clang generates better optimized debug info +- # by default. https://crbug.com/765793 +- cflags += [ +- "-mllvm", +- "-instcombine-lower-dbg-declare=0", +- ] +- if (!is_debug && use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-instcombine-lower-dbg-declare=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-instcombine-lower-dbg-declare=0" ] +- } +- } +- +- # TODO(crbug.com/40283598): This causes binary size growth and potentially +- # other problems. +- # TODO(crbug.com/40284925): This isn't supported by Cronet's mainline llvm version. +- if (default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline) { +- cflags += [ +- "-mllvm", +- "-split-threshold-for-reg-with-hint=0", +- ] +- if (use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ] +- } +- } +- } +- +- # TODO(crbug.com/40192287): Investigate why/if this should be needed. +- if (is_win) { +- cflags += [ "/clang:-ffp-contract=off" ] +- } else { +- cflags += [ "-ffp-contract=off" ] +- } +- +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF +- # (excluding toolchains that use an older version of LLVM). +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. +- if (is_linux && use_lld && !llvm_android_mainline && current_cpu != "arm" && +- default_toolchain != "//build/toolchain/cros:target") { +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] +- } +- } +- + # C11/C++11 compiler flags setup. + # --------------------------- + if (is_linux || is_chromeos || is_android || current_os == "aix") { +@@ -1074,20 +1006,6 @@ config("compiler") { + # `-nodefaultlibs` from the linker invocation from Rust, which would be used + # to compile dylibs on Android, such as for constructing unit test APKs. + "-Cdefault-linker-libraries", +- +- # To make Rust .d files compatible with ninja +- "-Zdep-info-omit-d-target", +- +- # If a macro panics during compilation, show which macro and where it is +- # defined. +- "-Zmacro-backtrace", +- +- # For deterministic builds, keep the local machine's current working +- # directory from appearing in build outputs. +- "-Zremap-cwd-prefix=.", +- +- # We use clang-rt sanitizer runtimes. +- "-Zexternal-clangrt", + ] + + if (!is_win || force_rustc_color_output) { +@@ -1142,7 +1060,7 @@ config("compiler") { + # Don't allow unstable features to be enabled by `#![feature()]` without + # additional command line flags. + config("disallow_unstable_features") { +- rustflags = [ "-Zallow-features=" ] ++ #rustflags = [ "-Zallow-features=" ] + } + + config("libcxx_hardening") { +@@ -1612,43 +1530,6 @@ config("compiler_deterministic") { + } + } + +- # Makes builds independent of absolute file path. +- if (is_clang && strip_absolute_paths_from_debug_symbols) { +- # If debug option is given, clang includes $cwd in debug info by default. +- # For such build, this flag generates reproducible obj files even we use +- # different build directory like "out/feature_a" and "out/feature_b" if +- # we build same files with same compile flag. +- # Other paths are already given in relative, no need to normalize them. +- +- # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= +- # and -fcoverage-compilation-dir=. +- cflags += [ "-ffile-compilation-dir=." ] +- +- # Convert absolute paths to relative paths. Expands to, for example: +- # -file-prefix-map /path/to/chromium/src=../.. +- swiftflags += [ +- "-file-prefix-map", +- rebase_path("//.", "") + "=" + rebase_path("//.", root_build_dir), +- ] +- if (!is_win) { +- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) +- asmflags = [ "-Wa,-fdebug-compilation-dir,." ] +- } +- +- if (is_win && use_lld) { +- if (symbol_level == 2 || (is_clang && using_sanitizer)) { +- # Absolutize source file paths for PDB. Pass the real build directory +- # if the pdb contains source-level debug information and if linker +- # reproducibility is not critical. +- ldflags += [ "/PDBSourcePath:" + rebase_path(root_build_dir) ] +- } else { +- # Use a fake fixed base directory for paths in the pdb to make the pdb +- # output fully deterministic and independent of the build directory. +- ldflags += [ "/PDBSourcePath:o:\fake\prefix" ] +- } +- } +- } +- + # Tells the compiler not to use absolute paths when passing the default + # paths to the tools it invokes. We don't want this because we don't + # really need it and it can mess up the RBE cache entries. +@@ -1675,107 +1556,6 @@ config("compiler_deterministic") { + } + } + +-config("clang_revision") { +- if (is_clang && clang_base_path == default_clang_base_path && +- current_os != "zos") { +- _perform_consistency_checks = current_toolchain == default_toolchain +- if (llvm_force_head_revision) { +- _head_revision_stamp_path = "//third_party/llvm-build/force_head_revision" +- _head_revision = "" +- if (path_exists(_head_revision_stamp_path)) { +- _head_revision = read_file(_head_revision_stamp_path, "trim string") +- } +- assert( +- _head_revision != "", +- "llvm_force_head_revision=true, but no locally built version was detected.") +- _clang_revision = _head_revision +- } else { +- _clang_revision = read_file( +- "//third_party/llvm-build/Release+Asserts/cr_build_revision", +- "trim string") +- +- # Ensure that the synced clang version matches what's in git. +- if (_perform_consistency_checks) { +- # Parse the clang version from the Python script. +- _clang_version_lines = filter_include( +- read_file("//tools/clang/scripts/update.py", "list lines"), +- [ "CLANG_*REVISION = *" ]) +- _py_revision = +- string_replace(_clang_version_lines[0], "CLANG_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_clang_version_lines[1], "CLANG_SUB_REVISION = ", "") +- _expected_clang_revision = "$_py_revision-$_py_subrevision" +- +- # TODO(agrieve): Change filter_include to _clang_revision == +- # _expected_clang_revision once angle & webrtc use a GCS DEPS entry +- # rather than a update.py runhook. +- assert( +- filter_include([ _clang_revision ], +- [ +- _expected_clang_revision, +- "$_expected_clang_revision,*", +- ]) != [], +- "clang_revision=\"$_clang_revision\" but update.py expected \"$_expected_clang_revision\". Did you forget to gclient sync?") +- } +- } +- +- if (_perform_consistency_checks) { +- # Ensure that the revision matches the version major expected by GN. +- _versions_match = filter_include([ _clang_revision ], +- [ "llvmorg-$clang_version-*" ]) != [] +- assert( +- _versions_match, +- "clang_revision=\"$_clang_revision\" but clang_version=\"$clang_version\". clang_version in build/toolchain/toolchain.gni is likely outdated.") +- } +- +- if (toolchain_has_rust && _perform_consistency_checks) { +- # Ensure that the synced rust version matches what's in git. +- _rust_revision_lines = +- filter_include(read_file("//tools/rust/update_rust.py", "list lines"), +- [ "RUST_*REVISION = *" ]) +- _py_revision = +- string_replace(_rust_revision_lines[0], "RUST_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_rust_revision_lines[1], "RUST_SUB_REVISION = ", "") +- _expected_rust_revision = "$_py_revision-$_py_subrevision" +- +- # Ensure the rust version matches the clang version. +- assert( +- filter_include([ rustc_revision ], +- [ "*-$_expected_rust_revision-*" ]) != [], +- "rustc_revision=\"$rustc_revision\" but update_rust.py expected \"$_expected_rust_revision\". Run \"gclient sync\"?") +- } +- +- # This is here so that all files get recompiled after a clang roll and +- # when turning clang on or off. (defines are passed via the command line, +- # and build system rebuild things when their commandline changes). Nothing +- # should ever read this define. +- defines = [ "CR_CLANG_REVISION=\"$_clang_revision\"" ] +- } +-} +- +-# Controls the usage of a warning suppression mapping (WSM) file to suppress +-# warnings based on the path of the file they come from. It's controlled by the +-# `clang_warning_suppression_file` gn argument , which points to a text file +-# defining which warnings should be suppressed where. +-# See //build/config/warning_suppression.txt for an example file; this is the +-# file used by Chromium. +-# +-# To use a different file, or to use this functionality outside of chromium, +-# set the `clang_warning_suppression_file` argument to point to the new file, +-# e.g. by setting in the the project's .gn file. +-config("clang_warning_suppression") { +- # Some build configs use older versions of clang that don't support WSMs +- if (use_clang_warning_suppression_file) { +- from_build_root = +- rebase_path(clang_warning_suppression_file, root_build_dir) +- inputs = [ clang_warning_suppression_file ] +- cflags = [ "--warning-suppression-mappings=" + from_build_root ] +- } +-} +- + # Enable bounds checks when indexing directly (i.e. not via a pointer) + # into C arrays. This aligns with libc++ hardening for + # `std::array::operator[]`. +@@ -1799,18 +1579,6 @@ config("sanitize_c_array_bounds") { + } + } + +-config("rustc_revision") { +- if (rustc_revision != "") { +- # Similar to the above config, this is here so that all files get recompiled +- # after a rustc roll. Nothing should ever read this cfg. This will not be +- # set if a custom toolchain is used. +- rustflags = [ +- "--cfg", +- "cr_rustc_revision=\"$rustc_revision\"", +- ] +- } +-} +- + config("compiler_arm_fpu") { + if (current_cpu == "arm" && !is_ios) { + cflags = [ "-mfpu=$arm_fpu" ] +@@ -2254,11 +2022,7 @@ config("chromium_code") { + defines = [ "_HAS_NODISCARD" ] + } + } else { +- cflags = [ "-Wall" ] +- if (is_clang) { +- # Enable extra warnings for chromium_code when we control the compiler. +- cflags += [ "-Wextra" ] +- } ++ cflags = [ ] + + # In Chromium code, we define __STDC_foo_MACROS in order to get the + # C99 macros on Mac and Linux. +@@ -2267,24 +2031,6 @@ config("chromium_code") { + "__STDC_FORMAT_MACROS", + ] + +- if (!is_debug && !using_sanitizer && current_cpu != "s390x" && +- current_cpu != "s390" && current_cpu != "ppc64" && +- current_cpu != "mips" && current_cpu != "mips64" && +- current_cpu != "riscv64" && current_cpu != "loong64") { +- # Non-chromium code is not guaranteed to compile cleanly with +- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are +- # disabled, so only do that for Release build. +- fortify_level = "2" +- +- # ChromeOS's toolchain supports a high-quality _FORTIFY_SOURCE=3 +- # implementation with a few custom glibc patches. Use that if it's +- # available. +- if (is_chromeos_device && !lacros_use_chromium_toolchain) { +- fortify_level = "3" +- } +- defines += [ "_FORTIFY_SOURCE=" + fortify_level ] +- } +- + if (is_apple) { + cflags_objc = [ "-Wimplicit-retain-self" ] + cflags_objcc = [ "-Wimplicit-retain-self" ] +@@ -2713,7 +2459,8 @@ config("default_stack_frames") { + # [0]: https://pinpoint-dot-chromeperf.appspot.com/job/147634a8be0000 + # [1]: https://pinpoint-dot-chromeperf.appspot.com/job/132bc772be0000 + # [2]: https://crrev.com/c/5447532 +-config("optimize") { ++config("optimize") { } ++config("xoptimize") { + if (is_win) { + # clang-cl's /O2 corresponds to clang's -O3, and really want -O2 for + # consistency with the other platforms. +@@ -2762,7 +2509,8 @@ config("optimize") { + } + + # Turn off optimizations. +-config("no_optimize") { ++config("no_optimize") { } ++config("xno_optimize") { + if (is_win) { + cflags = [ + "/Od", # Disable optimization. +@@ -2797,7 +2545,8 @@ config("no_optimize") { + # Turns up the optimization level. Used to explicitly enable -O2 instead of + # -Os for select targets on platforms that use optimize_for_size. No-op + # elsewhere. +-config("optimize_max") { ++config("optimize_max") { } ++config("xoptimize_max") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2818,7 +2567,8 @@ config("optimize_max") { + # + # TODO(crbug.com/41259697) - rework how all of these configs are related + # so that we don't need this disclaimer. +-config("optimize_speed") { ++config("optimize_speed") { } ++config("xoptimize_speed") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2835,7 +2585,8 @@ config("optimize_speed") { + rustflags = [ "-Copt-level=3" ] + } + +-config("optimize_fuzzing") { ++config("optimize_fuzzing") { } ++config("xoptimize_fuzzing") { + cflags = [ "-O1" ] + common_optimize_on_cflags + rustflags = [ "-Copt-level=1" ] + ldflags = common_optimize_on_ldflags +@@ -2962,7 +2713,8 @@ config("win_pdbaltpath") { + } + + # Full symbols. +-config("symbols") { ++config("symbols") { } ++config("xsymbols") { + rustflags = [] + configs = [] + if (is_win) { +@@ -3118,7 +2870,8 @@ config("symbols") { + # Minimal symbols. + # This config guarantees to hold symbol for stack trace which are shown to user + # when crash happens in unittests running on buildbot. +-config("minimal_symbols") { ++config("minimal_symbols") { } ++config("xminimal_symbols") { + rustflags = [] + if (is_win) { + # Functions, files, and line tables only. +@@ -3194,7 +2947,8 @@ config("minimal_symbols") { + # This configuration contains function names only. That is, the compiler is + # told to not generate debug information and the linker then just puts function + # names in the final debug information. +-config("no_symbols") { ++config("no_symbols") { } ++config("xno_symbols") { + if (is_win) { + ldflags = [ "/DEBUG" ] + +diff --git a/build/config/gcc/BUILD.gn b/build/config/gcc/BUILD.gn +index a659210b19..bde0e1b273 100644 +--- a/build/config/gcc/BUILD.gn ++++ b/build/config/gcc/BUILD.gn +@@ -32,7 +32,7 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ # rustflags = [ "-Zdefault-visibility=hidden" ] + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { +diff --git a/build/config/rust.gni b/build/config/rust.gni +index 7b09b0d80f..e4abdce8bf 100644 +--- a/build/config/rust.gni ++++ b/build/config/rust.gni +@@ -73,7 +73,8 @@ declare_args() { + # + # TODO(crbug.com/40281834): Re-enable ThinLTO for Rust on LaCrOS + # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome +- toolchain_supports_rust_thin_lto = !is_chromeos ++ # toolchain_supports_rust_thin_lto = !is_chromeos ++ toolchain_supports_rust_thin_lto = false + + # Any extra std rlibs in your Rust toolchain, relative to the standard + # Rust toolchain. Typically used with 'rust_sysroot_absolute' diff --git a/www-client/chromium/files/chromium-140-gni-lf.patch b/www-client/chromium/files/chromium-140-gni-lf.patch new file mode 100644 index 0000000..7c08986 --- /dev/null +++ b/www-client/chromium/files/chromium-140-gni-lf.patch @@ -0,0 +1,36 @@ +diff --git a/build/config/android/config.gni b/build/config/android/config.gni +index 41aa76cfef..c22e55c0d6 100644 +--- a/build/config/android/config.gni ++++ b/build/config/android/config.gni +@@ -51,15 +51,7 @@ if (is_android) { + assert(checkout_android, + "Missing native Android toolchain support. |target_os| in your " + + ".gclient configuration file (in the parent directory of " + +- "src) must include \"android\". For example: +- +-solutions = [ +-... +-] +-target_os=[\"android\"] +- +-After adding |target_os| please re-run \"gclient sync\". +-") ++ "src) must include \"android\". For example: *snip") + } + } + +diff --git a/testing/test.gni b/testing/test.gni +index 9883ddad1d..fd2fa6ed5e 100644 +--- a/testing/test.gni ++++ b/testing/test.gni +@@ -300,9 +300,7 @@ template("mixed_test") { + + fuzzer_args_joined = string_join(" ", _fuzzer_args) + +- contents = "const char* kFuzzerArgs = \"${fuzzer_args_joined}\"; +-const char* kFuzzerBinary = \"${_fuzzer_binary_name}\"; +-" ++ contents = "const char* kFuzzerArgs = \"${fuzzer_args_joined}\";const char* kFuzzerBinary = \"${_fuzzer_binary_name}\";" + } + + _additional_fuzz_deps = [] diff --git a/www-client/chromium/files/chromium-140-rust-1.8x.patch b/www-client/chromium/files/chromium-140-rust-1.8x.patch new file mode 100644 index 0000000..84a7ed8 --- /dev/null +++ b/www-client/chromium/files/chromium-140-rust-1.8x.patch @@ -0,0 +1,17 @@ +diff --git a/build/rust/allocator/lib.rs b/build/rust/allocator/lib.rs +index 29b3af1274..142c6e6084 100644 +--- a/build/rust/allocator/lib.rs ++++ b/build/rust/allocator/lib.rs +@@ -90,6 +90,12 @@ mod both_allocators { + #[linkage = "weak"] + fn __rust_no_alloc_shim_is_unstable_v2() {} + ++ // TODO(crbug.com/422538133) Remove after rolling past ++ // https://github.com/rust-lang/rust/pull/141061 ++ #[no_mangle] ++ #[linkage = "weak"] ++ static __rust_no_alloc_shim_is_unstable: u8 = 0; ++ + // Mangle the symbol name as rustc expects. + #[rustc_std_internal_symbol] + #[allow(non_upper_case_globals)] diff --git a/www-client/chromium/files/chromium-141-compiler.patch b/www-client/chromium/files/chromium-141-compiler.patch new file mode 100644 index 0000000..36f6f34 --- /dev/null +++ b/www-client/chromium/files/chromium-141-compiler.patch @@ -0,0 +1,473 @@ +diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn +index 298e37f832..c892801357 100644 +--- a/build/config/compiler/BUILD.gn ++++ b/build/config/compiler/BUILD.gn +@@ -265,15 +265,6 @@ declare_args() { + assert(!(llvm_force_head_revision && use_remoteexec && host_os != "linux"), + "rbe with locally built clang only works on linux") + +-# Whether or not we should pass the warning_suppression.txt file to clang +-# compilations. This file allows us to suppress warnings that originate from +-# specific file paths, typically third_party headers. +-# +-# Since this is referenced both when passing the file and when deciding which +-# warnings to enable, store it in a separate variable here. +-use_clang_warning_suppression_file = +- !llvm_android_mainline && is_clang && clang_warning_suppression_file != "" +- + # default_include_dirs --------------------------------------------------------- + # + # This is a separate config so that third_party code (which would not use the +@@ -341,12 +332,8 @@ config("compiler") { + + configs += [ + # See the definitions below. +- ":clang_revision", +- ":rustc_revision", +- ":compiler_cpu_abi", + ":compiler_codegen", + ":compiler_deterministic", +- ":clang_warning_suppression", + ] + + # TODO(https://crbug.com/404297941): Disable clang_warning_suppression +@@ -547,6 +534,9 @@ config("compiler") { + ldflags += [ "-fPIC" ] + rustflags += [ "-Crelocation-model=pic" ] + ++ extra_rustflags = getenv("RUSTFLAGS") ++ rustflags += [ extra_rustflags ] ++ + if (!is_clang) { + # Use pipes for communicating between sub-processes. Faster. + # (This flag doesn't do anything with Clang.) +@@ -638,64 +628,6 @@ config("compiler") { + ldflags += [ "-Wl,-z,keep-text-section-prefix" ] + } + +- if (is_clang) { +- cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] +- if (save_reproducers_on_lld_crash && use_lld) { +- ldflags += [ +- "-fcrash-diagnostics=all", +- "-fcrash-diagnostics-dir=" + clang_diagnostic_dir, +- ] +- } +- +- # TODO(hans): Remove this once Clang generates better optimized debug info +- # by default. https://crbug.com/765793 +- cflags += [ +- "-mllvm", +- "-instcombine-lower-dbg-declare=0", +- ] +- if (!is_debug && use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-instcombine-lower-dbg-declare=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-instcombine-lower-dbg-declare=0" ] +- } +- } +- +- # TODO(crbug.com/40283598): This causes binary size growth and potentially +- # other problems. +- # TODO(crbug.com/40284925): This isn't supported by Cronet's mainline llvm version. +- if (default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline) { +- cflags += [ +- "-mllvm", +- "-split-threshold-for-reg-with-hint=0", +- ] +- if (use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ] +- } +- } +- } +- +- # TODO(crbug.com/40192287): Investigate why/if this should be needed. +- if (is_win) { +- cflags += [ "/clang:-ffp-contract=off" ] +- } else { +- cflags += [ "-ffp-contract=off" ] +- } +- +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF. +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. +- # It also causes segfault on Linux s390x: +- # https://github.com/llvm/llvm-project/issues/149511 +- if (is_linux && use_lld && !llvm_android_mainline && current_cpu != "arm" && +- current_cpu != "s390x") { +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] +- } +- } +- + # C11/C++11 compiler flags setup. + # --------------------------- + if (is_linux || is_chromeos || is_android || current_os == "aix") { +@@ -1108,20 +1040,6 @@ config("compiler") { + # `-nodefaultlibs` from the linker invocation from Rust, which would be used + # to compile dylibs on Android, such as for constructing unit test APKs. + "-Cdefault-linker-libraries", +- +- # To make Rust .d files compatible with ninja +- "-Zdep-info-omit-d-target", +- +- # If a macro panics during compilation, show which macro and where it is +- # defined. +- "-Zmacro-backtrace", +- +- # For deterministic builds, keep the local machine's current working +- # directory from appearing in build outputs. +- "-Zremap-cwd-prefix=.", +- +- # We use clang-rt sanitizer runtimes. +- "-Zexternal-clangrt", + ] + + if (!is_win || force_rustc_color_output) { +@@ -1176,7 +1094,7 @@ config("compiler") { + # Don't allow unstable features to be enabled by `#![feature()]` without + # additional command line flags. + config("disallow_unstable_features") { +- rustflags = [ "-Zallow-features=" ] ++ #rustflags = [ "-Zallow-features=" ] + } + + config("libcxx_hardening") { +@@ -1646,43 +1564,6 @@ config("compiler_deterministic") { + } + } + +- # Makes builds independent of absolute file path. +- if (is_clang && strip_absolute_paths_from_debug_symbols) { +- # If debug option is given, clang includes $cwd in debug info by default. +- # For such build, this flag generates reproducible obj files even we use +- # different build directory like "out/feature_a" and "out/feature_b" if +- # we build same files with same compile flag. +- # Other paths are already given in relative, no need to normalize them. +- +- # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= +- # and -fcoverage-compilation-dir=. +- cflags += [ "-ffile-compilation-dir=." ] +- +- # Convert absolute paths to relative paths. Expands to, for example: +- # -file-prefix-map /path/to/chromium/src=../.. +- swiftflags += [ +- "-file-prefix-map", +- rebase_path("//.", "") + "=" + rebase_path("//.", root_build_dir), +- ] +- if (!is_win) { +- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) +- asmflags = [ "-Wa,-fdebug-compilation-dir,." ] +- } +- +- if (is_win && use_lld) { +- if (symbol_level == 2 || (is_clang && using_sanitizer)) { +- # Absolutize source file paths for PDB. Pass the real build directory +- # if the pdb contains source-level debug information and if linker +- # reproducibility is not critical. +- ldflags += [ "/PDBSourcePath:" + rebase_path(root_build_dir) ] +- } else { +- # Use a fake fixed base directory for paths in the pdb to make the pdb +- # output fully deterministic and independent of the build directory. +- ldflags += [ "/PDBSourcePath:o:\fake\prefix" ] +- } +- } +- } +- + # Tells the compiler not to use absolute paths when passing the default + # paths to the tools it invokes. We don't want this because we don't + # really need it and it can mess up the RBE cache entries. +@@ -1699,114 +1580,8 @@ config("compiler_deterministic") { + ldflags += [ "-no-canonical-prefixes" ] + } + } +- +- if (use_clang_modules) { +- cflags += [ +- # This removes absolute paths from .pcm files. +- "-Xclang", +- "-fmodule-file-home-is-cwd", +- ] +- } +-} +- +-config("clang_revision") { +- if (is_clang && clang_base_path == default_clang_base_path && +- current_os != "zos") { +- _perform_consistency_checks = current_toolchain == default_toolchain +- if (llvm_force_head_revision) { +- _head_revision_stamp_path = "//third_party/llvm-build/force_head_revision" +- _head_revision = "" +- if (path_exists(_head_revision_stamp_path)) { +- _head_revision = read_file(_head_revision_stamp_path, "trim string") +- } +- assert( +- _head_revision != "", +- "llvm_force_head_revision=true, but no locally built version was detected.") +- _clang_revision = _head_revision +- } else { +- _clang_revision = read_file( +- "//third_party/llvm-build/Release+Asserts/cr_build_revision", +- "trim string") +- +- # Ensure that the synced clang version matches what's in git. +- if (_perform_consistency_checks) { +- # Parse the clang version from the Python script. +- _clang_version_lines = filter_include( +- read_file("//tools/clang/scripts/update.py", "list lines"), +- [ "CLANG_*REVISION = *" ]) +- _py_revision = +- string_replace(_clang_version_lines[0], "CLANG_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_clang_version_lines[1], "CLANG_SUB_REVISION = ", "") +- _expected_clang_revision = "$_py_revision-$_py_subrevision" +- +- # TODO(agrieve): Change filter_include to _clang_revision == +- # _expected_clang_revision once angle & webrtc use a GCS DEPS entry +- # rather than a update.py runhook. +- assert( +- filter_include([ _clang_revision ], +- [ +- _expected_clang_revision, +- "$_expected_clang_revision,*", +- ]) != [], +- "clang_revision=\"$_clang_revision\" but update.py expected \"$_expected_clang_revision\". Did you forget to gclient sync?") +- } +- } +- +- if (_perform_consistency_checks) { +- # Ensure that the revision matches the version major expected by GN. +- _versions_match = filter_include([ _clang_revision ], +- [ "llvmorg-$clang_version-*" ]) != [] +- assert( +- _versions_match, +- "clang_revision=\"$_clang_revision\" but clang_version=\"$clang_version\". clang_version in build/toolchain/toolchain.gni is likely outdated.") +- } +- +- if (toolchain_has_rust && _perform_consistency_checks) { +- # Ensure that the synced rust version matches what's in git. +- _rust_revision_lines = +- filter_include(read_file("//tools/rust/update_rust.py", "list lines"), +- [ "RUST_*REVISION = *" ]) +- _py_revision = +- string_replace(_rust_revision_lines[0], "RUST_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_rust_revision_lines[1], "RUST_SUB_REVISION = ", "") +- _expected_rust_revision = "$_py_revision-$_py_subrevision" +- +- # Ensure the rust version matches the clang version. +- assert( +- filter_include([ rustc_revision ], +- [ "*-$_expected_rust_revision-*" ]) != [], +- "rustc_revision=\"$rustc_revision\" but update_rust.py expected \"$_expected_rust_revision\". Run \"gclient sync\"?") +- } +- +- # This is here so that all files get recompiled after a clang roll and +- # when turning clang on or off. (defines are passed via the command line, +- # and build system rebuild things when their commandline changes). Nothing +- # should ever read this define. +- defines = [ "CR_CLANG_REVISION=\"$_clang_revision\"" ] +- } +-} +- +-# Controls the usage of a warning suppression mapping (WSM) file to suppress +-# warnings based on the path of the file they come from. It's controlled by the +-# `clang_warning_suppression_file` gn argument , which points to a text file +-# defining which warnings should be suppressed where. +-# See //build/config/warning_suppression.txt for an example file; this is the +-# file used by Chromium. +-# +-# To use a different file, or to use this functionality outside of chromium, +-# set the `clang_warning_suppression_file` argument to point to the new file, +-# e.g. by setting in the the project's .gn file. +-config("clang_warning_suppression") { +- # Some build configs use older versions of clang that don't support WSMs +- if (use_clang_warning_suppression_file) { +- from_build_root = +- rebase_path(clang_warning_suppression_file, root_build_dir) +- inputs = [ clang_warning_suppression_file ] +- cflags = [ "--warning-suppression-mappings=" + from_build_root ] ++ if (is_clang) { ++ cflags += [ "-Xclang", "-fno-cxx-modules" ] + } + } + +@@ -1833,18 +1608,6 @@ config("sanitize_c_array_bounds") { + } + } + +-config("rustc_revision") { +- if (rustc_revision != "") { +- # Similar to the above config, this is here so that all files get recompiled +- # after a rustc roll. Nothing should ever read this cfg. This will not be +- # set if a custom toolchain is used. +- rustflags = [ +- "--cfg", +- "cr_rustc_revision=\"$rustc_revision\"", +- ] +- } +-} +- + config("compiler_arm_fpu") { + if (current_cpu == "arm" && !is_ios) { + cflags = [ "-mfpu=$arm_fpu" ] +@@ -1869,7 +1632,8 @@ config("compiler_arm") { + } + } + +-config("libcxx_module") { ++config("libcxx_module") {} ++config("libcxx_modulex") { + if (use_clang_modules) { + cflags_cc = [ + "-fmodules", +@@ -2288,11 +2052,7 @@ config("chromium_code") { + defines = [ "_HAS_NODISCARD" ] + } + } else { +- cflags = [ "-Wall" ] +- if (is_clang) { +- # Enable extra warnings for chromium_code when we control the compiler. +- cflags += [ "-Wextra" ] +- } ++ cflags = [ ] + + # In Chromium code, we define __STDC_foo_MACROS in order to get the + # C99 macros on Mac and Linux. +@@ -2301,24 +2061,6 @@ config("chromium_code") { + "__STDC_FORMAT_MACROS", + ] + +- if (!is_debug && !using_sanitizer && current_cpu != "s390x" && +- current_cpu != "s390" && current_cpu != "ppc64" && +- current_cpu != "mips" && current_cpu != "mips64" && +- current_cpu != "riscv64" && current_cpu != "loong64") { +- # Non-chromium code is not guaranteed to compile cleanly with +- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are +- # disabled, so only do that for Release build. +- fortify_level = "2" +- +- # ChromeOS's toolchain supports a high-quality _FORTIFY_SOURCE=3 +- # implementation with a few custom glibc patches. Use that if it's +- # available. +- if (is_chromeos_device) { +- fortify_level = "3" +- } +- defines += [ "_FORTIFY_SOURCE=" + fortify_level ] +- } +- + if (is_apple) { + cflags_objc = [ "-Wimplicit-retain-self" ] + cflags_objcc = [ "-Wimplicit-retain-self" ] +@@ -2734,7 +2476,8 @@ config("default_stack_frames") { + # [0]: https://pinpoint-dot-chromeperf.appspot.com/job/147634a8be0000 + # [1]: https://pinpoint-dot-chromeperf.appspot.com/job/132bc772be0000 + # [2]: https://crrev.com/c/5447532 +-config("optimize") { ++config("optimize") { } ++config("xoptimize") { + if (is_win) { + # clang-cl's /O2 corresponds to clang's -O3, and really want -O2 for + # consistency with the other platforms. +@@ -2783,7 +2526,8 @@ config("optimize") { + } + + # Turn off optimizations. +-config("no_optimize") { ++config("no_optimize") { } ++config("xno_optimize") { + if (is_win) { + cflags = [ + "/Od", # Disable optimization. +@@ -2818,7 +2562,8 @@ config("no_optimize") { + # Turns up the optimization level. Used to explicitly enable -O2 instead of + # -Os for select targets on platforms that use optimize_for_size. No-op + # elsewhere. +-config("optimize_max") { ++config("optimize_max") { } ++config("xoptimize_max") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2839,7 +2584,8 @@ config("optimize_max") { + # + # TODO(crbug.com/41259697) - rework how all of these configs are related + # so that we don't need this disclaimer. +-config("optimize_speed") { ++config("optimize_speed") { } ++config("xoptimize_speed") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2856,7 +2602,8 @@ config("optimize_speed") { + rustflags = [ "-Copt-level=3" ] + } + +-config("optimize_fuzzing") { ++config("optimize_fuzzing") { } ++config("xoptimize_fuzzing") { + cflags = [ "-O1" ] + common_optimize_on_cflags + rustflags = [ "-Copt-level=1" ] + ldflags = common_optimize_on_ldflags +@@ -2983,7 +2730,8 @@ config("win_pdbaltpath") { + } + + # Full symbols. +-config("symbols") { ++config("symbols") { } ++config("xsymbols") { + rustflags = [] + configs = [] + if (is_win) { +@@ -3139,7 +2887,8 @@ config("symbols") { + # Minimal symbols. + # This config guarantees to hold symbol for stack trace which are shown to user + # when crash happens in unittests running on buildbot. +-config("minimal_symbols") { ++config("minimal_symbols") { } ++config("xminimal_symbols") { + rustflags = [] + if (is_win) { + # Functions, files, and line tables only. +@@ -3215,7 +2964,8 @@ config("minimal_symbols") { + # This configuration contains function names only. That is, the compiler is + # told to not generate debug information and the linker then just puts function + # names in the final debug information. +-config("no_symbols") { ++config("no_symbols") { } ++config("xno_symbols") { + if (is_win) { + ldflags = [ "/DEBUG" ] + +diff --git a/build/config/gcc/BUILD.gn b/build/config/gcc/BUILD.gn +index a659210b19..bde0e1b273 100644 +--- a/build/config/gcc/BUILD.gn ++++ b/build/config/gcc/BUILD.gn +@@ -32,7 +32,7 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ # rustflags = [ "-Zdefault-visibility=hidden" ] + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { +diff --git a/build/config/rust.gni b/build/config/rust.gni +index 55bd7b78ee..be36aef69f 100644 +--- a/build/config/rust.gni ++++ b/build/config/rust.gni +@@ -73,7 +73,8 @@ declare_args() { + # + # TODO(crbug.com/40281834): Re-enable ThinLTO for Rust on LaCrOS + # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome +- toolchain_supports_rust_thin_lto = !is_chromeos ++ # toolchain_supports_rust_thin_lto = !is_chromeos ++ toolchain_supports_rust_thin_lto = false + + # Any extra std rlibs in your Rust toolchain, relative to the standard + # Rust toolchain. Typically used with 'rust_sysroot_absolute' diff --git a/www-client/chromium/files/chromium-141-mv2-ungoogled.patch b/www-client/chromium/files/chromium-141-mv2-ungoogled.patch new file mode 100644 index 0000000..2eea81c --- /dev/null +++ b/www-client/chromium/files/chromium-141-mv2-ungoogled.patch @@ -0,0 +1,158 @@ +diff --git a/chrome/browser/extensions/api/developer_private/extension_info_generator.cc b/chrome/browser/extensions/api/developer_private/extension_info_generator.cc +index 4780e2b3db..32691cb88c 100644 +--- a/chrome/browser/extensions/api/developer_private/extension_info_generator.cc ++++ b/chrome/browser/extensions/api/developer_private/extension_info_generator.cc +@@ -594,17 +594,6 @@ void ExtensionInfoGenerator::FillExtensionInfo(const Extension& extension, + info.controlled_info.emplace(); + info.controlled_info->text = + l10n_util::GetStringUTF8(IDS_EXTENSIONS_INSTALL_LOCATION_ENTERPRISE); +- } else { +- // Create Safety Hub information for any non-enterprise extension. +- developer::SafetyCheckWarningReason warning_reason = +- ExtensionSafetyCheckUtils::GetSafetyCheckWarningReason(extension, +- profile); +- if (warning_reason != developer::SafetyCheckWarningReason::kNone) { +- info.safety_check_warning_reason = warning_reason; +- info.safety_check_text = +- ExtensionSafetyCheckUtils::GetSafetyCheckWarningStrings( +- warning_reason, state); +- } + } + + bool is_enabled = state == developer::ExtensionState::kEnabled; +diff --git a/chrome/browser/extensions/extension_management.cc b/chrome/browser/extensions/extension_management.cc +index b35d69a7a9..d2bb1f364e 100644 +--- a/chrome/browser/extensions/extension_management.cc ++++ b/chrome/browser/extensions/extension_management.cc +@@ -348,31 +348,7 @@ bool ExtensionManagement::IsAllowedManifestVersion( + int manifest_version, + const std::string& extension_id, + Manifest::Type manifest_type) { +- bool enabled_by_default = +- !base::FeatureList::IsEnabled( +- extensions_features::kExtensionsManifestV3Only) || +- manifest_version >= 3; +- +- // Manifest version policy only supports normal extensions and Chrome OS login +- // screen extension. +- if (manifest_type != Manifest::Type::TYPE_EXTENSION && +- manifest_type != Manifest::Type::TYPE_LOGIN_SCREEN_EXTENSION) { +- return enabled_by_default; +- } +- switch (global_settings_->manifest_v2_setting) { +- case internal::GlobalSettings::ManifestV2Setting::kDefault: +- return enabled_by_default; +- case internal::GlobalSettings::ManifestV2Setting::kDisabled: +- return manifest_version >= 3; +- case internal::GlobalSettings::ManifestV2Setting::kEnabled: + return true; +- case internal::GlobalSettings::ManifestV2Setting::kEnabledForForceInstalled: +- auto installation_mode = +- GetInstallationMode(extension_id, /*update_url=*/std::string()); +- return manifest_version >= 3 || +- installation_mode == ManagedInstallationMode::kForced || +- installation_mode == ManagedInstallationMode::kRecommended; +- } + } + + bool ExtensionManagement::IsAllowedManifestVersion(const Extension* extension) { +@@ -393,26 +369,8 @@ bool ExtensionManagement::IsExemptFromMV2DeprecationByPolicy( + return false; + } + +- switch (global_settings_->manifest_v2_setting) { +- case internal::GlobalSettings::ManifestV2Setting::kDefault: +- // Default browser behavior. Not exempt. +- return false; +- case internal::GlobalSettings::ManifestV2Setting::kDisabled: +- // All MV2 extensions are disallowed. Not exempt. +- return false; +- case internal::GlobalSettings::ManifestV2Setting::kEnabled: + // All MV2 extensions are allowed. Exempt. + return true; +- case internal::GlobalSettings::ManifestV2Setting::kEnabledForForceInstalled: +- // Force-installed MV2 extensions are allowed. Exempt if it's a force- +- // installed extension only. +- auto installation_mode = +- GetInstallationMode(extension_id, /*update_url=*/std::string()); +- return installation_mode == ManagedInstallationMode::kForced || +- installation_mode == ManagedInstallationMode::kRecommended; +- } +- +- return false; + } + + bool ExtensionManagement::IsAllowedByUnpublishedAvailabilityPolicy( +diff --git a/chrome/browser/extensions/manifest_v2_experiment_manager.cc b/chrome/browser/extensions/manifest_v2_experiment_manager.cc +index a5cfb94f79..2d2eb52319 100644 +--- a/chrome/browser/extensions/manifest_v2_experiment_manager.cc ++++ b/chrome/browser/extensions/manifest_v2_experiment_manager.cc +@@ -145,17 +145,6 @@ bool ManifestV2ExperimentManagerFactory::ServiceIsCreatedWithBrowserContext() + + // Determines the current stage of the MV2 deprecation experiments. + MV2ExperimentStage CalculateCurrentExperimentStage() { +- // Return the "highest" stage that is currently active for the user. +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2Unsupported)) { +- return MV2ExperimentStage::kUnsupported; +- } +- +- if (base::FeatureList::IsEnabled( +- extensions_features::kExtensionManifestV2Disabled)) { +- return MV2ExperimentStage::kDisableWithReEnable; +- } +- + return MV2ExperimentStage::kWarning; + } + +@@ -189,18 +178,7 @@ PrefMap GetGlobalNoticeAcknowledgedPrefFor( + // Returns true if legacy extensions should be disabled, looking at both + // experiment stage and global state. + bool ShouldDisableLegacyExtensions(MV2ExperimentStage stage) { +- if (g_allow_mv2_for_testing) { +- // We allow legacy MV2 extensions for testing purposes. +- return false; +- } +- +- switch (stage) { +- case MV2ExperimentStage::kWarning: +- return false; +- case MV2ExperimentStage::kDisableWithReEnable: +- case MV2ExperimentStage::kUnsupported: +- return true; +- } ++ return false; + } + + // Returns true if the given `stage` is one in which extension enablement should +diff --git a/chrome/browser/ui/webui/extensions/extensions_ui.cc b/chrome/browser/ui/webui/extensions/extensions_ui.cc +index 9e73d41c3e..55c82edf96 100644 +--- a/chrome/browser/ui/webui/extensions/extensions_ui.cc ++++ b/chrome/browser/ui/webui/extensions/extensions_ui.cc +@@ -483,7 +483,7 @@ content::WebUIDataSource* CreateAndAddExtensionsSource(Profile* profile, + extensions_features::kExtensionsMenuAccessControlWithPermittedSites)); + source->AddBoolean( + "safetyHubThreeDotDetails", +- base::FeatureList::IsEnabled(features::kSafetyHubThreeDotDetails)); ++ false); + + // MV2 deprecation. + auto* mv2_experiment_manager = ManifestV2ExperimentManager::Get(profile); +diff --git a/extensions/common/extension.cc b/extensions/common/extension.cc +index 97752e1447..9889c9dfb6 100644 +--- a/extensions/common/extension.cc ++++ b/extensions/common/extension.cc +@@ -101,13 +101,6 @@ bool IsManifestSupported(int manifest_version, + // Supported versions are always safe. + if (manifest_version >= kMinimumSupportedManifestVersion && + manifest_version <= kMaximumSupportedManifestVersion) { +- // Emit a warning for unpacked extensions on Manifest V2 warning that +- // MV2 is deprecated. +- if (type == Manifest::TYPE_EXTENSION && manifest_version == 2 && +- Manifest::IsUnpackedLocation(location) && +- !g_silence_deprecated_manifest_version_warnings) { +- *warning = errors::kManifestV2IsDeprecatedWarning; +- } + return true; + } + diff --git a/www-client/chromium/files/chromium-142-blink-observable_array-css.patch b/www-client/chromium/files/chromium-142-blink-observable_array-css.patch new file mode 100644 index 0000000..07e29cd --- /dev/null +++ b/www-client/chromium/files/chromium-142-blink-observable_array-css.patch @@ -0,0 +1,13 @@ +diff --git a/third_party/blink/renderer/platform/bindings/observable_array.h b/third_party/blink/renderer/platform/bindings/observable_array.h +index d7050727cd..6d3a0b4912 100644 +--- a/third_party/blink/renderer/platform/bindings/observable_array.h ++++ b/third_party/blink/renderer/platform/bindings/observable_array.h +@@ -10,6 +10,8 @@ + #include "third_party/blink/renderer/platform/heap/member.h" + #include "v8/include/v8-forward.h" + ++#include "third_party/blink/renderer/core/css/css_style_sheet.h" ++ + // Overview of Blink implementation of Web IDL observable arrays + // + // Observable arrays are implemented with two objects: diff --git a/www-client/chromium/files/chromium-142-compiler.patch b/www-client/chromium/files/chromium-142-compiler.patch new file mode 100644 index 0000000..ba45a89 --- /dev/null +++ b/www-client/chromium/files/chromium-142-compiler.patch @@ -0,0 +1,517 @@ +diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn +index 9cf9079bc5..2e4c762503 100644 +--- a/build/config/compiler/BUILD.gn ++++ b/build/config/compiler/BUILD.gn +@@ -261,15 +261,6 @@ declare_args() { + assert(!(llvm_force_head_revision && use_remoteexec && host_os != "linux"), + "rbe with locally built clang only works on linux") + +-# Whether or not we should pass the warning_suppression.txt file to clang +-# compilations. This file allows us to suppress warnings that originate from +-# specific file paths, typically third_party headers. +-# +-# Since this is referenced both when passing the file and when deciding which +-# warnings to enable, store it in a separate variable here. +-use_clang_warning_suppression_file = +- !llvm_android_mainline && is_clang && clang_warning_suppression_file != "" +- + # default_include_dirs --------------------------------------------------------- + # + # This is a separate config so that third_party code (which would not use the +@@ -337,12 +328,8 @@ config("compiler") { + + configs += [ + # See the definitions below. +- ":clang_revision", +- ":rustc_revision", +- ":compiler_cpu_abi", + ":compiler_codegen", + ":compiler_deterministic", +- ":clang_warning_suppression", + ] + + # TODO(https://crbug.com/404297941): Disable clang_warning_suppression +@@ -543,6 +530,9 @@ config("compiler") { + ldflags += [ "-fPIC" ] + rustflags += [ "-Crelocation-model=pic" ] + ++ extra_rustflags = getenv("RUSTFLAGS") ++ rustflags += [ extra_rustflags ] ++ + if (!is_clang) { + # Use pipes for communicating between sub-processes. Faster. + # (This flag doesn't do anything with Clang.) +@@ -634,64 +624,6 @@ config("compiler") { + ldflags += [ "-Wl,-z,keep-text-section-prefix" ] + } + +- if (is_clang) { +- cflags += [ "-fcrash-diagnostics-dir=" + clang_diagnostic_dir ] +- if (save_reproducers_on_lld_crash && use_lld) { +- ldflags += [ +- "-fcrash-diagnostics=all", +- "-fcrash-diagnostics-dir=" + clang_diagnostic_dir, +- ] +- } +- +- # TODO(hans): Remove this once Clang generates better optimized debug info +- # by default. https://crbug.com/765793 +- cflags += [ +- "-mllvm", +- "-instcombine-lower-dbg-declare=0", +- ] +- if (!is_debug && use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-instcombine-lower-dbg-declare=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-instcombine-lower-dbg-declare=0" ] +- } +- } +- +- # TODO(crbug.com/40283598): This causes binary size growth and potentially +- # other problems. +- # TODO(crbug.com/40284925): This isn't supported by Cronet's mainline llvm version. +- if (default_toolchain != "//build/toolchain/cros:target" && +- !llvm_android_mainline) { +- cflags += [ +- "-mllvm", +- "-split-threshold-for-reg-with-hint=0", +- ] +- if (use_thin_lto && is_a_target_toolchain) { +- if (is_win) { +- ldflags += [ "-mllvm:-split-threshold-for-reg-with-hint=0" ] +- } else { +- ldflags += [ "-Wl,-mllvm,-split-threshold-for-reg-with-hint=0" ] +- } +- } +- } +- +- # TODO(crbug.com/40192287): Investigate why/if this should be needed. +- if (is_win) { +- cflags += [ "/clang:-ffp-contract=off" ] +- } else { +- cflags += [ "-ffp-contract=off" ] +- } +- +- # Enable ELF CREL (see crbug.com/357878242) for all platforms that use ELF. +- # TODO(crbug.com/376278218): This causes segfault on Linux ARM builds. +- # It also causes segfault on Linux s390x: +- # https://github.com/llvm/llvm-project/issues/149511 +- if (is_linux && use_lld && !llvm_android_mainline && current_cpu != "arm" && +- current_cpu != "s390x") { +- cflags += [ "-Wa,--crel,--allow-experimental-crel" ] +- } +- } +- + # C11/C++11 compiler flags setup. + # --------------------------- + if (is_linux || is_chromeos || is_android || current_os == "aix") { +@@ -1104,20 +1036,6 @@ config("compiler") { + # `-nodefaultlibs` from the linker invocation from Rust, which would be used + # to compile dylibs on Android, such as for constructing unit test APKs. + "-Cdefault-linker-libraries", +- +- # To make Rust .d files compatible with ninja +- "-Zdep-info-omit-d-target", +- +- # If a macro panics during compilation, show which macro and where it is +- # defined. +- "-Zmacro-backtrace", +- +- # For deterministic builds, keep the local machine's current working +- # directory from appearing in build outputs. +- "-Zremap-cwd-prefix=.", +- +- # We use clang-rt sanitizer runtimes. +- "-Zexternal-clangrt", + ] + + if (!is_win || force_rustc_color_output) { +@@ -1172,7 +1090,7 @@ config("compiler") { + # Don't allow unstable features to be enabled by `#![feature()]` without + # additional command line flags. + config("disallow_unstable_features") { +- rustflags = [ "-Zallow-features=" ] ++ #rustflags = [ "-Zallow-features=" ] + } + + config("libcxx_hardening") { +@@ -1642,43 +1560,6 @@ config("compiler_deterministic") { + } + } + +- # Makes builds independent of absolute file path. +- if (is_clang && strip_absolute_paths_from_debug_symbols) { +- # If debug option is given, clang includes $cwd in debug info by default. +- # For such build, this flag generates reproducible obj files even we use +- # different build directory like "out/feature_a" and "out/feature_b" if +- # we build same files with same compile flag. +- # Other paths are already given in relative, no need to normalize them. +- +- # -ffile-compilation-dir is an alias for both -fdebug-compilation-dir= +- # and -fcoverage-compilation-dir=. +- cflags += [ "-ffile-compilation-dir=." ] +- +- # Convert absolute paths to relative paths. Expands to, for example: +- # -file-prefix-map /path/to/chromium/src=../.. +- swiftflags += [ +- "-file-prefix-map", +- rebase_path("//.", "") + "=" + rebase_path("//.", root_build_dir), +- ] +- if (!is_win) { +- # We don't use clang -cc1as on Windows (yet? https://crbug.com/762167) +- asmflags = [ "-Wa,-fdebug-compilation-dir,." ] +- } +- +- if (is_win && use_lld) { +- if (symbol_level == 2 || (is_clang && using_sanitizer)) { +- # Absolutize source file paths for PDB. Pass the real build directory +- # if the pdb contains source-level debug information and if linker +- # reproducibility is not critical. +- ldflags += [ "/PDBSourcePath:" + rebase_path(root_build_dir) ] +- } else { +- # Use a fake fixed base directory for paths in the pdb to make the pdb +- # output fully deterministic and independent of the build directory. +- ldflags += [ "/PDBSourcePath:o:\fake\prefix" ] +- } +- } +- } +- + # Tells the compiler not to use absolute paths when passing the default + # paths to the tools it invokes. We don't want this because we don't + # really need it and it can mess up the RBE cache entries. +@@ -1696,114 +1577,8 @@ config("compiler_deterministic") { + } + } + +- if (use_clang_modules) { +- cflags += [ +- # This removes absolute paths from .pcm files. +- "-Xclang", +- "-fmodule-file-home-is-cwd", +- ] +- } +-} +- +-config("clang_revision") { +- if (is_clang && clang_base_path == default_clang_base_path && +- current_os != "zos") { +- _perform_consistency_checks = current_toolchain == default_toolchain +- if (llvm_force_head_revision) { +- _head_revision_stamp_path = "//third_party/llvm-build/force_head_revision" +- _head_revision = "" +- if (path_exists(_head_revision_stamp_path)) { +- _head_revision = read_file(_head_revision_stamp_path, "trim string") +- } +- assert( +- _head_revision != "", +- "llvm_force_head_revision=true, but no locally built version was detected.") +- _clang_revision = _head_revision +- } else { +- _clang_revision = read_file( +- "//third_party/llvm-build/Release+Asserts/cr_build_revision", +- "trim string") +- +- # Ensure that the synced clang version matches what's in git. +- if (_perform_consistency_checks) { +- # Parse the clang version from the Python script. +- _clang_version_lines = filter_include( +- read_file("//tools/clang/scripts/update.py", "list lines"), +- [ "CLANG_*REVISION = *" ]) +- _py_revision = +- string_replace(_clang_version_lines[0], "CLANG_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_clang_version_lines[1], "CLANG_SUB_REVISION = ", "") +- _expected_clang_revision = "$_py_revision-$_py_subrevision" +- +- # TODO(agrieve): Change filter_include to _clang_revision == +- # _expected_clang_revision once angle & webrtc use a GCS DEPS entry +- # rather than a update.py runhook. +- assert( +- filter_include([ _clang_revision ], +- [ +- _expected_clang_revision, +- "$_expected_clang_revision,*", +- ]) != [], +- "clang_revision=\"$_clang_revision\" but update.py expected \"$_expected_clang_revision\". Did you forget to gclient sync?") +- } +- } +- +- if (_perform_consistency_checks) { +- # Ensure that the revision matches the version major expected by GN. +- _versions_match = filter_include([ _clang_revision ], +- [ "llvmorg-$clang_version-*" ]) != [] +- assert( +- _versions_match, +- "clang_revision=\"$_clang_revision\" but clang_version=\"$clang_version\". clang_version in build/toolchain/toolchain.gni is likely outdated.") +- } +- +- if (toolchain_has_rust && _perform_consistency_checks && +- !rust_force_head_revision) { +- # Ensure that the synced rust version matches what's in git. +- _rust_revision_lines = +- filter_include(read_file("//tools/rust/update_rust.py", "list lines"), +- [ "RUST_*REVISION = *" ]) +- _py_revision = +- string_replace(_rust_revision_lines[0], "RUST_REVISION = '", "") +- _py_revision = string_replace(_py_revision, "'", "") +- _py_subrevision = +- string_replace(_rust_revision_lines[1], "RUST_SUB_REVISION = ", "") +- _expected_rust_revision = "$_py_revision-$_py_subrevision" +- +- # Ensure the rust version matches the clang version. +- assert( +- filter_include([ rustc_revision ], +- [ "*-$_expected_rust_revision-*" ]) != [], +- "rustc_revision=\"$rustc_revision\" but update_rust.py expected \"$_expected_rust_revision\". Run \"gclient sync\"?") +- } +- +- # This is here so that all files get recompiled after a clang roll and +- # when turning clang on or off. (defines are passed via the command line, +- # and build system rebuild things when their commandline changes). Nothing +- # should ever read this define. +- defines = [ "CR_CLANG_REVISION=\"$_clang_revision\"" ] +- } +-} +- +-# Controls the usage of a warning suppression mapping (WSM) file to suppress +-# warnings based on the path of the file they come from. It's controlled by the +-# `clang_warning_suppression_file` gn argument , which points to a text file +-# defining which warnings should be suppressed where. +-# See //build/config/warning_suppression.txt for an example file; this is the +-# file used by Chromium. +-# +-# To use a different file, or to use this functionality outside of chromium, +-# set the `clang_warning_suppression_file` argument to point to the new file, +-# e.g. by setting in the the project's .gn file. +-config("clang_warning_suppression") { +- # Some build configs use older versions of clang that don't support WSMs +- if (use_clang_warning_suppression_file) { +- from_build_root = +- rebase_path(clang_warning_suppression_file, root_build_dir) +- inputs = [ clang_warning_suppression_file ] +- cflags = [ "--warning-suppression-mappings=" + from_build_root ] ++ if (is_clang) { ++ cflags += [ "-Xclang", "-fno-cxx-modules" ] + } + } + +@@ -1830,18 +1605,6 @@ config("sanitize_c_array_bounds") { + } + } + +-config("rustc_revision") { +- if (rustc_revision != "") { +- # Similar to the above config, this is here so that all files get recompiled +- # after a rustc roll. Nothing should ever read this cfg. This will not be +- # set if a custom toolchain is used. +- rustflags = [ +- "--cfg", +- "cr_rustc_revision=\"$rustc_revision\"", +- ] +- } +-} +- + config("compiler_arm_fpu") { + if (current_cpu == "arm" && !is_ios) { + cflags = [ "-mfpu=$arm_fpu" ] +@@ -1867,6 +1630,19 @@ config("compiler_arm") { + } + + config("libcxx_module") { ++ cflags_cc = [ ++ # TODO(crbug.com/1456385): Figure out if this can be removed. ++ "-Wno-modules-ambiguous-internal-linkage", ++ ++ # TODO(crbug.com/40440396): Clean up. ++ "-Wno-modules-import-nested-redundant", ++ ++ # Needed to allow using builtin modules when the headers are ++ # unnecessarily using extern "C". ++ "-Wno-module-import-in-extern-c", ++ ] ++} ++config("libcxx_modulex") { + if (use_clang_modules) { + cflags_cc = [ + "-fmodules", +@@ -2163,18 +1939,6 @@ config("default_warnings") { + ] + } + +- if (is_component_build && use_clang_warning_suppression_file && !is_win) { +- # Warn for globally unique objects which might get duplicated if built +- # into different components, due to hidden visibility. Only applicable +- # to component builds. +- +- # For details about the warning and now to fix it, see the official docs at +- # https://clang.llvm.org/docs/DiagnosticsReference.html#wunique-object-duplication +- # If you still have trouble resolving it, file a bug asking for advice in the +- # Chromium > Tools > LLVM component, and cc dloehr and thakis. +- cflags_cc += [ "-Wunique-object-duplication" ] +- } +- + if (is_wasm) { + # Abseil's `symbolize_emscripten.inc` file currently has macros that are + # not compatible with C++98, so turn off the warnings. +@@ -2206,14 +1970,6 @@ config("default_warnings") { + if (cc_wrapper == "ccache" || cc_wrapper == "icecc") { + cflags += [ "-Wno-gnu-line-marker" ] + } +- +- if (is_wexit_time_destructors_default && +- use_clang_warning_suppression_file) { +- # TODO(crbug.com/40031409): We are migrating towards making this warning +- # enabled by default. Once that is completed, the warning +- # should always be added for clang builds. +- cflags += [ "-Wexit-time-destructors" ] +- } + } + + # TODO(crbug.com/354162568): Clean up and enable. +@@ -2286,11 +2042,7 @@ config("chromium_code") { + defines = [ "_HAS_NODISCARD" ] + } + } else { +- cflags = [ "-Wall" ] +- if (is_clang) { +- # Enable extra warnings for chromium_code when we control the compiler. +- cflags += [ "-Wextra" ] +- } ++ cflags = [ ] + + # In Chromium code, we define __STDC_foo_MACROS in order to get the + # C99 macros on Mac and Linux. +@@ -2299,24 +2051,6 @@ config("chromium_code") { + "__STDC_FORMAT_MACROS", + ] + +- if (!is_debug && !using_sanitizer && current_cpu != "s390x" && +- current_cpu != "s390" && current_cpu != "ppc64" && +- current_cpu != "mips" && current_cpu != "mips64" && +- current_cpu != "riscv64" && current_cpu != "loong64") { +- # Non-chromium code is not guaranteed to compile cleanly with +- # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are +- # disabled, so only do that for Release build. +- fortify_level = "2" +- +- # ChromeOS's toolchain supports a high-quality _FORTIFY_SOURCE=3 +- # implementation with a few custom glibc patches. Use that if it's +- # available. +- if (is_chromeos_device) { +- fortify_level = "3" +- } +- defines += [ "_FORTIFY_SOURCE=" + fortify_level ] +- } +- + if (is_apple) { + cflags_objc = [ "-Wimplicit-retain-self" ] + cflags_objcc = [ "-Wimplicit-retain-self" ] +@@ -2732,7 +2466,8 @@ config("default_stack_frames") { + # [0]: https://pinpoint-dot-chromeperf.appspot.com/job/147634a8be0000 + # [1]: https://pinpoint-dot-chromeperf.appspot.com/job/132bc772be0000 + # [2]: https://crrev.com/c/5447532 +-config("optimize") { ++config("optimize") { } ++config("xoptimize") { + if (is_win) { + # clang-cl's /O2 corresponds to clang's -O3, and really want -O2 for + # consistency with the other platforms. +@@ -2781,7 +2516,8 @@ config("optimize") { + } + + # Turn off optimizations. +-config("no_optimize") { ++config("no_optimize") { } ++config("xno_optimize") { + if (is_win) { + cflags = [ + "/Od", # Disable optimization. +@@ -2816,7 +2552,8 @@ config("no_optimize") { + # Turns up the optimization level. Used to explicitly enable -O2 instead of + # -Os for select targets on platforms that use optimize_for_size. No-op + # elsewhere. +-config("optimize_max") { ++config("optimize_max") { } ++config("xoptimize_max") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2837,7 +2574,8 @@ config("optimize_max") { + # + # TODO(crbug.com/41259697) - rework how all of these configs are related + # so that we don't need this disclaimer. +-config("optimize_speed") { ++config("optimize_speed") { } ++config("xoptimize_speed") { + ldflags = common_optimize_on_ldflags + if (is_win) { + # Favor speed over size, /O2 must be before the common flags. +@@ -2854,7 +2592,8 @@ config("optimize_speed") { + rustflags = [ "-Copt-level=3" ] + } + +-config("optimize_fuzzing") { ++config("optimize_fuzzing") { } ++config("xoptimize_fuzzing") { + cflags = [ "-O1" ] + common_optimize_on_cflags + rustflags = [ "-Copt-level=1" ] + ldflags = common_optimize_on_ldflags +@@ -2981,7 +2720,8 @@ config("win_pdbaltpath") { + } + + # Full symbols. +-config("symbols") { ++config("symbols") { } ++config("xsymbols") { + rustflags = [] + configs = [] + if (is_win) { +@@ -3137,7 +2877,8 @@ config("symbols") { + # Minimal symbols. + # This config guarantees to hold symbol for stack trace which are shown to user + # when crash happens in unittests running on buildbot. +-config("minimal_symbols") { ++config("minimal_symbols") { } ++config("xminimal_symbols") { + rustflags = [] + if (is_win) { + # Functions, files, and line tables only. +@@ -3213,7 +2954,8 @@ config("minimal_symbols") { + # This configuration contains function names only. That is, the compiler is + # told to not generate debug information and the linker then just puts function + # names in the final debug information. +-config("no_symbols") { ++config("no_symbols") { } ++config("xno_symbols") { + if (is_win) { + ldflags = [ "/DEBUG" ] + +diff --git a/build/config/gcc/BUILD.gn b/build/config/gcc/BUILD.gn +index a659210b19..bde0e1b273 100644 +--- a/build/config/gcc/BUILD.gn ++++ b/build/config/gcc/BUILD.gn +@@ -32,7 +32,7 @@ declare_args() { + # See http://gcc.gnu.org/wiki/Visibility + config("symbol_visibility_hidden") { + cflags = [ "-fvisibility=hidden" ] +- rustflags = [ "-Zdefault-visibility=hidden" ] ++ # rustflags = [ "-Zdefault-visibility=hidden" ] + + # Visibility attribute is not supported on AIX. + if (current_os != "aix") { +diff --git a/build/config/rust.gni b/build/config/rust.gni +index 55bd7b78ee..be36aef69f 100644 +--- a/build/config/rust.gni ++++ b/build/config/rust.gni +@@ -73,7 +73,8 @@ declare_args() { + # + # TODO(crbug.com/40281834): Re-enable ThinLTO for Rust on LaCrOS + # TODO(b/300937673): Re-enable ThinLTO for Rust on ash-chrome +- toolchain_supports_rust_thin_lto = !is_chromeos ++ # toolchain_supports_rust_thin_lto = !is_chromeos ++ toolchain_supports_rust_thin_lto = false + + # Any extra std rlibs in your Rust toolchain, relative to the standard + # Rust toolchain. Typically used with 'rust_sysroot_absolute' diff --git a/www-client/chromium/files/chromium-142-rust-1.8x.patch b/www-client/chromium/files/chromium-142-rust-1.8x.patch new file mode 100644 index 0000000..e964482 --- /dev/null +++ b/www-client/chromium/files/chromium-142-rust-1.8x.patch @@ -0,0 +1,17 @@ +diff --git a/build/rust/allocator/lib.rs b/build/rust/allocator/lib.rs +index a7fa7a470f..742688567c 100644 +--- a/build/rust/allocator/lib.rs ++++ b/build/rust/allocator/lib.rs +@@ -96,6 +96,12 @@ mod both_allocators { + 0 + } + ++ // TODO(crbug.com/422538133) Remove after rolling past ++ // https://github.com/rust-lang/rust/pull/141061 ++ #[no_mangle] ++ #[linkage = "weak"] ++ static __rust_no_alloc_shim_is_unstable: u8 = 0; ++ + // Mangle the symbol name as rustc expects. + // TODO(crbug.com/440481922): Remove this after rolling past https://github.com/rust-lang/rust/pull/143387 + #[rustc_std_internal_symbol] |