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 97DE2158043 for ; Sat, 13 Apr 2024 23:04:35 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6227BE2A3C; Sat, 13 Apr 2024 23:04: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 3DF5FE2A3E for ; Sat, 13 Apr 2024 23:04: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 13AE63433B0 for ; Sat, 13 Apr 2024 23:04:32 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 5AE3F16E7 for ; Sat, 13 Apr 2024 23:04:29 +0000 (UTC) From: "Horodniceanu Andrei" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Horodniceanu Andrei" Message-ID: <1713048451.1d4aecbcff00c424dc413ae6bdade57a3ceda80b.a.horodniceanu@gentoo> Subject: [gentoo-commits] repo/user/dlang:master commit in: dev-util/dlang-tools/ X-VCS-Repository: repo/user/dlang X-VCS-Files: dev-util/dlang-tools/dlang-tools-2.107.0-r1.ebuild X-VCS-Directories: dev-util/dlang-tools/ X-VCS-Committer: a.horodniceanu X-VCS-Committer-Name: Horodniceanu Andrei X-VCS-Revision: 1d4aecbcff00c424dc413ae6bdade57a3ceda80b X-VCS-Branch: master Date: Sat, 13 Apr 2024 23:04:29 +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: 853aac44-2d40-4a16-8221-11d3bc37bb68 X-Archives-Hash: 0730d3fca3d3f7dabae74bd8769c9cd0 commit: 1d4aecbcff00c424dc413ae6bdade57a3ceda80b Author: Andrei Horodniceanu proton me> AuthorDate: Sat Mar 9 17:06:47 2024 +0000 Commit: Horodniceanu Andrei proton me> CommitDate: Sat Apr 13 22:47:31 2024 +0000 URL: https://gitweb.gentoo.org/repo/user/dlang.git/commit/?id=1d4aecbc dev-util/dlang-tools: port to dlang-single.eclass Signed-off-by: Andrei Horodniceanu proton.me> dev-util/dlang-tools/dlang-tools-2.107.0-r1.ebuild | 64 ++++++++++++++++++++++ 1 file changed, 64 insertions(+) diff --git a/dev-util/dlang-tools/dlang-tools-2.107.0-r1.ebuild b/dev-util/dlang-tools/dlang-tools-2.107.0-r1.ebuild new file mode 100644 index 0000000..87b1fef --- /dev/null +++ b/dev-util/dlang-tools/dlang-tools-2.107.0-r1.ebuild @@ -0,0 +1,64 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DESCRIPTION="Ancilliary tools for the D programming language compiler" +HOMEPAGE="http://dlang.org/" +LICENSE="Boost-1.0" + +SLOT="0" +KEYWORDS="~amd64 ~x86" +TOOLS="ddemangle detab dustmite rdmd" +IUSE="+ddemangle detab dustmite +rdmd" + +DLANG_SLOT="$(ver_cut 1-2)" +RESTRICT="mirror" + +BETA="$(ver_cut 4)" +VERSION="$(ver_cut 1-3)" + +if [[ -n "${BETA}" ]]; then + # We want to convert a Gentoo version string into an upstream one: 2.097.0_rc1 -> 2.097.0-rc.1 + VERSION="$(ver_rs 3 "-" 4 ".")" +fi +SRC_URI="https://codeload.github.com/dlang/tools/tar.gz/v${VERSION} -> dlang-tools-${VERSION}.tar.gz" + +DLANG_COMPAT=( dmd-2_{106..107} gdc-12 ldc2-1_{35..36} ) + +inherit desktop dlang-single xdg-utils + +REQUIRED_USE="|| ( ${TOOLS[@]} ) ${DLANG_REQUIRED_USE}" +DEPEND=${DLANG_DEPS} +BDEPEND=${DLANG_DEPS} +RDEPEND=${DLANG_DEPS} + +S="${WORKDIR}/tools-${VERSION}" + +src_compile() { + use ddemangle && dlang_compile_bin ddemangle ddemangle.d + use detab && dlang_compile_bin detab detab.d + use dustmite && dlang_compile_bin dustmite DustMite/dustmite.d DustMite/splitter.d DustMite/polyhash.d + use rdmd && dlang_compile_bin rdmd rdmd.d +} + +src_install() { + for tool in ${TOOLS}; do + if use "${tool}"; then + dobin "${tool}" + fi + done + + # file icons + for size in 16 22 24 32 48 256; do + newicon --size "${size}" --context mimetypes "${FILESDIR}/icons/${size}/dmd-source.png" text-x-dsrc.png + done +} + +pkg_postinst() { + xdg_icon_cache_update +} + +pkg_postrm() { + xdg_icon_cache_update +}