commit: 6f924ddc7f364b46b22cf46a6b9b6b05891e89ad Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> AuthorDate: Sun Jan 26 19:01:03 2025 +0000 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> CommitDate: Sun Jan 26 19:01:49 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6f924ddc
dev-lang/c-intercal: add 33.0 Closes: https://bugs.gentoo.org/722862 Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org> dev-lang/c-intercal/Manifest | 1 + dev-lang/c-intercal/c-intercal-33.0.ebuild | 79 ++++++++++++++++++++++++++++++ 2 files changed, 80 insertions(+) diff --git a/dev-lang/c-intercal/Manifest b/dev-lang/c-intercal/Manifest index 0ac55ab591e2..49f925f55357 100644 --- a/dev-lang/c-intercal/Manifest +++ b/dev-lang/c-intercal/Manifest @@ -1 +1,2 @@ DIST intercal-0.31.tar.gz 940950 BLAKE2B 9a23229b1d7f0524b164a4b66bcab4fdf67a04ba1e411365a46a90d646867fe92d6e328935b406673809535a895becde934fb6cf2e8380943eb8f19473fcedab SHA512 ca5c10be880ce2470d7dd3404fa5a314bd7bcab45cf4908f7108eb1baa50339b876e135251d991527881b564027c63dc38d74a154cbd00d606261013d2b01262 +DIST intercal-0.33.tar.gz 960355 BLAKE2B c9d4f0a497865980fe2b8d26f43bf33a6c0ee2fb197c278cbd5b019fb2929310f4f776eeb5538e47de5d10b9410176f9cab403607108f7f0186bd004ce39184a SHA512 8dcd5eceb0b356a130b6a839536129438b17e417c33563ad851e29793755756c81cf3a2a61a90793d0fb59ade8a6928912cfa0471fbae9c61cd9cba0ed849379 diff --git a/dev-lang/c-intercal/c-intercal-33.0.ebuild b/dev-lang/c-intercal/c-intercal-33.0.ebuild new file mode 100644 index 000000000000..3888f0660505 --- /dev/null +++ b/dev-lang/c-intercal/c-intercal-33.0.ebuild @@ -0,0 +1,79 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit elisp-common flag-o-matic + +# C-INTERCAL uses minor-major ordering of version components and +# negative version numbers. We map version components -1, -2, ... +# to 65535, 65534, ..., and subtract one from the next component. +# For example, upstream version 0.28 is mapped to Gentoo version 28.0 +# and 0.-2.0.29 is mapped to 28.65535.65534.0. +#get_intercal_version() { +# local i=.${1:-${PV}} j k c=0 +# while [[ ${i} ]]; do +# (( k = ${i##*.} + c )) +# (( (c = (k >= 32768)) && (k -= 65536) )) +# i=${i%.*} +# j=${j}.${k} +# done +# echo ${j#.} +#} + +MY_P="${PN#c-}-$(ver_cut 2).$(ver_cut 1)" +DESCRIPTION="C-INTERCAL - INTERCAL to binary (via C) compiler" +HOMEPAGE="http://www.catb.org/~esr/intercal/ + https://gitlab.com/esr/intercal" +SRC_URI="http://www.catb.org/~esr/intercal/${MY_P}.tar.gz" +S="${WORKDIR}/${MY_P}" + +LICENSE="GPL-2+ FDL-1.2+" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="emacs examples" + +RDEPEND="emacs? ( >=app-editors/emacs-23.1:* )" +BDEPEND="${RDEPEND} + app-alternatives/lex + app-alternatives/yacc" + +SITEFILE="50${PN}-gentoo.el" + +src_configure() { + # -Werror=lto-type-mismatch + # https://bugs.gentoo.org/855590 + # https://gitlab.com/esr/intercal/-/issues/7 + filter-lto + + append-cflags $(test-flags-CC -fno-toplevel-reorder) #722862 + econf +} + +src_compile() { + emake + + if use emacs; then + elisp-compile etc/intercal.el + fi +} + +src_install() { + emake DESTDIR="${D}" install + dodoc BUGS NEWS HISTORY README doc/THEORY.txt + + if use emacs; then + elisp-install ${PN} etc/intercal.{el,elc} + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi + + use examples && dodoc -r pit +} + +pkg_postinst() { + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +}
