dev-lang/dafny: add verison 3.3.0

Package-Manager: Portage-3.0.20, Repoman-3.0.3
Signed-off-by: Maciej Barć <xgqt@riseup.net>
This commit is contained in:
Maciej Barć 2021-10-26 08:32:52 +02:00
parent 3041a15bfd
commit 83e700cc02
No known key found for this signature in database
GPG Key ID: 031C9FE65BED714A
3 changed files with 88 additions and 0 deletions

1
dev-lang/dafny/Manifest Normal file
View File

@ -0,0 +1 @@
DIST dafny-3.3.0.tar.gz 3413584 BLAKE2B 5d9cd2da9559cbc5584fe9c6dccf0773ba7b981f3708dc8695907243d647e34ad43ed89fb64a95f9b646209d5f963ca0dd287764d3b7ae89335c8fbb50091eac SHA512 1a9af37a1826176f369e1c732e561bfa1e10a5b1fe7c0b61d7e64754052b806f776e70c40080c93cde4a47a7cb9f9e208899d77be88104606d833f77abd160ab

View File

@ -0,0 +1,69 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DOTNET="5.0"
DESCRIPTION="Verification-aware programming language"
HOMEPAGE="https://dafny-lang.github.io/dafny/"
if [[ "${PV}" == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/dafny-lang/${PN}.git"
else
SRC_URI="https://github.com/dafny-lang/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64"
fi
# TODO: src_test
RESTRICT="network-sandbox test"
LICENSE="MIT"
SLOT="0"
IUSE="debug"
# TODO: add dev-java/gradle when available
BDEPEND="
dev-java/gradle-bin
"
DEPEND="
>=virtual/jdk-1.8.0:*
virtual/dotnet-sdk:${DOTNET}
"
RDEPEND="
${DEPEND}
sci-mathematics/z3
"
DAFNY_EXES="
usr/share/dafny/Dafny
usr/share/dafny/DafnyLanguageServer
usr/share/dafny/DafnyServer
"
QA_PREBUILT="${DAFNY_EXES}"
src_compile() {
local configuration
if use debug; then
configuration="Debug"
else
configuration="Release"
fi
dotnet build --configuration "${configuration}" ./Source/Dafny.sln ||
die "dotnet build failed"
}
src_install() {
insinto /usr/share/${PN}
doins -r ./Binaries/net${DOTNET}/*
local exe
for exe in ${DAFNY_EXES}; do
# fix permissions (make executable)
fperms +x "/${exe}"
# create symlinks to bin (also convert to a lowercase name)
dosym "../../${exe}" "/usr/bin/$(basename "${exe,,}")"
done
}

View File

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>xgqt@riseup.net</email>
<name>Maciej Barć</name>
</maintainer>
<longdescription lang="en">
Dafny is a programming language with a program verifier.
As you type in your program, the verifier constantly
looks over your shoulders and flags any errors.
</longdescription>
<upstream>
<bugs-to>https://github.com/dafny-lang/dafny</bugs-to>
<remote-id type="github">dafny-lang/dafny</remote-id>
</upstream>
</pkgmetadata>