dev-cpp/pcg-cpp: new package, add 0.98.1_p20220408

Changes from ::guru:
* New snapshot
* Removed .pc file, which is not upstream
* Not installing samples
* Patch test to fail if failed

Signed-off-by: Alexey Sokolov <alexey+gentoo@asokolov.org>
Part-of: https://github.com/gentoo/gentoo/pull/43482
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Alexey Sokolov
2025-08-15 22:10:42 +01:00
committed by Sam James
parent 7aeb218709
commit 35c3e1bee8
4 changed files with 71 additions and 0 deletions

1
dev-cpp/pcg-cpp/Manifest Normal file
View File

@@ -0,0 +1 @@
DIST pcg-cpp-0.98.1_p20220408.tar.gz 78224 BLAKE2B a2de1ddd297e0f18be1be69d047e77cd53e0278d80818e8431e8a7fe49d4576d72df256a1210afe87f53e3ee65e920b55cba1a461354a118d9d8d794b387b9c0 SHA512 6d952737f61778f1d5c7f6bba0ebc3164e84fc0b1369186cd9c9aa880ec7ab3ea2a7066012c9094bc697a0093fe24d316bf83bd2842eb9433f4533782bb50a39

View File

@@ -0,0 +1,12 @@
Fail test if test failed
https://github.com/imneme/pcg-cpp/pull/100
--- a/test-high/run-tests.sh
+++ b/test-high/run-tests.sh
@@ -94,5 +94,6 @@ else
echo All tests except tests awkward tests with 128-bit math succceed.
else
echo ERROR: Some tests failed.
+ exit 1
fi
fi

View File

@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person" proxied="yes">
<email>alexey+gentoo@asokolov.org</email>
<name>Alexey Sokolov</name>
</maintainer>
<maintainer type="project" proxied="proxy">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<upstream>
<remote-id type="github">mneme/pcg-cpp</remote-id>
<bugs-to>https://github.com/imneme/pcg-cpp/issues</bugs-to>
<doc>https://www.pcg-random.org/using-pcg-cpp.html</doc>
</upstream>
</pkgmetadata>

View File

@@ -0,0 +1,41 @@
# Copyright 2021-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
MY_COMMIT="428802d1a5634f96bcd0705fab379ff0113bcf13"
DESCRIPTION="Family of better random number generators"
HOMEPAGE="https://www.pcg-random.org https://github.com/imneme/pcg-cpp"
SRC_URI="https://github.com/imneme/pcg-cpp/archive/${MY_COMMIT}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/pcg-cpp-${MY_COMMIT}"
LICENSE="|| ( Apache-2.0 MIT )"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="test"
RESTRICT="!test? ( test )"
PATCHES=(
"${FILESDIR}"/pcg-cpp-0.98.1-testerror.patch
)
# header-only library
src_compile() {
tc-export CXX
if use test ; then
cd test-high || die
emake
fi
}
src_test() {
cd test-high || die
sh ./run-tests.sh || die
}
src_install() {
doheader include/*
}