aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlessandro Barbieri <lssndrbarbieri@gmail.com>2020-03-04 02:44:28 +0100
committerAlessandro Barbieri <lssndrbarbieri@gmail.com>2020-03-04 02:44:28 +0100
commitddc30e856ca7ccaf89192d4eb5c809587a75d410 (patch)
tree31ef9ed84e7d5b0b122f0df53b2eae9d777eff0f /dev-lang
parentdev-lang/aldor: Fix S variable (diff)
downloadguru-ddc30e856ca7ccaf89192d4eb5c809587a75d410.tar.gz
guru-ddc30e856ca7ccaf89192d4eb5c809587a75d410.tar.bz2
guru-ddc30e856ca7ccaf89192d4eb5c809587a75d410.zip
dev-lang/aldor: many changes, WIP
Package-Manager: Portage-2.3.91, Repoman-2.3.20 Signed-off-by: Alessandro Barbieri <lssndrbarbieri@gmail.com>
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/aldor/aldor-1.2.0_p20190730.ebuild62
-rw-r--r--dev-lang/aldor/metadata.xml6
2 files changed, 52 insertions, 16 deletions
diff --git a/dev-lang/aldor/aldor-1.2.0_p20190730.ebuild b/dev-lang/aldor/aldor-1.2.0_p20190730.ebuild
index bb79cb1f4..e962d8583 100644
--- a/dev-lang/aldor/aldor-1.2.0_p20190730.ebuild
+++ b/dev-lang/aldor/aldor-1.2.0_p20190730.ebuild
@@ -4,9 +4,8 @@
EAPI="7"
COMMIT="13e5b90eecc79ec6704efb333c4c100187520e80"
-AUTOTOOLS_AUTORECONF=1
-AUTOTOOLS_IN_SOURCE_BUILD=1
+#TODO: figure out if a java eclass is needed
inherit autotools elisp-common
DESCRIPTION="The Aldor Programming Language"
@@ -21,13 +20,24 @@ LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64"
-IUSE="doc emacs"
+IUSE="boehm-gc doc emacs java"
-RDEPEND="
+#is junit dep. only for test?
+#TODO: choose a slot for junit
+CDEPEND="
+ boehm-gc? ( dev-libs/boehm-gc )
emacs? ( app-editors/emacs:= )
+ java? ( dev-java/junit )
+"
+RDEPEND="
+ ${CDEPEND}
+ java? ( virtual/jre:1.8 )
"
DEPEND="
- ${RDEPEND}
+ ${CDEPEND}
+ java? ( virtual/jdk:1.8 )
+"
+BDEPEND="
virtual/yacc
doc? ( virtual/latex-base )
@@ -40,23 +50,42 @@ DOCS=( AUTHORS README.building README.binary-only README.library ../README.md )
src_unpack() {
unpack "${P}.tar.gz"
- use doc && cp "${DISTDIR}/libaldor.pdf.gz" "${S}" && gunzip "${S}/libaldor.pdf.gz" || die
+ if use doc ; then
+ cp "${DISTDIR}/libaldor.pdf.gz" "${S}"
+ gunzip "${S}/libaldor.pdf.gz"
+ fi
use emacs && cp "${DISTDIR}/aldor.el.nw" "${S}" || die
}
+src_prepare() {
+ #TODO: respect CFLAGS and remove Werror
+ eapply_user
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ --disable-static
+ --enable-libraries
+ --enable-shared
+ $(use_enable java)
+ $(use_with java java-junit)
+ $(use_with boehm-gc)
+ )
+ econf "${myconf[@]}"
+}
+
src_compile() {
if use doc ; then
- ( cd aldorug; emake aldorug.pdf ) || die "make aldorug.pdf failed"
- ( cd lib/aldor/tutorial
+ ( cd "${S}/aldorug"; emake aldorug.pdf ) || die "make aldorug.pdf failed"
+ ( cd "${S}/lib/aldor/tutorial"
pdflatex tutorial.tex
pdflatex tutorial.tex ) || die "make tutorial.pdf failed"
- tar xzf "${DISTDIR}/algebra.html.tar.gz"
fi
-
+ cd "${S}"
if use emacs ; then
notangle "aldor.el.nw" > aldor.el
- notangle -Rinit.el "aldor.el.nw" | \
- sed -e '1s/^.*$/;; aldor mode/' > 64aldor-gentoo.el
+ notangle -Rinit.el "aldor.el.nw" | sed -e '1s/^.*$/;; aldor mode/' > 64aldor-gentoo.el
if use doc ; then
einfo "Documentation for the aldor emacs mode"
noweave "aldor.el.nw" > aldor-mode.tex
@@ -64,15 +93,16 @@ src_compile() {
pdflatex aldor-mode.tex || die "make aldor-mode.pdf failed"
fi
fi
+ cd "${S}"
default
}
src_install() {
- if use doc ; then
- DOCS+=( aldorug/aldorug.pdf lib/aldor/tutorial/tutorial.pdf libaldor.pdf )
- fi
+ use doc && DOCS+=( aldorug/aldorug.pdf lib/aldor/tutorial/tutorial.pdf libaldor.pdf )
+
if use emacs ; then
- DOCS+=( aldor-mode.pdf )
+ use doc && DOCS+=( aldor-mode.pdf )
+ #TODO: rename aldor.el
elisp-site-file-install aldor.el
elisp-site-file-install 64aldor-gentoo.el
fi
diff --git a/dev-lang/aldor/metadata.xml b/dev-lang/aldor/metadata.xml
index 4b9f70186..fb2260805 100644
--- a/dev-lang/aldor/metadata.xml
+++ b/dev-lang/aldor/metadata.xml
@@ -11,4 +11,10 @@ The Aldor language combines imperative, functional, and object-oriented features
<upstream>
<remote-id type="github">pippijn/aldor</remote-id>
</upstream>
+ <use>
+ <flag name="boehm-gc">Use Boehm Garbage Collector instead of built-in</flag>
+ </use>
+
+
+
</pkgmetadata>