commit:     ad2ece4a6fe9fa09e308f8cd750626fe0bbe88e8
Author:     Pavel Sobolev <contact <AT> paveloom <DOT> dev>
AuthorDate: Wed Jul  9 19:09:26 2025 +0000
Commit:     Pavel Sobolev <contact <AT> paveloom <DOT> dev>
CommitDate: Sat Jul 12 13:43:56 2025 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=ad2ece4a

dev-libs/zycore-c: new package, add 1.5.2

Signed-off-by: Pavel Sobolev <contact <AT> paveloom.dev>

 dev-libs/zycore-c/Manifest                         |  1 +
 ...2-build-documentation-only-when-requested.patch | 35 +++++++++++++++++++++
 dev-libs/zycore-c/metadata.xml                     | 16 ++++++++++
 dev-libs/zycore-c/zycore-c-1.5.2.ebuild            | 36 ++++++++++++++++++++++
 4 files changed, 88 insertions(+)

diff --git a/dev-libs/zycore-c/Manifest b/dev-libs/zycore-c/Manifest
new file mode 100644
index 0000000000..32a8e8e9be
--- /dev/null
+++ b/dev-libs/zycore-c/Manifest
@@ -0,0 +1 @@
+DIST zycore-c-1.5.2.tar.gz 65981 BLAKE2B 
127e9a0d0da0d0887b85a806deb7a6404913e9ed77afbfa4fd945e139c4102a26d3ae0128812bc8ed1b6da6e1d460217f126c23bbd4c12c888ebcea1f1483049
 SHA512 
dd410010b99e11f40ad5234d21c9857bd57e47591ed9caec45c6199bfd690f7158499659c874680f2087bfd2b6eee41f08e95c367f83af3585690ce7d20ccb87

diff --git 
a/dev-libs/zycore-c/files/zycore-c-1.5.2-build-documentation-only-when-requested.patch
 
b/dev-libs/zycore-c/files/zycore-c-1.5.2-build-documentation-only-when-requested.patch
new file mode 100644
index 0000000000..05f45c0d7c
--- /dev/null
+++ 
b/dev-libs/zycore-c/files/zycore-c-1.5.2-build-documentation-only-when-requested.patch
@@ -0,0 +1,35 @@
+From: Pavel Sobolev <[email protected]>
+Subject: [PATCH] Build documentation only when requested.
+
+Signed-off-by: Pavel Sobolev <[email protected]>
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -36,6 +36,9 @@ option(ZYAN_FORCE_ASSERTS
+ option(ZYCORE_BUILD_SHARED_LIB
+     "Build shared library"
+     OFF)
++option(ZYCORE_BUILD_DOCS
++    "Build documentation"
++    OFF)
+ option(ZYCORE_BUILD_EXAMPLES
+     "Build examples"
+     OFF)
+@@ -228,7 +231,8 @@ install(DIRECTORY "include/" DESTINATION 
${CMAKE_INSTALL_INCLUDEDIR})
+ # Doxygen documentation                                                       
                    #
+ # 
===============================================================================================
 #
+ 
+-find_package(Doxygen)
++if (ZYCORE_BUILD_DOCS)
++find_package(Doxygen REQUIRED)
+ if (DOXYGEN_FOUND)
+     set(DOXYGEN_GENERATE_MAN YES)
+     doxygen_add_docs(ZycoreDoc "include/Zycore/" ALL)
+@@ -243,6 +247,7 @@ if (DOXYGEN_FOUND)
+         COMPONENT Documentation
+     )
+ endif()
++endif()
+ 
+ # 
===============================================================================================
 #
+ # Developer mode                                                              
                    #

diff --git a/dev-libs/zycore-c/metadata.xml b/dev-libs/zycore-c/metadata.xml
new file mode 100644
index 0000000000..8bcd0ca85c
--- /dev/null
+++ b/dev-libs/zycore-c/metadata.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+  <maintainer type="person">
+    <email>[email protected]</email>
+    <name>Pavel Sobolev</name>
+  </maintainer>
+  <upstream>
+    <bugs-to>https://github.com/zyantific/zycore-c/issues</bugs-to>
+    <remote-id type="github">zyantific/zycore-c</remote-id>
+  </upstream>
+  <longdescription lang="en">
+    Internal library providing platform independent types, macros and a 
fallback
+    for environments without LibC.
+  </longdescription>
+</pkgmetadata>

diff --git a/dev-libs/zycore-c/zycore-c-1.5.2.ebuild 
b/dev-libs/zycore-c/zycore-c-1.5.2.ebuild
new file mode 100644
index 0000000000..44a1170f72
--- /dev/null
+++ b/dev-libs/zycore-c/zycore-c-1.5.2.ebuild
@@ -0,0 +1,36 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Zyan Core Library for C"
+HOMEPAGE="https://github.com/zyantific/zycore-c";
+SRC_URI="https://github.com/zyantific/zycore-c/archive/refs/tags/v${PV}.tar.gz 
-> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="doc test"
+RESTRICT="!test? ( test )"
+
+BDEPEND="
+       doc? ( app-text/doxygen )
+       test? ( dev-cpp/gtest )
+"
+
+PATCHES=(
+       "${FILESDIR}/${PN}-1.5.2-build-documentation-only-when-requested.patch"
+)
+
+src_configure() {
+       local mycmakeargs=(
+               -DZYCORE_BUILD_SHARED_LIB=yes
+
+               -DZYCORE_BUILD_DOCS=$(usex doc)
+               -DZYCORE_BUILD_TESTS=$(usex test)
+       )
+
+       cmake_src_configure
+}

Reply via email to