diff options
author | V3n3RiX <venerix@koprulu.sector> | 2023-04-13 23:44:17 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2023-04-13 23:44:17 +0100 |
commit | fdca6388cf31827202fae75cae067c695bd09339 (patch) | |
tree | 5021150295c139ea6a808950a9e1928b8ef593b8 /sci-mathematics/opensmt/opensmt-2.4.3-r2.ebuild | |
parent | b43fb9ec552fc1a84599161478d77c6716dd9e0a (diff) |
gentoo auto-resync : 13:04:2023 - 23:44:17
Diffstat (limited to 'sci-mathematics/opensmt/opensmt-2.4.3-r2.ebuild')
-rw-r--r-- | sci-mathematics/opensmt/opensmt-2.4.3-r2.ebuild | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/sci-mathematics/opensmt/opensmt-2.4.3-r2.ebuild b/sci-mathematics/opensmt/opensmt-2.4.3-r2.ebuild new file mode 100644 index 000000000000..f46f590a012c --- /dev/null +++ b/sci-mathematics/opensmt/opensmt-2.4.3-r2.ebuild @@ -0,0 +1,71 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +DESCRIPTION="Compact and open-source SMT-solver written in C++" +HOMEPAGE="http://verify.inf.usi.ch/opensmt/ + https://github.com/usi-verification-and-security/opensmt/" + +if [[ ${PV} == *9999* ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/usi-verification-and-security/${PN}.git" +else + SRC_URI="https://github.com/usi-verification-and-security/${PN}/archive/v${PV}.tar.gz + -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi + +LICENSE="MIT" +SLOT="0/${PV}" +IUSE="debug libedit +readline test" +REQUIRED_USE="?? ( libedit readline )" +RESTRICT="!test? ( test )" + +RDEPEND=" + dev-libs/gmp:=[cxx] + readline? ( sys-libs/readline:= ) + libedit? ( dev-libs/libedit:= ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + sys-devel/bison + sys-devel/flex + test? ( dev-cpp/gtest ) +" + +PATCHES=( "${FILESDIR}"/${P}-musl.patch ) + +src_prepare() { + cmake_src_prepare + + echo "add_subdirectory(unit)" > "${S}"/test/CMakeLists.txt || die +} + +src_configure() { + local CMAKE_BUILD_TYPE + if use debug ; then + CMAKE_BUILD_TYPE=Debug + else + CMAKE_BUILD_TYPE=Release + fi + + local -a mycmakeargs=( + -DPACKAGE_TESTS=$(usex test) + -DUSE_READLINE=$(usex readline) + ) + if use readline || use libedit ; then + mycmakeargs+=( -DENABLE_LINE_EDITING=ON ) + fi + cmake_src_configure +} + +src_install() { + cmake_src_install + + rm "${ED}"/usr/lib/libopensmt.a || die + dodir /usr/$(get_libdir) + mv "${ED}"/usr/lib/libopensmt.* "${ED}"/usr/$(get_libdir)/ || die +} |