* [gentoo-commits] repo/proj/guru:dev commit in: sci-electronics/slang/files/, sci-electronics/slang/
@ 2024-04-22 2:32 Rui Huang
0 siblings, 0 replies; only message in thread
From: Rui Huang @ 2024-04-22 2:32 UTC (permalink / raw
To: gentoo-commits
commit: 8f68c4625c1b44375299d604fb8372c13a202156
Author: Huang Rui <vowstar <AT> gmail <DOT> com>
AuthorDate: Mon Apr 22 02:25:41 2024 +0000
Commit: Rui Huang <vowstar <AT> gmail <DOT> com>
CommitDate: Mon Apr 22 02:27:22 2024 +0000
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=8f68c462
sci-electronics/slang: add 6.0
Signed-off-by: Huang Rui <vowstar <AT> gmail.com>
sci-electronics/slang/Manifest | 1 +
.../files/slang-6.0-fix-gentoo-libfmt-depend.patch | 26 +++++++++
sci-electronics/slang/slang-6.0.ebuild | 66 ++++++++++++++++++++++
3 files changed, 93 insertions(+)
diff --git a/sci-electronics/slang/Manifest b/sci-electronics/slang/Manifest
index c1278ad217..b37ddbc2f7 100644
--- a/sci-electronics/slang/Manifest
+++ b/sci-electronics/slang/Manifest
@@ -1,2 +1,3 @@
DIST slang-4.0.tar.gz 1308308 BLAKE2B 99029a26b3fe86942abc33381f8f9ba050c09b390ed7fc54404f4054eb34a83e168d53096cad2e8f037954770a95009c701c86b1e59e1e9d02e1709fd120164c SHA512 043c053452b2d452875b2e3ed96be5b96275544e2a692bec8b170e01cefec6e5648a6681e3cac3afd2a68c8ec57f6461a9a73394d74abbc8627d49b66978808e
DIST slang-5.0.tar.gz 1334032 BLAKE2B 08981f86d0be6a4a7d391a2b65d8f4e5bdab8e3ba50f6e847e2b25fec9d9345e806045faae3c74fd71db90f939d8668ff775465ea1e8433d660a0a53f20a358a SHA512 a1b7b9aac7357a9a7cc1818adbb5e9622234f607aba452ca57e3d28b31779339bb19557137cf37cdcc2abb2aba15eb6d2f580169322caf075a2518b3d8634a26
+DIST slang-6.0.tar.gz 1401115 BLAKE2B 77c6359e8de39216bef553ec832a643397e83847146223acf2512efbbb2cd15eb0b874ff8f021adb72472ce5bb77ca33648ed8c392b21df7ed349110f5654d17 SHA512 bd9e24abc6e83ca2ca0527271754bd0312e094c040feccbf95852a84dba486addd2ed0a40e5a855c1b41918061a6a7c34ca1a4f6610b1e941e50e1b74402cb5c
diff --git a/sci-electronics/slang/files/slang-6.0-fix-gentoo-libfmt-depend.patch b/sci-electronics/slang/files/slang-6.0-fix-gentoo-libfmt-depend.patch
new file mode 100644
index 0000000000..59d9166d18
--- /dev/null
+++ b/sci-electronics/slang/files/slang-6.0-fix-gentoo-libfmt-depend.patch
@@ -0,0 +1,26 @@
+From 4be4a956ad1a1ff767dcc91c88fac103d5780578 Mon Sep 17 00:00:00 2001
+From: Huang Rui <vowstar@gmail.com>
+Date: Fri, 15 Sep 2023 19:38:34 +0800
+Subject: [PATCHv1] external/CMakeLists.txt: fix gentoo libfmt depend
+
+Signed-off-by: Huang Rui <vowstar@gmail.com>
+---
+ external/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt
+index 9341eb2e2ffa..4ea7429a69a8 100644
+--- a/external/CMakeLists.txt
++++ b/external/CMakeLists.txt
+@@ -4,7 +4,7 @@
+ # ~~~
+
+ # Required minimum versions for dependencies
+-set(fmt_min_version "10.2")
++set(fmt_min_version "9.0")
+ set(mimalloc_min_version "2.1")
+ set(catch2_min_version "3.0")
+
+--
+2.42.0
+
diff --git a/sci-electronics/slang/slang-6.0.ebuild b/sci-electronics/slang/slang-6.0.ebuild
new file mode 100644
index 0000000000..a1660d0a4b
--- /dev/null
+++ b/sci-electronics/slang/slang-6.0.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="8"
+
+PYTHON_COMPAT=( python3_{10..12} )
+inherit cmake python-single-r1
+
+DESCRIPTION="SystemVerilog compiler and language services"
+HOMEPAGE="
+ https://sv-lang.com
+ https://github.com/MikePopoloski/slang
+"
+
+if [[ "${PV}" == "9999" ]] ; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/MikePopoloski/${PN}.git"
+else
+ SRC_URI="https://github.com/MikePopoloski/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~arm64 ~riscv ~x86"
+ S="${WORKDIR}/${P}"
+fi
+
+LICENSE="MIT"
+SLOT="0"
+IUSE="python test"
+REQUIRED_USE=" ${PYTHON_REQUIRED_USE} "
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ ${PYTHON_DEPS}
+ $(python_gen_cond_dep '
+ >=dev-python/pybind11-2.10[${PYTHON_USEDEP}]
+ ')
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ >=dev-libs/libfmt-9.1.0
+ test? ( >=dev-cpp/catch-3.0.1 )
+"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-6.0-fix-gentoo-libfmt-depend.patch"
+)
+
+src_configure() {
+ python_setup
+ local mycmakeargs=(
+ -D CMAKE_INSTALL_LIBDIR="${EPREFIX}/usr/$(get_libdir)"
+ -D BUILD_SHARED_LIBS=ON
+ -D SLANG_INCLUDE_PYLIB=$(usex python)
+ -D SLANG_INCLUDE_TESTS=$(usex test)
+ -D SLANG_USE_MIMALLOC=OFF
+ )
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+
+ if use python; then
+ # fix python unexpected paths QA
+ mkdir -p "${D}/$(python_get_sitedir)" || die
+ mv "${D}"/usr/pyslang* "${D}/$(python_get_sitedir)" || die
+ fi
+}
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2024-04-22 2:33 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-22 2:32 [gentoo-commits] repo/proj/guru:dev commit in: sci-electronics/slang/files/, sci-electronics/slang/ Rui Huang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox