diff options
-rw-r--r-- | dev-libs/msgpack/Manifest | 1 | ||||
-rw-r--r-- | dev-libs/msgpack/msgpack-5.0.0.ebuild | 61 |
2 files changed, 62 insertions, 0 deletions
diff --git a/dev-libs/msgpack/Manifest b/dev-libs/msgpack/Manifest index 5590de8de0f3..4774d20f2102 100644 --- a/dev-libs/msgpack/Manifest +++ b/dev-libs/msgpack/Manifest @@ -1 +1,2 @@ DIST msgpack-3.3.0.tar.gz 508001 BLAKE2B 3017c44689f8afbf078b9c498449e21b4e3b87591c50a37bf9ae73869dab550819f24d6e5179a3600df297aa2c024e5a7fe1defcbab7c0f1aff826870de2ab32 SHA512 ad3e32edc8c6afd70282b3d4b493c2ffe74a697c41bd1f39030c5b4752cccefaa965bc049d4c2e63103a210bf714dc3bddd474691bc067d1475ae017593f55e6 +DIST msgpack-c-5.0.0.tar.gz 69275 BLAKE2B 9c4ebc60387028cba04d5a8f4d97ca3cf6caa3db93fa7da1a90089d63cd58b36a7fb387b4fd5410d0c422719c1aed6d479418d3cbc011b609afb49cf89c4d0e3 SHA512 f61f19c7dcb5ef2a94cd3fb84e9b090e236caa922f590496e6455bd49a3d001021b55d0f28cea3ce3c35558bedb64f2f932c0e107fb15e6efc6855b99cbe4de6 diff --git a/dev-libs/msgpack/msgpack-5.0.0.ebuild b/dev-libs/msgpack/msgpack-5.0.0.ebuild new file mode 100644 index 000000000000..cc6f586a055f --- /dev/null +++ b/dev-libs/msgpack/msgpack-5.0.0.ebuild @@ -0,0 +1,61 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake-multilib + +MY_PN="${PN}-c" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="MessagePack is a binary-based efficient data interchange format" +HOMEPAGE="https://msgpack.org/ https://github.com/msgpack/msgpack-c/" +SRC_URI="https://github.com/${PN}/${PN}-c/releases/download/c-${PV}/${MY_P}.tar.gz" + +LICENSE="Boost-1.0" +SLOT="0/2" +KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86 ~amd64-linux ~x86-linux ~x64-macos" +IUSE="doc examples test" + +RESTRICT="!test? ( test )" + +BDEPEND="doc? ( app-doc/doxygen[dot] ) + test? ( + dev-cpp/gtest[${MULTILIB_USEDEP}] + sys-libs/zlib[${MULTILIB_USEDEP}] + )" + +S="${WORKDIR}"/${MY_P} + +multilib_src_configure() { + local mycmakeargs=( + -DMSGPACK_BUILD_EXAMPLES=OFF + -DMSGPACK_BUILD_TESTS="$(usex test)" + ) + + cmake_src_configure +} + +multilib_src_compile() { + cmake_src_compile + + if multilib_is_native_abi && use doc; then + cmake_build doxygen + fi +} + +multilib_src_install() { + if multilib_is_native_abi; then + if use doc; then + local HTML_DOCS=( "${BUILD_DIR}"/doc_c/html/. ) + fi + + if use examples; then + docinto examples + dodoc -r "${S}"/example/. + docompress -x /usr/share/doc/${PF}/examples + fi + fi + + cmake_src_install +} |