diff options
Diffstat (limited to 'sci-mathematics/alectryon')
-rw-r--r-- | sci-mathematics/alectryon/Manifest | 4 | ||||
-rw-r--r-- | sci-mathematics/alectryon/alectryon-1.4.0.ebuild | 78 | ||||
-rw-r--r-- | sci-mathematics/alectryon/files/50alectryon-gentoo.el | 3 | ||||
-rw-r--r-- | sci-mathematics/alectryon/metadata.xml | 23 |
4 files changed, 108 insertions, 0 deletions
diff --git a/sci-mathematics/alectryon/Manifest b/sci-mathematics/alectryon/Manifest new file mode 100644 index 000000000000..f90615f901e1 --- /dev/null +++ b/sci-mathematics/alectryon/Manifest @@ -0,0 +1,4 @@ +AUX 50alectryon-gentoo.el 155 BLAKE2B 6a83a0b6e7116a85d00b20799004eaec08033845661a23368b3340320184f2ea65c6b23db61664dadf2f829cabeabd8933f7f9e31d0971fcf2a0181c6d8ae956 SHA512 65fb668f29ba4737fc374302536c3223a02d45816a79256e425e255f30c134b19c8e88ccd19c13954a562182ad072cd10de08cd5047ae17b1b72efcfdc78f00f +DIST alectryon-1.4.0.tar.gz 312436 BLAKE2B 7f1e58670fbba0b31a4e4bc6502dffa72931ae3495c38b53987406a05aac9d3d1a34d75c89b7b85a6122ee6a7ce30970f8cf3190a5916e416e56854313077d4c SHA512 1310a04c8584147b38af8edb19cc95bd71043f5d00f55cbf4d5649dad9eede5bd01dba6fb23b85acf7cb9e9619fd01e5f83d8d37064f0b43f706589b9ec8aeef +EBUILD alectryon-1.4.0.ebuild 1729 BLAKE2B 3209721c93c4552278ad968e7a43fcbc0f34025a6ae83ae9cdb24e48303caee56217c76d0e59a383ec06527833979eead8783d1911fed9c45db0fac69bda7e90 SHA512 f3184ed6ccd684f04e2e6cb6b70f2275c139ab29e3f016784f0492e966ac8c16de64c8a8d9059b6f723ab76c506d10d5707cd568c3c58dd10927584210044043 +MISC metadata.xml 977 BLAKE2B 929c655f60171ee97c50a711e5ddaa4f5b6e5c7a2ffa2a2e3ff69665fa46a894af8a353e73efa8e43ed18fa87440e77d6a0d2abe7ecf740dcffe315d9bcddffa SHA512 a88e5341ebe5a4f239e73dbe0d843c46bdcc0f24dfa99e554b57ec715455d2a0526b4a157d2a2a2854b6d7e500b921f81cc29b6ab3c54db8ed228d94807d33fd diff --git a/sci-mathematics/alectryon/alectryon-1.4.0.ebuild b/sci-mathematics/alectryon/alectryon-1.4.0.ebuild new file mode 100644 index 000000000000..bdbf53a0c35b --- /dev/null +++ b/sci-mathematics/alectryon/alectryon-1.4.0.ebuild @@ -0,0 +1,78 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{8..10} ) + +inherit elisp-common distutils-r1 + +DESCRIPTION="Toolkit for literate programming in Coq" +HOMEPAGE="https://github.com/cpitclaudel/alectryon/" + +if [[ "${PV}" == *9999* ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/cpitclaudel/${PN}.git" +else + SRC_URI="https://github.com/cpitclaudel/${PN}/archive/v${PV}.tar.gz + -> ${P}.tar.gz" + KEYWORDS="~amd64" +fi + +LICENSE="MIT" +SLOT="0" +IUSE="doc emacs" + +RDEPEND=" + dev-python/beautifulsoup4[${PYTHON_USEDEP}] + dev-python/docutils[${PYTHON_USEDEP}] + dev-python/dominate[${PYTHON_USEDEP}] + dev-python/myst_parser[${PYTHON_USEDEP}] + dev-python/pygments[${PYTHON_USEDEP}] + dev-python/sphinx[${PYTHON_USEDEP}] + sci-mathematics/coq-serapi +" +DEPEND="${RDEPEND}" +BDEPEND=" + emacs? ( + >=app-editors/emacs-23.1:* + app-emacs/flycheck + app-emacs/proofgeneral + ) +" + +DOCS=( CHANGES.rst CITATION.bib README.rst ) +SITEFILE="50${PN}-gentoo.el" + +src_compile() { + python_foreach_impl distutils-r1_python_compile + + use doc && emake -C ./recipes/sphinx latexpdf + use emacs && elisp-compile ./etc/elisp/alectryon.el +} + +src_install() { + python_foreach_impl distutils-r1_python_install + einstalldocs + + if use doc ; then + docinto html + dodoc ./recipes/sphinx/_build/html/* + docinto pdf + dodoc ./recipes/sphinx/_build/latex/alectryon-demo.pdf + docinto latex + dodoc ./recipes/sphinx/_build/latex/alectryon-demo.tex + fi + if use emacs ; then + elisp-install ${PN} ./etc/elisp/${PN}.el{,c} + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +} diff --git a/sci-mathematics/alectryon/files/50alectryon-gentoo.el b/sci-mathematics/alectryon/files/50alectryon-gentoo.el new file mode 100644 index 000000000000..2d6ca63cdd6d --- /dev/null +++ b/sci-mathematics/alectryon/files/50alectryon-gentoo.el @@ -0,0 +1,3 @@ +(add-to-list 'load-path "@SITELISP@") +(autoload 'alectryon-mode "alectryon" "Mode for Literate Coq files." t) +(add-hook 'coq-mode-hook #'alectryon-mode t) diff --git a/sci-mathematics/alectryon/metadata.xml b/sci-mathematics/alectryon/metadata.xml new file mode 100644 index 000000000000..67c427e81f35 --- /dev/null +++ b/sci-mathematics/alectryon/metadata.xml @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> + +<pkgmetadata> + <maintainer type="project"> + <email>sci-mathematics@gentoo.org</email> + <name>Gentoo Mathematics Project</name> + </maintainer> + <longdescription> + A library to process Coq and Lean snippets embedded in text documents, + showing goals and messages for each input sentence. Also a literate + programming toolkit. The goal of Alectryon is to make it easy to write + textbooks, blog posts, and other documents that mix interactive proofs and + prose. + Alectryon originally supported Coq only. Support for Lean is preliminary + and restricted to Lean 3. + </longdescription> + <upstream> + <changelog>https://github.com/cpitclaudel/alectryon/releases/</changelog> + <bugs-to>https://github.com/cpitclaudel/alectryon/issues/</bugs-to> + <remote-id type="github">cpitclaudel/alectryon</remote-id> + </upstream> +</pkgmetadata> |