diff options
author | Maciej Barć <xgqt@gentoo.org> | 2022-11-18 23:13:11 +0100 |
---|---|---|
committer | Maciej Barć <xgqt@gentoo.org> | 2022-11-18 23:15:13 +0100 |
commit | 9f378b9a170e462527b9d6580df1f653a7ab15e1 (patch) | |
tree | 5fe7c0a776aa53f91609d90e1127b7853ee0ffbe /sci-mathematics/lean/lean-3.49.1.ebuild | |
parent | dev-ml/re: drop seq requirement (diff) | |
download | gentoo-9f378b9a170e462527b9d6580df1f653a7ab15e1.tar.gz gentoo-9f378b9a170e462527b9d6580df1f653a7ab15e1.tar.bz2 gentoo-9f378b9a170e462527b9d6580df1f653a7ab15e1.zip |
sci-mathematics/lean: bump to 3.49.1
Signed-off-by: Maciej Barć <xgqt@gentoo.org>
Diffstat (limited to 'sci-mathematics/lean/lean-3.49.1.ebuild')
-rw-r--r-- | sci-mathematics/lean/lean-3.49.1.ebuild | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/sci-mathematics/lean/lean-3.49.1.ebuild b/sci-mathematics/lean/lean-3.49.1.ebuild new file mode 100644 index 000000000000..e008b81cf582 --- /dev/null +++ b/sci-mathematics/lean/lean-3.49.1.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +MAJOR=$(ver_cut 1) +CMAKE_IN_SOURCE_BUILD="ON" + +inherit flag-o-matic cmake readme.gentoo-r1 + +DESCRIPTION="The Lean Theorem Prover" +HOMEPAGE="https://leanprover-community.github.io/" + +if [[ ${PV} == *9999* ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/leanprover-community/lean.git" +else + SRC_URI="https://github.com/leanprover-community/lean/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi +S="${S}/src" + +LICENSE="Apache-2.0" +SLOT="0/${MAJOR}" +IUSE="debug +threads" + +RDEPEND="dev-libs/gmp:=" +DEPEND="${RDEPEND}" + +PATCHES=( "${FILESDIR}"/${PN}-CMakeLists-fix_flags.patch ) + +src_configure() { + local CMAKE_BUILD_TYPE + if use debug; then + CMAKE_BUILD_TYPE="Debug" + else + CMAKE_BUILD_TYPE="Release" + fi + + filter-lto + + local mycmakeargs=( + -DALPHA=ON + -DAUTO_THREAD_FINALIZATION=ON + -DJSON=ON # bug 833900 + -DLEAN_EXTRA_CXX_FLAGS="${CXXFLAGS}" + -DMULTI_THREAD=$(usex threads) + -DUSE_GITHASH=OFF + ) + cmake_src_configure +} + +src_test() { + local myctestargs=( + # Disable problematic "style_check" cpplint test, + # this also removes the python test dependency + --exclude-regex style_check + ) + cmake_src_test +} + +src_install() { + cmake_src_install + + local DISABLE_AUTOFORMATTING="yes" + local DOC_CONTENTS="You probably want to use lean with mathlib, you can either: + - Do not install mathlib globally and use local versions + - Use leanproject from sci-mathematics/mathlib-tools + $ leanproject global-install + - Use leanpkg and compile mathlib (which will take some time) + $ leanpkg install https://github.com/leanprover-community/mathlib" + readme.gentoo_create_doc +} + +pkg_postinst() { + readme.gentoo_print_elog +} |