From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1550358-garchives=archives.gentoo.org@lists.gentoo.org>
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 27D5415800A
	for <garchives@archives.gentoo.org>; Tue, 29 Aug 2023 11:20:36 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 2E3552BC04C;
	Tue, 29 Aug 2023 11:20:33 +0000 (UTC)
Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183])
	(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 112EA2BC04C
	for <gentoo-commits@lists.gentoo.org>; Tue, 29 Aug 2023 11:20:33 +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 A84B4340CF4
	for <gentoo-commits@lists.gentoo.org>; Tue, 29 Aug 2023 11:20:31 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 6326E10E0
	for <gentoo-commits@lists.gentoo.org>; Tue, 29 Aug 2023 11:20:28 +0000 (UTC)
From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" <mgorny@gentoo.org>
Message-ID: <1693308016.03ef4d6a927583c5ec9e61ffdc4c9de1afd33995.mgorny@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/lld/
X-VCS-Repository: repo/gentoo
X-VCS-Files: sys-devel/lld/Manifest sys-devel/lld/lld-18.0.0_pre20230829.ebuild
X-VCS-Directories: sys-devel/lld/
X-VCS-Committer: mgorny
X-VCS-Committer-Name: Michał Górny
X-VCS-Revision: 03ef4d6a927583c5ec9e61ffdc4c9de1afd33995
X-VCS-Branch: master
Date: Tue, 29 Aug 2023 11:20:28 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 8af36f5a-af54-4df7-a4ff-842896988c9c
X-Archives-Hash: b56c6a1484ba991c50a8cd4bfa8ab8a1

commit:     03ef4d6a927583c5ec9e61ffdc4c9de1afd33995
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Tue Aug 29 10:49:34 2023 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Tue Aug 29 11:20:16 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=03ef4d6a

sys-devel/lld: Add 18.0.0_pre20230829 snapshot

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 sys-devel/lld/Manifest                      |  1 +
 sys-devel/lld/lld-18.0.0_pre20230829.ebuild | 89 +++++++++++++++++++++++++++++
 2 files changed, 90 insertions(+)

diff --git a/sys-devel/lld/Manifest b/sys-devel/lld/Manifest
index 09b3d75bef4e..df1d14d0bc48 100644
--- a/sys-devel/lld/Manifest
+++ b/sys-devel/lld/Manifest
@@ -8,3 +8,4 @@ DIST llvm-project-16.0.6.src.tar.xz.sig 566 BLAKE2B 2060cebd5ed57cb8a86a44238c43
 DIST llvm-project-17.0.0rc3.src.tar.xz 127805656 BLAKE2B ecaead9f227b8357a5dc5ff21554d9b4f5aa036df1b88676fd8c3e16b438381db062872be396af5246e12cd71812a886016e0331a272dafc3508ecd0bfbb50ed SHA512 5f48b4af2e4f9bc470fcfd42fd48072b7bd442bc676d8401b04fbc6e9014a9a78e1bf524ba78f7ae8a1246222a6b03ca662721e3bf6e9eb03a015dd3306c7234
 DIST llvm-project-17.0.0rc3.src.tar.xz.sig 438 BLAKE2B 7b644cf501d17a6aef9b052e359ba06c1840a75e5263de46d938dbbdea07720b53d7ee6b5861ad641d0f7a7f75c6cc17717847b0ea9cf08873dbfacbe1c19074 SHA512 7059b1a90b7dd8cfa831f9e199a3a817358fd75d7c7d7e6de446d5443fce5831877a28e9b964ea238c1d803f9054bf4f53a97622d5f756f7f99aaa1c1a279f44
 DIST llvm-project-e3373c6c83d3855adb78f1952a3bf0398baf359e.tar.gz 196926975 BLAKE2B 9da1052db0a6ff81a8b76cbf9cb2ab7eed5c8798dc5ae6887a4694de8b151c7a1282cfff2da2e8440b1a67d3d12c33db319fbbe6062761b6d5369e6b335821ae SHA512 8bb6d49ddb824e932f7bad3c51e4a6c2227139aaf19c02e9deb15657919bc12ea41844d8fe045061814aefb9031d82b167c7c0c20bedaa09aaffe164a2109f7d
+DIST llvm-project-f6259d9b9a546dbfa5bc2f29313c6edd6c701177.tar.gz 196957045 BLAKE2B c38b17f4e697c090b0b70385e45ca4ce97981746738e556154895d5b57cede90f6b8bdc5f41023bda6e942f07f572aa508cf0107fb81bee80a5ea9f13ac495fd SHA512 8394a42e1963618ed7f7cf7770acb72ae6bf84f3e2351218b5049ea2d76ff6ae768ad5588ffd1b2be1b5228a8fcb03663430814c409ceb9fa5735c891847f816

diff --git a/sys-devel/lld/lld-18.0.0_pre20230829.ebuild b/sys-devel/lld/lld-18.0.0_pre20230829.ebuild
new file mode 100644
index 000000000000..085543e50762
--- /dev/null
+++ b/sys-devel/lld/lld-18.0.0_pre20230829.ebuild
@@ -0,0 +1,89 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..12} )
+inherit cmake flag-o-matic llvm llvm.org python-any-r1 toolchain-funcs
+
+DESCRIPTION="The LLVM linker (link editor)"
+HOMEPAGE="https://llvm.org/"
+
+LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA"
+SLOT="${LLVM_MAJOR}/${LLVM_SOABI}"
+KEYWORDS=""
+IUSE="+debug test zstd"
+RESTRICT="!test? ( test )"
+
+DEPEND="
+	~sys-devel/llvm-${PV}[debug=,zstd=]
+	sys-libs/zlib:=
+	zstd? ( app-arch/zstd:= )
+"
+RDEPEND="
+	${DEPEND}
+	!sys-devel/lld:0
+"
+BDEPEND="
+	sys-devel/llvm:${LLVM_MAJOR}
+	test? (
+		>=dev-util/cmake-3.16
+		$(python_gen_any_dep ">=dev-python/lit-${PV}[\${PYTHON_USEDEP}]")
+	)
+"
+PDEPEND="
+	>=sys-devel/lld-toolchain-symlinks-16-r2:${LLVM_MAJOR}
+"
+
+LLVM_COMPONENTS=( lld cmake libunwind/include/mach-o )
+llvm.org_set_globals
+
+python_check_deps() {
+	python_has_version ">=dev-python/lit-${PV}[${PYTHON_USEDEP}]"
+}
+
+pkg_setup() {
+	LLVM_MAX_SLOT=${LLVM_MAJOR} llvm_pkg_setup
+	use test && python-any-r1_pkg_setup
+}
+
+src_unpack() {
+	llvm.org_src_unpack
+
+	# Directory ${WORKDIR}/llvm does not exist with USE="-test",
+	# but LLVM_MAIN_SRC_DIR="${WORKDIR}/llvm" is set below,
+	# and ${LLVM_MAIN_SRC_DIR}/../libunwind/include is used by build system
+	# (lld/MachO/CMakeLists.txt) and is expected to be resolvable
+	# to existent directory ${WORKDIR}/libunwind/include.
+	mkdir -p "${WORKDIR}/llvm" || die
+}
+
+src_configure() {
+	# LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
+	use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG"
+
+	use elibc_musl && append-ldflags -Wl,-z,stack-size=2097152
+
+	local mycmakeargs=(
+		-DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}"
+		-DBUILD_SHARED_LIBS=ON
+		-DLLVM_INCLUDE_TESTS=$(usex test)
+	)
+
+	use test && mycmakeargs+=(
+		-DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit"
+		-DLLVM_LIT_ARGS="$(get_lit_flags)"
+		-DPython3_EXECUTABLE="${PYTHON}"
+	)
+
+	tc-is-cross-compiler &&	mycmakeargs+=(
+		-DLLVM_TABLEGEN_EXE="${BROOT}/usr/lib/llvm/${LLVM_MAJOR}/bin/llvm-tblgen"
+	)
+
+	cmake_src_configure
+}
+
+src_test() {
+	local -x LIT_PRESERVES_TMP=1
+	cmake_build check-lld
+}