diff options
author | tea <gentoo@tastytea.de> | 2024-06-13 11:56:22 +0200 |
---|---|---|
committer | tea <gentoo@tastytea.de> | 2024-06-13 14:53:42 +0200 |
commit | f288e588abf388c888fb0a2bb094895c62169cfa (patch) | |
tree | 1f5b723bb6f56c384b47885b86a4cb9aaa1316e9 /dev-cpp | |
parent | media-sound/tidal-hifi-bin: drop 5.13.1 (diff) | |
download | guru-f288e588abf388c888fb0a2bb094895c62169cfa.tar.gz guru-f288e588abf388c888fb0a2bb094895c62169cfa.tar.bz2 guru-f288e588abf388c888fb0a2bb094895c62169cfa.zip |
dev-cpp/coeurl: add 0.3.1
Signed-off-by: tea <gentoo@tastytea.de>
Diffstat (limited to 'dev-cpp')
-rw-r--r-- | dev-cpp/coeurl/Manifest | 1 | ||||
-rw-r--r-- | dev-cpp/coeurl/coeurl-0.3.1.ebuild | 68 |
2 files changed, 69 insertions, 0 deletions
diff --git a/dev-cpp/coeurl/Manifest b/dev-cpp/coeurl/Manifest index 44b25fd17..017cdcaed 100644 --- a/dev-cpp/coeurl/Manifest +++ b/dev-cpp/coeurl/Manifest @@ -1,2 +1,3 @@ DIST coeurl-0.2.1.tar.bz2 45784 BLAKE2B e1280478d6112171e387d88f10ef220ac839e9be3b222c60111f0e046b00161f29561fce5bc62cc806bd0188fa2ad64f54d016e04e53af9032e69b6cc8dd4153 SHA512 0e65c1120eb352d75976a2b1f11a83dea4e6557276b22962c37e6387bf649ad18117f6f4b4b1b76d4cce2ef53d55834aacf7207e7c15e015344f3c4a60a49671 DIST coeurl-0.3.0.tar.bz2 46292 BLAKE2B e00e70da3759fa6479d703af8bb520e96f41cbfdd9dc35c2b982f12ca9d596516283d56749785c6862e081b832a29a8453a3a57251c4c968724ed20ccf98d080 SHA512 4ad5a279689ad360f7b33f110e3bf174578655ab036405789d43bcbc73f775c51ab69cb20e79e1229ba045414a2d46e97869a0cd62b978e518cdf23a86b0a846 +DIST coeurl-0.3.1.tar.bz2 46513 BLAKE2B 8a80ece8449ced486c56114fba1c544eebc25d165daac630c5d1f3af6d8c4dfd96361afc51d3d4f92fabeff0cdc61dcea9a068c915b3dbd8cc6e7a8bf3baf0a7 SHA512 d9369162ef75a40cafaec88e6b32b6a28daf293691ca017b97b0e4900ae6960f4956124cb8b9ebc3659e174dd55c51441225e212e5c1dbad88413a71faa8c718 diff --git a/dev-cpp/coeurl/coeurl-0.3.1.ebuild b/dev-cpp/coeurl/coeurl-0.3.1.ebuild new file mode 100644 index 000000000..4bb84e477 --- /dev/null +++ b/dev-cpp/coeurl/coeurl-0.3.1.ebuild @@ -0,0 +1,68 @@ +# Copyright 2021-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +inherit edo meson python-any-r1 + +DESCRIPTION="A simple async wrapper around CURL for C++" +HOMEPAGE="https://nheko.im/nheko-reborn/coeurl" +SRC_URI="https://nheko.im/nheko-reborn/coeurl/-/archive/v${PV}/${PN}-v${PV}.tar.bz2 -> ${P}.tar.bz2" +S="${WORKDIR}/${PN}-v${PV}" + +LICENSE="MIT" +SLOT="0/$(ver_cut 1-2)" +KEYWORDS="~amd64" +IUSE="ssl test" +REQUIRED_USE="test? ( ssl )" +RESTRICT="!test? ( test )" + +RDEPEND=" + net-misc/curl[ssl?] + dev-libs/libevent:= + dev-libs/libfmt:= + dev-libs/spdlog:= +" +DEPEND=" + ${RDEPEND} + test? ( dev-cpp/doctest ) +" +BDEPEND=" + test? ( + dev-libs/openssl + $(python_gen_any_dep 'dev-python/flask[${PYTHON_USEDEP}]') + ) +" + +python_check_deps() { + use test || return 0 # python is only used for tests, bug #911504 + + python_has_version "dev-python/flask[${PYTHON_USEDEP}]" +} + +src_prepare() { + default + rm -r subprojects || die +} + +src_configure() { + local -a emesonargs=( + $(meson_use test tests) + ) + meson_src_configure +} + +src_test() { + openssl req -x509 -newkey rsa:4096 -nodes \ + -out "${T}"/cert.pem -keyout "${T}"/key.pem \ + -days 365 -subj "/CN=localhost" || die + + edo ${EPYTHON} ./tests/testserver.py & + sleep 3 + + edo ${EPYTHON} ./tests/testserver.py "${T}" & + sleep 3 + + meson_src_test +} |