summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2017-02-15 22:20:01 +0000
committerSergei Trofimovich <slyfox@gentoo.org>2017-02-16 10:21:24 +0000
commit3351557e82e54d622248b2679384b7885d0236cc (patch)
tree44307e2cb72ace64fad09689545d20e8acf07cb0 /sci-mathematics
parentsci-mathematics/agda: bump up to 2.5.2 (diff)
downloadgentoo-3351557e82e54d622248b2679384b7885d0236cc.tar.gz
gentoo-3351557e82e54d622248b2679384b7885d0236cc.tar.bz2
gentoo-3351557e82e54d622248b2679384b7885d0236cc.zip
sci-mathematics/agda-stdlib: bump up to 2.5.2.0.13
Package-Manager: Portage-2.3.3, Repoman-2.3.1
Diffstat (limited to 'sci-mathematics')
-rw-r--r--sci-mathematics/agda-stdlib/Manifest1
-rw-r--r--sci-mathematics/agda-stdlib/agda-stdlib-2.5.2.0.13.ebuild69
2 files changed, 70 insertions, 0 deletions
diff --git a/sci-mathematics/agda-stdlib/Manifest b/sci-mathematics/agda-stdlib/Manifest
index 020b3fa7ab5..ec9f8d6bebd 100644
--- a/sci-mathematics/agda-stdlib/Manifest
+++ b/sci-mathematics/agda-stdlib/Manifest
@@ -1 +1,2 @@
DIST agda-stdlib-2.4.2.5.tar.gz 253379 SHA256 9b46956e88a886cd08a8e6e83bea6115844860d7e927279abacc52e84b302b16 SHA512 b15ed5838916240c8602fe7a4bccddf43c71ab3a18ecb5a6dc85199b908e261b04cf794a4d93c90af0a9263a36603c392280639ace7fecead0c39269c2623302 WHIRLPOOL 6414b268a813309e7315d6e2ff9345efdb95d1559966f8755607045a685d4b7cf521750ac7efa8dd90001357d7c825d31589dfd2fe771d379f45d79739c7d66c
+DIST agda-stdlib-2.5.2.0.13.tar.gz 264701 SHA256 e7cffc2b8b168c3584b6d1e760d2b49850835444e4777caa69eb29b3677ef8bb SHA512 340a7b9cb15793cdbe99f558a32eaab3476b94b4d43d45bdc92c6b368197d075c977fd2f6ce0c5b0baf584289a2218b07dd030ad2b83f6d9e4bc7effee91eece WHIRLPOOL 9e888be7ef5e09d678f64b487cff457381d417db475e7445b47afb415b80fcd0d3cbef756d9a13de22d704c243d7222429d3fcf1e9cd28776b0a54f7d278b0d0
diff --git a/sci-mathematics/agda-stdlib/agda-stdlib-2.5.2.0.13.ebuild b/sci-mathematics/agda-stdlib/agda-stdlib-2.5.2.0.13.ebuild
new file mode 100644
index 00000000000..81412d99179
--- /dev/null
+++ b/sci-mathematics/agda-stdlib/agda-stdlib-2.5.2.0.13.ebuild
@@ -0,0 +1,69 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+CABAL_FEATURES="bin"
+inherit haskell-cabal elisp-common
+
+## shared with sci-mathematics/agda
+# upstream does not maintain version ordering:
+# https://github.com/agda/agda-stdlib/releases
+# 0.11 -> 2.5.0.20160213 -> 2.5.0.20160412 -> 0.12 -> 0.13
+# As Agda-stdlib is tied to Agda version we encode
+# both versions in gentoo version.
+##
+MY_UPSTREAM_AGDA_STDLIB_V="0.13"
+MY_GENTOO_AGDA_STDLIB_V="${PV}.${MY_UPSTREAM_AGDA_STDLIB_V}"
+MY_UPSTREAM_AGDA_V="${PV%.${MY_UPSTREAM_AGDA_STDLIB_V}}"
+
+DESCRIPTION="Agda standard library"
+HOMEPAGE="http://wiki.portal.chalmers.se/agda/"
+SRC_URI="https://github.com/agda/${PN}/archive/v${MY_UPSTREAM_AGDA_STDLIB_V}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="profile +ffi"
+
+RDEPEND=">=sci-mathematics/agda-${MY_UPSTREAM_AGDA_V}:=[profile?]
+ ffi? ( sci-mathematics/agda-lib-ffi )
+"
+DEPEND="${RDEPEND}
+ >=dev-haskell/cabal-1.16.0
+ >=dev-haskell/filemanip-0.3.6.2[profile?] <dev-haskell/filemanip-0.4[profile?]
+ >=dev-lang/ghc-7.6.3
+"
+
+S=${WORKDIR}/${PN}-${MY_UPSTREAM_AGDA_STDLIB_V}
+
+src_compile() {
+ haskell-cabal_src_compile
+ "${S}"/dist/build/GenerateEverything/GenerateEverything \
+ || die "GenerateEverything failed"
+ local prof
+ use profile && prof="--ghc-flag=-prof"
+ agda +RTS -K1G -RTS ${prof} \
+ -i "${S}" -i "${S}"/src "${S}"/Everything.agda || die
+ # Although my agda-9999 build has
+ # /var/tmp/portage/sci-mathematics/agda-9999/work/agda-9999/dist/build/autogen/Paths_Agda.hs
+ # containing:
+ # datadir = "/usr/share/agda-9999/ghc-7.6.1"
+ # it fails without the --css option like:
+ # /usr/share/agda-9999/ghc-7.4.1/Agda.css: copyFile: does not exist
+ local cssdir=$(egrep 'datadir *=' "${S}/dist/build/autogen/Paths_lib.hs" | sed -e 's@datadir = \(.*\)@\1@')
+ agda --html -i "${S}" -i "${S}"/src --css="${cssdir}/Agda.css" "${S}"/README.agda || die
+}
+
+src_test() {
+ agda -i "${S}" -i "${S}"/src README.agda || die
+}
+
+src_install() {
+ insinto usr/share/agda-stdlib
+ insopts --preserve-timestamps
+ doins -r src/*
+ dodoc -r html/*
+ doins "${FILESDIR}/standard-library.agda-lib"
+}