aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>2023-06-15 21:11:43 +0200
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>2023-06-15 21:12:05 +0200
commit31510b33b14fb9553bb7125e9fd36de5db5964ed (patch)
tree5745a7d3e70e409453b2318fa6aaddd1adb8f76f /dev-lang
parentdev-lang/harec: add 0_pre20230611 (diff)
downloadguru-31510b33b14fb9553bb7125e9fd36de5db5964ed.tar.gz
guru-31510b33b14fb9553bb7125e9fd36de5db5964ed.tar.bz2
guru-31510b33b14fb9553bb7125e9fd36de5db5964ed.zip
dev-lang/hare: add 0_pre20230615
Signed-off-by: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/hare/Manifest1
-rw-r--r--dev-lang/hare/hare-0_pre20230615.ebuild57
2 files changed, 58 insertions, 0 deletions
diff --git a/dev-lang/hare/Manifest b/dev-lang/hare/Manifest
index c4ef64eec..f60decb06 100644
--- a/dev-lang/hare/Manifest
+++ b/dev-lang/hare/Manifest
@@ -1 +1,2 @@
+DIST hare-0cf443bbfb121fbf04d0d138161b6073a088bef9.tar.gz 725094 BLAKE2B 4ba04e73a70b4257dd8448a6a899058422bc0492f8f5598a1f705e4164a82a4e348f3877de710c17f2aebe909893d5d271242eb987dba37233a86fb881464f8c SHA512 9ac6322713366d7a7fa41ce86584e045a274c7a4b2389d96fe47d18133b233cc0a9f4ed41f2ed4c64f8d8e9601ed0dbe2cda6d89204e1add42f3f8a5a2688e94
DIST hare-464ec7a660b12ab1ef8e4dcc9d00604cec996c6e.tar.gz 699656 BLAKE2B cacf3a229abfad6c3c43c1d590f8bfcd37bb0617fd27d2c293a137723dd47d7d51f9a08157d8b056932cf83d4539817c850a2a0761ce4d1bed842683d20369be SHA512 0c5d7416b9a28227e376e1b8ed8fd0c19e6646738bed8b334bf5ad2837d10b03b11a7c842e8eee04b28faf62cc1042cd99bcdc8b8d65e92f27a4eb5ad8076be2
diff --git a/dev-lang/hare/hare-0_pre20230615.ebuild b/dev-lang/hare/hare-0_pre20230615.ebuild
new file mode 100644
index 000000000..08ab7b2e4
--- /dev/null
+++ b/dev-lang/hare/hare-0_pre20230615.ebuild
@@ -0,0 +1,57 @@
+# Copyright 2021-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+if [[ "${PV}" = 9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://git.sr.ht/~sircmpwn/hare"
+ SLOT="0"
+else
+ EGIT_COMMIT="0cf443bbfb121fbf04d0d138161b6073a088bef9"
+ MY_P="${PN}-${EGIT_COMMIT}"
+ SRC_URI="https://git.sr.ht/~sircmpwn/hare/archive/${EGIT_COMMIT}.tar.gz -> ${MY_P}.tar.gz"
+ S="${WORKDIR}/${MY_P}"
+ SLOT="0/${PV}"
+
+ KEYWORDS="~amd64 ~arm64 ~riscv"
+fi
+
+DESCRIPTION="The Hare systems programming language"
+HOMEPAGE="https://harelang.org/"
+LICENSE="MPL-2.0 GPL-3"
+
+DEPEND="
+ sys-devel/qbe
+ >=dev-lang/harec-0_pre20220702
+"
+BDEPEND="
+ app-text/scdoc
+"
+RDEPEND="${DEPEND}"
+
+# hare and haredoc are built by hare
+QA_FLAGS_IGNORED="usr/bin/hare usr/bin/haredoc"
+
+src_configure() {
+ local target_arch
+ case ${ARCH} in
+ amd64 ) target_arch=x86_64 ;;
+ arm64 ) target_arch=aarch64 ;;
+ riscv ) target_arch=riscv64 ;;
+ * ) die "unsupported architecture: ${ARCH}" ;;
+ esac
+
+ cp config.example.mk config.mk || die
+ sed -i \
+ -e 's;=aarch64-;=;' \
+ -e 's;=riscv64-;=;' \
+ -e "s;^ARCH =.*;ARCH = ${target_arch};" \
+ -e 's;^PREFIX =.*;PREFIX = /usr;' \
+ -e 's;^AS =;AS ?=;' \
+ -e 's;^LD =;LD ?=;' \
+ -e 's;^AR =;AR ?=;' \
+ config.mk || die
+
+ sed -i 's; $(DESTDIR)$(LOCALSRCDIR);;' Makefile || die
+}