summaryrefslogtreecommitdiff
path: root/sci-mathematics/stp
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-06-28 07:59:59 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-06-28 07:59:59 +0100
commitb8325835c82367d22428eb41afa0f2d375338d3c (patch)
treec416b8853bd14fc346da5d0129843cc4a68a30a0 /sci-mathematics/stp
parentd2ed973482fdd800013658e83a61709b29e0a80f (diff)
gentoo auto-resync : 28:06:2024 - 07:59:59
Diffstat (limited to 'sci-mathematics/stp')
-rw-r--r--sci-mathematics/stp/Manifest4
-rw-r--r--sci-mathematics/stp/files/stp-2.3.4-gtest.patch26
-rw-r--r--sci-mathematics/stp/files/stp-2.3.4-lit-cfg.patch24
-rw-r--r--sci-mathematics/stp/stp-2.3.4.ebuild109
4 files changed, 163 insertions, 0 deletions
diff --git a/sci-mathematics/stp/Manifest b/sci-mathematics/stp/Manifest
index d7e50d42d770..eed3f58e0f73 100644
--- a/sci-mathematics/stp/Manifest
+++ b/sci-mathematics/stp/Manifest
@@ -1,8 +1,12 @@
AUX stp-2.3.3-CMakeLists.txt-fix_cflags.patch 721 BLAKE2B 31f116d43270558ee88b3cde1cb6303ee35a0078ca7c1be805260a405d5932068609918d711e3c6f3ec0e01e468c0647e1b2b392311e9408a7959736c86cf720 SHA512 1b5f2e9592f178ba31797da152e960c2a78ecf37dae2737f122f6becf16b0235e515129119b176fb5439e77597ab3d5c5f910bb764e13740922bc395a3fab17b
AUX stp-2.3.3-cstdint.patch 275 BLAKE2B 9343de9e9e4eeed85b2d8e61ccd1ab04fc8b0b7af29a2e54fb047e61ee9552cf06043d1fd80b4685ac6095615b8c5a5b5991c31cf207daebe442cbfd44352320 SHA512 91cdf2814b13bf73450aff6adaf0daf9a38ba0712046b808555da9817ac64a346f4e3fcb33b0c1c78ad49a2b5fe964c04966e154b269a1f323e59772b91ca6fb
AUX stp-2.3.3-stp.py-library_path.patch 372 BLAKE2B 1e36f48d2c403cdea156157826a1b3c3e424dc864bf87b30c66d13deadacc25479aaca2c44f89773c20c7ec48b49ce0c65e642e46a8ea22bd5c4695fe15ae86f SHA512 d5feaf02395d90fdba997aebbf582d764e9c238cce4300caba4316b60a1164cc3ce11e8756dd341dc6e3bc53a153fedac4c322776ca5d5b951eaf3a997456973
+AUX stp-2.3.4-gtest.patch 1077 BLAKE2B 338ba55fc5f5f4dba866585dfa6c72eac2b7364a442e3790c774e1cad6c6101f71c0baa807fa366e5479edcd69db737f9b5fd91cffc917ca7cee5967c3d6680c SHA512 f759aeb1701c16190e9808f6f116deb79280bc7a6c1becb0c37b1253a85189a5862ce36dd4da9c73d7ad4e0359c7444bff9e1d0ac70758323d5e927cc9350aca
+AUX stp-2.3.4-lit-cfg.patch 871 BLAKE2B d784973495a76d01fe1b3a69ba1cc0aa4511dcca43f19cf82e0a310f95e20f2834cee2c97b6b050f74561d625561c6f9e2671af845436f290b2ee34ac79712fa SHA512 73769c1a42dcc2906283aa3e8684155c1757fd5c7c8ef349822350c1ffa17f9858eea0a36e43eda354b886f22a9a79b18a592133438fac361035a44f961ec0f9
DIST stp-2.3.3.tar.gz 2577550 BLAKE2B 9ebedf3cb8e6b50d037cfacbc14826bd4e6505d29a53b1fcc6580749f0637fe5f96619c166babdb3a52b18fb6337e49c02f5693e233effe84d0131d0e7402381 SHA512 a0b1bf419d8230e40ce0aee90d9c8c9d814aca300831c24b3576c75623362942abf20673c419f9f0ea1e0505bfae000dc65fdd818179f5759879b0b255f1b99a
DIST stp-2.3.3_OutputCheck.tar.gz 12002 BLAKE2B f8fafba8f7957f3d0ee480b9e1e8c8923c373cf134512d6329adf84a96f3177ad07d00eae4dc6dd8d4b09ca82dfc8b425602f1926e3f88ccb2556b4b7121e5b9 SHA512 36012ae2b2aee1ff3f36ba1678a4bcbfeb590e01c2042ca35eb2f49b6a890b767c1809d1415e7b03f2118204361f834ad9caf70319b59fd14b2c140bf858d16e
DIST stp-2.3.3_gtest.tar.gz 469100 BLAKE2B 386444657d3f23e54f01dac8e0ac36da4d97c3eebcc8cf79bfc754c474a5ed64765a0ad389fef358667e468469c47d02a407e13e6882d426a4defb0102e4a758 SHA512 2fc79fe9c8a4e0487e7e76db9508fd2207df0cfe3940a51aeac32e4440afab9e265bfe553b1cd66086cd5a574d8bf99dbb9e1d9c4a70fafd7b31f38825914aa1
+DIST stp-2.3.4.tar.gz 3543794 BLAKE2B 94813f76db3f1ba5ccdd226d5013c470ea0e265ffccc53050d49b1f7bd09bac87f1baf7d49325b106fd9a2bf934e78e879f58c913685176bcebf0f92a9b70168 SHA512 d4355698cd2d96199bd548d996f0c50788c0329b20e79ea0dd4d9e04b48417850041205d7d9efa342f8a362d203d434ec25aa22649f650f658acac2bfadb3ecf
EBUILD stp-2.3.3-r3.ebuild 2672 BLAKE2B da4e83f06666631b8273f40616b1de06b11a3b3fd34f810cfe5c8d8d1f9f6b6aab53748e7a9bb550e22b6bda2db47deb4b7582a6897f0f5419d509af42984016 SHA512 aeb87a19f5c125d90f0ca8c54f80f3c7e87f4a991ea9b0aef1b5350aaf49c2db715a5ca4253d575e4a73c376867c92e5c547f141e6852afefd57fd7dbe7c3cbf
+EBUILD stp-2.3.4.ebuild 2282 BLAKE2B b0fb4c62113bcbd53d3d7bfae0ed94cb311c2d77caca335333e84baaf14cc7724cdf6e5fbb27357637c4f2b46333f57f58950820005617d37d4d15dc8d4f0c29 SHA512 59a8e7fd18b3a887ca345961e4f80d55e874b3d8184b58523e7ce57000661aeccde2568a7a47e1ac980e82dd1d22e21c85270437b7798a8f9c35c194546d3019
MISC metadata.xml 1110 BLAKE2B e13b9420b7f730e6b9e2571e3f4e8a48cf7f54b16fa767fce48099549071c4c819e16a5da25b6779c77a5a7a7f21c3ec61eeb2719867f874a1c4fa21b84e32f2 SHA512 aa3ddfd8d3bf4647f230f0ca55b6f70f9f82f2ae63fe21edad637397fb1bd2779241a2e439a48bed59bd1de11ef3b4e275731c6a90873ec5d86bb5897bf2a9f0
diff --git a/sci-mathematics/stp/files/stp-2.3.4-gtest.patch b/sci-mathematics/stp/files/stp-2.3.4-gtest.patch
new file mode 100644
index 000000000000..25fb88b87ea9
--- /dev/null
+++ b/sci-mathematics/stp/files/stp-2.3.4-gtest.patch
@@ -0,0 +1,26 @@
+--- a/tests/CMakeLists.txt
++++ b/tests/CMakeLists.txt
+@@ -55,10 +55,7 @@ set(LIT_ARGS -s CACHE STRING "Arguments to pass to lit")
+ # the location of GTest source code is probably error prone so using a copy in the
+ # repository seems like the easiest thing to do. This also has the added benefit that
+ # everyone uses the same version of GTest.
+-set(GTEST_PREFIX ${PROJECT_SOURCE_DIR}/deps/gtest)
+-if (NOT EXISTS "${GTEST_PREFIX}/CMakeLists.txt")
+- message(FATAL_ERROR "Could not find GTest. Did you run scripts/deps/setup-gtest.sh?")
+-endif()
++find_package(GTest REQUIRED)
+
+ if (MSVC)
+ # STP is built with the shared version of the CRT, gtest defaults to the
+@@ -68,11 +65,8 @@ endif()
+
+ set(PREV_CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-format-nonliteral -Wno-missing-field-initializers")
+-add_subdirectory(${GTEST_PREFIX} gtest)
+ set(CMAKE_CXX_FLAGS "${PREV_CMAKE_CXX_FLAGS}")
+-set(GTEST_BOTH_LIBRARIES gtest gtest_main)
+
+-include_directories(${GTEST_PREFIX}/include)
+
+ # Add handy macros/functions
+ include(AddSTPGTest)
diff --git a/sci-mathematics/stp/files/stp-2.3.4-lit-cfg.patch b/sci-mathematics/stp/files/stp-2.3.4-lit-cfg.patch
new file mode 100644
index 000000000000..34f92feb28c9
--- /dev/null
+++ b/sci-mathematics/stp/files/stp-2.3.4-lit-cfg.patch
@@ -0,0 +1,24 @@
+--- a/tests/query-files/lit.cfg
++++ b/tests/query-files/lit.cfg
+@@ -6,6 +6,7 @@ import os
+ import sys
+ import re
+ import platform
++import shutil
+
+ import lit.util
+ import lit.formats
+@@ -107,12 +108,7 @@ lit_config.note('Using solver: {solver}\n'.format(solver=solverExecutable))
+ config.substitutions.append( ('%solver', solverExecutable) )
+
+ # Find OutputCheck
+-OutputCheckTool = os.path.join( os.path.dirname( os.path.dirname( config.test_source_root ) ),
+- 'deps',
+- 'OutputCheck',
+- 'bin',
+- 'OutputCheck'
+- )
++OutputCheckTool = shutil.which("OutputCheck")
+ if not os.path.exists(OutputCheckTool):
+ lit_config.fatal('Cannot find OutputCheck executable: {OutputCheck}'.format(OutputCheck=OutputCheckTool))
+
diff --git a/sci-mathematics/stp/stp-2.3.4.ebuild b/sci-mathematics/stp/stp-2.3.4.ebuild
new file mode 100644
index 000000000000..ab1cbf96c2d2
--- /dev/null
+++ b/sci-mathematics/stp/stp-2.3.4.ebuild
@@ -0,0 +1,109 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..13} )
+
+inherit flag-o-matic python-single-r1 cmake
+
+DESCRIPTION="Simple Theorem Prover, an efficient SMT solver for bitvectors"
+HOMEPAGE="https://stp.github.io/
+ https://github.com/stp/stp/"
+
+if [[ "${PV}" == *9999* ]] ; then
+ inherit git-r3
+
+ EGIT_REPO_URI="https://github.com/stp/stp.git"
+else
+ SRC_URI="https://github.com/stp/stp/archive/${PV}.tar.gz
+ -> ${P}.tar.gz"
+
+ KEYWORDS="~amd64 ~x86"
+fi
+
+LICENSE="GPL-2+ MIT"
+SLOT="0/${PV}"
+IUSE="cryptominisat debug +python test"
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} ) test? ( python )"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ dev-libs/boost:=
+ sci-mathematics/minisat:=
+ sys-libs/zlib:=
+ cryptominisat? (
+ dev-db/sqlite:3
+ dev-libs/icu:=
+ sci-mathematics/cryptominisat:=
+ )
+ python? (
+ ${PYTHON_DEPS}
+ )
+"
+DEPEND="
+ ${RDEPEND}
+"
+BDEPEND="
+ sys-apps/help2man
+ test? (
+ dev-cpp/gtest
+ dev-python/OutputCheck
+ dev-python/lit
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-2.3.3-CMakeLists.txt-fix_cflags.patch"
+ "${FILESDIR}/${PN}-2.3.3-stp.py-library_path.patch"
+ "${FILESDIR}/${PN}-2.3.4-gtest.patch"
+ "${FILESDIR}/${PN}-2.3.4-lit-cfg.patch"
+)
+
+pkg_setup() {
+ if use python ; then
+ python-single-r1_pkg_setup
+ fi
+}
+
+src_configure() {
+ # -Werror=odr warnings, bug #863263
+ filter-lto
+
+ local CMAKE_BUILD_TYPE
+ if use debug ; then
+ CMAKE_BUILD_TYPE="Debug"
+ else
+ CMAKE_BUILD_TYPE="Release"
+ fi
+
+ local -a mycmakeargs=(
+ # -DGTEST_PREFIX="${BROOT}/usr/$(get_libdir)/cmake/GTest"
+
+ -DTEST_C_API=OFF # C API test fail
+ -DUSE_RISS=OFF
+
+ # Cryptominisat switches
+ -DNOCRYPTOMINISAT=$(usex cryptominisat 'OFF' 'ON') # double negation
+ -DFORCE_CMS=$(usex cryptominisat)
+
+ -DENABLE_PYTHON_INTERFACE=$(usex python)
+ -DENABLE_ASSERTIONS=$(usex test)
+ -DENABLE_TESTING=$(usex test)
+ )
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+
+ # Because Python files for tests (in BUILD_DIR) and those installed on the
+ # system differ, and are generated upon install, we have to wait for CMake
+ # to install them into the temporary image.
+ if use python ; then
+ python_optimize "${D}/$(python_get_sitedir)/stp"
+ fi
+
+ mv "${D}/usr/man" "${D}/usr/share/man" || die
+ dodoc -r papers
+}