From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 18513158099 for ; Thu, 30 Nov 2023 03:49:11 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 595D52BC01F; Thu, 30 Nov 2023 03:49:10 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 40A982BC01F for ; Thu, 30 Nov 2023 03:49:10 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 87A49335C7A for ; Thu, 30 Nov 2023 03:49:09 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 995741436 for ; Thu, 30 Nov 2023 03:49:06 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1701316081.23a47cce8ca65e27f5408aa0b4e6d6eb8fb77eab.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/mold/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-devel/mold/Manifest sys-devel/mold/mold-2.4.0.ebuild X-VCS-Directories: sys-devel/mold/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 23a47cce8ca65e27f5408aa0b4e6d6eb8fb77eab X-VCS-Branch: master Date: Thu, 30 Nov 2023 03:49:06 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 3514991a-2ca6-47fe-aa9e-d45c3493a008 X-Archives-Hash: 4fb456b969f0184c1b07effc276f7158 commit: 23a47cce8ca65e27f5408aa0b4e6d6eb8fb77eab Author: Sam James gentoo org> AuthorDate: Thu Nov 30 03:48:01 2023 +0000 Commit: Sam James gentoo org> CommitDate: Thu Nov 30 03:48:01 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=23a47cce sys-devel/mold: add 2.4.0 Closes: https://bugs.gentoo.org/914849 Signed-off-by: Sam James gentoo.org> sys-devel/mold/Manifest | 1 + sys-devel/mold/mold-2.4.0.ebuild | 95 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 96 insertions(+) diff --git a/sys-devel/mold/Manifest b/sys-devel/mold/Manifest index a6fd9b87cfdb..95e10eefa2bb 100644 --- a/sys-devel/mold/Manifest +++ b/sys-devel/mold/Manifest @@ -1,3 +1,4 @@ DIST mold-2.1.0.tar.gz 9278811 BLAKE2B b31e13f92177553adf5069cf35c8c75c7bc28f0af4d1726cdc0c6abc1c9d3baaa5be512c3a8fb9bc3c3110096a79e1c6751c701171769595a2234fc1fa8c441a SHA512 f1c98d349b35b4042109d71f7db6eb8d7d089dc3241735bbd7b5402d513dcc85ca17904828779e5fc8234650fa9fb97f47c3a2f3e89cc2fb3cb9e9110439e5a2 DIST mold-2.3.2.tar.gz 9970530 BLAKE2B db943ad6fab336a8c9c7b5588895cc1232ebfac25fe9dd884a2fbd71ba8d76b9bf7543b4d98cbda9635a7898e980ec5dc2866ef1d02e7a80e7fb9d7f0cbca443 SHA512 dd98acb351757f99399b7d52589c339648478624323fd45c9e986eaf7f1a60f52ace4c09a2d20246e9340109641bda676735da9de89a277989851bd5f52ea9d0 DIST mold-2.3.3.tar.gz 9965345 BLAKE2B 391d9e38f13ae185c1cd9cff9cfd31c091952cf90276ccb4d7eff41beaf1fa0537bfbafafa9ffa08ab1d09db9c52aa4abcd0a765f8edc6d058f8832b35b726ad SHA512 cbe82568151a772097c86a25eebb0b0f8fc769d6b767169280f535d41cd3f27fc4640da9b86fb4a495e571f9d712368dda95c4431f8ebb2b42227de2b22fc80b +DIST mold-2.4.0.tar.gz 9974233 BLAKE2B 0710d9ce0407b64b05a23e04db142d603b38d41cd9e5e322b650680ee2bd8684f57647e9a0b5efc23b2106eb1e38e38143be7d4b357b2d32e4fe0b6a99e41cca SHA512 e332d027f783dfb0a4f48b1fb7daf98e11e830f8de82b971b58ee8a7bae59eaa30b8155e7491b6057f0ce8e0b09ddd0ab1d364f01ea15517e1d089fdb292a4e5 diff --git a/sys-devel/mold/mold-2.4.0.ebuild b/sys-devel/mold/mold-2.4.0.ebuild new file mode 100644 index 000000000000..2b9db9efa079 --- /dev/null +++ b/sys-devel/mold/mold-2.4.0.ebuild @@ -0,0 +1,95 @@ +# Copyright 2021-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake toolchain-funcs + +DESCRIPTION="A Modern Linker" +HOMEPAGE="https://github.com/rui314/mold" +if [[ ${PV} == 9999 ]] ; then + EGIT_REPO_URI="https://github.com/rui314/mold.git" + inherit git-r3 +else + SRC_URI="https://github.com/rui314/mold/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~arm ~arm64 ~loong ~riscv ~sparc ~x86" +fi + +# mold (MIT) +# - xxhash (BSD-2) +LICENSE="MIT BSD-2" +SLOT="0" + +RDEPEND=" + app-arch/zstd:= + >=dev-cpp/tbb-2021.7.0-r1:= + dev-libs/blake3:= + sys-libs/zlib + !kernel_Darwin? ( + >=dev-libs/mimalloc-2:= + ) +" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}"/${PN}-2.3.0-no-pch.patch +) + +pkg_pretend() { + # Requires a c++20 compiler, see #831473 + if [[ ${MERGE_TYPE} != binary ]]; then + if tc-is-gcc && [[ $(gcc-major-version) -lt 10 ]]; then + die "${PN} needs at least gcc 10" + elif tc-is-clang && [[ $(clang-major-version) -lt 12 ]]; then + die "${PN} needs at least clang 12" + fi + fi +} + +src_prepare() { + cmake_src_prepare + + # Needs unpackaged dwarfdump + rm test/elf/{{dead,compress}-debug-sections,compressed-debug-info}.sh || die + + # Heavy tests, need qemu + rm test/elf/gdb-index-{compress-output,dwarf{2,3,4,5}}.sh || die + rm test/elf/lto-{archive,dso,gcc,llvm,version-script}.sh || die + + # Sandbox sadness + rm test/elf/run.sh || die + sed -i 's|`pwd`/mold-wrapper.so|"& ${LD_PRELOAD}"|' \ + test/elf/mold-wrapper{,2}.sh || die + + # static-pie tests require glibc built with static-pie support + if ! has_version -d 'sys-libs/glibc[static-pie(+)]'; then + rm test/elf/{,ifunc-}static-pie.sh || die + fi +} + +src_configure() { + local mycmakeargs=( + -DCMAKE_DISABLE_PRECOMPILE_HEADERS=ON + -DMOLD_ENABLE_QEMU_TESTS=OFF + -DMOLD_LTO=OFF # Should be up to the user to decide this with CXXFLAGS. + -DMOLD_USE_MIMALLOC=$(usex !kernel_Darwin) + -DMOLD_USE_SYSTEM_MIMALLOC=ON + -DMOLD_USE_SYSTEM_TBB=ON + ) + cmake_src_configure +} + +src_install() { + dobin "${BUILD_DIR}"/${PN} + + # https://bugs.gentoo.org/872773 + insinto /usr/$(get_libdir)/mold + doins "${BUILD_DIR}"/${PN}-wrapper.so + + dodoc docs/{design,execstack}.md + doman docs/${PN}.1 + + dosym ${PN} /usr/bin/ld.${PN} + dosym ${PN} /usr/bin/ld64.${PN} + dosym -r /usr/bin/${PN} /usr/libexec/${PN}/ld +}