diff options
| author | Alexey Sokolov <alexey+gentoo@asokolov.org> | 2022-09-25 22:30:27 +0100 |
|---|---|---|
| committer | Ionen Wolkens <ionen@gentoo.org> | 2022-09-26 05:34:09 -0400 |
| commit | 9a6d9c1ece3205412ae0e6f3f36777ce7e203138 (patch) | |
| tree | c0b08b8d1e3bdffcd1df609ca405632b3448a043 /dev-cpp/sol2/sol2-3.3.0.ebuild | |
| parent | e6ff55cc55eb7e2b862326965ace1ac5b941c590 (diff) | |
| download | gentoo-9a6d9c1ece3205412ae0e6f3f36777ce7e203138.tar.gz gentoo-9a6d9c1ece3205412ae0e6f3f36777ce7e203138.tar.bz2 gentoo-9a6d9c1ece3205412ae0e6f3f36777ce7e203138.zip | |
dev-cpp/sol2: add 3.3.0
Signed-off-by: Alexey Sokolov <alexey+gentoo@asokolov.org>
Closes: https://bugs.gentoo.org/864169
Closes: https://github.com/gentoo/gentoo/pull/27456
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'dev-cpp/sol2/sol2-3.3.0.ebuild')
| -rw-r--r-- | dev-cpp/sol2/sol2-3.3.0.ebuild | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/dev-cpp/sol2/sol2-3.3.0.ebuild b/dev-cpp/sol2/sol2-3.3.0.ebuild new file mode 100644 index 000000000000..7ee94fefcfe3 --- /dev/null +++ b/dev-cpp/sol2/sol2-3.3.0.ebuild @@ -0,0 +1,71 @@ +# Copyright 2021-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LUA_COMPAT=( lua5-{1,3,4} luajit ) +inherit cmake lua + +DESCRIPTION="Header-only C++ <-> Lua API wrapper" +HOMEPAGE="https://github.com/ThePhD/sol2" +SRC_URI="https://github.com/ThePhD/sol2/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="test" +REQUIRED_USE="${LUA_REQUIRED_USE}" +RESTRICT="!test? ( test )" + +DEPEND=" + ${LUA_DEPS} + test? ( + >=dev-cpp/catch-3 + ) +" +BDEPEND=" + virtual/pkgconfig +" + +PATCHES=( + "${FILESDIR}"/sol2-3.3.0-werror.patch + "${FILESDIR}"/sol2-3.2.2-luajit-pkgconf.patch + "${FILESDIR}"/sol2-3.3.0-catch-depend.patch + "${FILESDIR}"/sol2-3.3.0-cmake-dir.patch + "${FILESDIR}"/sol2-3.3.0-dont-install-tests.patch +) + +src_prepare() { + cmake_src_prepare +} + +src_configure() { + sol2_configure_wrapper() { + local mycmakeargs=( + -DSOL2_BUILD_LUA=no + -DSOL2_TESTS=$(usex test) + -DSOL2_LUA_VERSION="${ELUA}" + ) + cmake_src_configure + } + lua_foreach_impl sol2_configure_wrapper +} + +src_compile() { + lua_foreach_impl cmake_src_compile +} + +src_test() { + sol2_test_wrapper() { + if [[ ${ELUA} == luajit ]]; then + einfo "Skipping test due to https://github.com/ThePhD/sol2/issues/1221" + else + cmake_src_test + fi + } + lua_foreach_impl sol2_test_wrapper +} + +src_install() { + lua_foreach_impl cmake_src_install +} |
