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 AF30E158094 for ; Fri, 19 Aug 2022 17:56:05 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 61CA9E0864; Fri, 19 Aug 2022 17:56:04 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.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) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 30A7FE0864 for ; Fri, 19 Aug 2022 17:56:04 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (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 CBB59340E41 for ; Fri, 19 Aug 2022 17:56:02 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 4B011568 for ; Fri, 19 Aug 2022 17:56:01 +0000 (UTC) From: "Matthew Smith" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matthew Smith" Message-ID: <1660931718.3ea682897a3b3bd80ebe261170c0fec3ac04e985.matthew@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/mold/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-devel/mold/mold-9999.ebuild X-VCS-Directories: sys-devel/mold/ X-VCS-Committer: matthew X-VCS-Committer-Name: Matthew Smith X-VCS-Revision: 3ea682897a3b3bd80ebe261170c0fec3ac04e985 X-VCS-Branch: master Date: Fri, 19 Aug 2022 17:56:01 +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: 1fdac284-daba-490c-9b3f-dc4286cc16db X-Archives-Hash: fd6ea104471b6d14863c74d86e70c5f6 commit: 3ea682897a3b3bd80ebe261170c0fec3ac04e985 Author: Matthew Smith gentoo org> AuthorDate: Fri Aug 19 17:54:48 2022 +0000 Commit: Matthew Smith gentoo org> CommitDate: Fri Aug 19 17:55:18 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3ea68289 sys-devel/mold: update live ebuild Signed-off-by: Matthew Smith gentoo.org> sys-devel/mold/mold-9999.ebuild | 76 ++++++++++++++++++++--------------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/sys-devel/mold/mold-9999.ebuild b/sys-devel/mold/mold-9999.ebuild index 2a7faac5052d..b170b570b827 100644 --- a/sys-devel/mold/mold-9999.ebuild +++ b/sys-devel/mold/mold-9999.ebuild @@ -3,7 +3,7 @@ EAPI=8 -inherit toolchain-funcs +inherit cmake toolchain-funcs DESCRIPTION="A Modern Linker" HOMEPAGE="https://github.com/rui314/mold" @@ -12,28 +12,26 @@ if [[ ${PV} == 9999 ]] ; then inherit git-r3 else SRC_URI="https://github.com/rui314/mold/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" - KEYWORDS="~amd64" + KEYWORDS="~amd64 ~riscv" fi -LICENSE="AGPL-3" +# mold (AGPL-3) +# - xxhash (BSD-2) +# - tbb (Apache-2.0) +LICENSE="AGPL-3 Apache-2.0 BSD-2" SLOT="0" +IUSE="system-tbb" -RDEPEND=">=dev-cpp/tbb-2021.4.0:= +RDEPEND=" sys-libs/zlib + system-tbb? ( >=dev-cpp/tbb-2021.4.0:= ) !kernel_Darwin? ( >=dev-libs/mimalloc-2:= dev-libs/openssl:= - )" -# As of 1.1, xxhash is now a header-only dep, but it's now bundled :( -# TODO: restore SYSTEM_XXHASH upstream? + ) +" DEPEND="${RDEPEND}" -PATCHES=( - # Bug #841575 - "${FILESDIR}"/${PN}-1.2.1-install-nopython.patch - "${FILESDIR}"/${PN}-1.3.0-openssl-pkgconfig.patch -) - pkg_pretend() { # Requires a c++20 compiler, see #831473 if [[ ${MERGE_TYPE} != binary ]]; then @@ -46,7 +44,7 @@ pkg_pretend() { } src_prepare() { - default + cmake_src_prepare # Needs unpackaged dwarfdump rm test/elf/{{dead,compress}-debug-sections,compressed-debug-info}.sh || die @@ -64,34 +62,36 @@ src_prepare() { if ! has_version -d 'sys-libs/glibc[static-pie(+)]'; then rm test/elf/{,ifunc-}static-pie.sh || die fi -} - -src_compile() { - tc-export CC CXX - emake \ - CFLAGS="${CFLAGS}" \ - CXXFLAGS="${CXXFLAGS}" \ - SYSTEM_TBB=1 \ - SYSTEM_MIMALLOC=1 \ - STRIP="true" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" + # Don't require python + sed -i '/find_package(Python3/d' CMakeLists.txt || die + sed -i '/add_dependencies/d' CMakeLists.txt || die + cat <git-hash.cc +#include +namespace mold { +std::string mold_git_hash = "gentoo-${PVR}"; +} +EOF } -src_test() { - emake \ - SYSTEM_TBB=1 \ - SYSTEM_MIMALLOC=1 \ - check +src_configure() { + local mycmakeargs=( + -DMOLD_ENABLE_QEMU_TESTS=OFF + -DMOLD_LTO=OFF # Should be up to the user to decide this with CXXFLAGS. + -DMOLD_USE_SYSTEM_MIMALLOC=ON + -DMOLD_USE_SYSTEM_TBB=$(usex system-tbb) + ) + cmake_src_configure } src_install() { - emake \ - SYSTEM_TBB=1 \ - SYSTEM_MIMALLOC=1 \ - DESTDIR="${D}" \ - PREFIX="${EPREFIX}/usr" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - STRIP="true" \ - install + dobin "${BUILD_DIR}"/${PN} + dolib.so "${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 ../../../usr/bin/${PN} /usr/libexec/${PN}/ld }