commit:     7ff4dec0ee2ecdf36c5f22fcf0f4af00c875e945
Author:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
AuthorDate: Sun Feb 25 04:51:43 2024 +0000
Commit:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
CommitDate: Sun Feb 25 04:51:43 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7ff4dec0

dev-libs/leatherman: add 1.12.12

Signed-off-by: Matthew Thode <prometheanfire <AT> gentoo.org>

 dev-libs/leatherman/Manifest                  |  1 +
 dev-libs/leatherman/leatherman-1.12.12.ebuild | 56 +++++++++++++++++++++++++++
 2 files changed, 57 insertions(+)

diff --git a/dev-libs/leatherman/Manifest b/dev-libs/leatherman/Manifest
index 5f847fe81993..236c0c151bb1 100644
--- a/dev-libs/leatherman/Manifest
+++ b/dev-libs/leatherman/Manifest
@@ -1 +1,2 @@
 DIST leatherman-1.12.11.tar.gz 816707 BLAKE2B 
7e94c24b541efb9a8f879897eb13cbb7fbce7e87fd7543625e0c88717a79ccdcd1bc8d06268582ee4445a2628a71ef6ffd64b38f93ad0fbdd811e686623ac4f6
 SHA512 
26fb96a2f8bb34efe4df1220db18f9816ecd3b34d3ef1e84ecfda8833318f7e4f3dcd93535034669110e62fa69bbf9c43599d84739321c6d0075475cd2de7671
+DIST leatherman-1.12.12.tar.gz 818006 BLAKE2B 
b8174da6ae3f981b9ef44728069502264585b6ec8602125e54e2747c6f4ce1755979c4c7337af176bba234dcb6415acdbdff69b1a4c60ec87b69892043b91353
 SHA512 
b4041ec59dd716e599c12c31dd5401542efe0739abfc9d508b56dc759ca9bdeb29daac87b626d416f5339fca8909cfa98653a24a39b32bb1cd04baf99c6f1d92

diff --git a/dev-libs/leatherman/leatherman-1.12.12.ebuild 
b/dev-libs/leatherman/leatherman-1.12.12.ebuild
new file mode 100644
index 000000000000..7508537d3159
--- /dev/null
+++ b/dev-libs/leatherman/leatherman-1.12.12.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake
+
+DESCRIPTION="A C++ toolkit"
+HOMEPAGE="https://github.com/puppetlabs/leatherman";
+SRC_URI="https://github.com/puppetlabs/${PN}/archive/${PV}.tar.gz -> 
${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~sparc ~x86"
+IUSE="debug static-libs test"
+#RESTRICT="!test? ( test )"
+RESTRICT="test"  # restricted til we don't need the shared_nowide patch
+
+RDEPEND="dev-libs/boost:=[nls]
+       net-misc/curl"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+       "${FILESDIR}"/portage-sandbox-test-fix.patch
+       "${FILESDIR}"/1.12.2-shared_nowide.patch
+)
+
+src_prepare() {
+       sed -i 's/\-Werror\ //g' "cmake/cflags.cmake" || die
+       # vendored boost lib conflicts with boost 1.73 and above
+       cmake_src_prepare
+}
+
+src_configure() {
+       local mycmakeargs=(
+               -DCMAKE_VERBOSE_MAKEFILE=ON
+               -DCMAKE_BUILD_TYPE=None
+               -DLEATHERMAN_ENABLE_TESTING=$(usex test)
+               # We depend on Boost with nls, so this is always true
+               -DLEATHERMAN_USE_ICU=ON
+
+               -DLEATHERMAN_SHARED=$(usex !static-libs)
+       )
+
+       if use debug; then
+               mycmakeargs+=(
+                       -DCMAKE_BUILD_TYPE=Debug
+               )
+       fi
+
+       cmake_src_configure
+}
+
+src_test() {
+       "${WORKDIR}/${P}"_build/bin/leatherman_test || die
+}

Reply via email to