aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authorGeod24 <pro.mathias.lang@gmail.com>2020-03-02 19:46:18 +0900
committerRasmus Thomsen <oss@cogitri.dev>2020-03-02 15:45:53 +0100
commitcd7fd733581bbc264431a3d3fbce04fae44f9962 (patch)
tree9ccf5809913f85a6fc89c1694ba95aeadd7390b8 /testing
parent54bf7758a6123941093b9ba1d36fe46060abb647 (diff)
downloadaports-cd7fd733581bbc264431a3d3fbce04fae44f9962.tar.bz2
aports-cd7fd733581bbc264431a3d3fbce04fae44f9962.tar.xz
testing/dtools: add dustmite
Dustmite is one of the most important tool of the D Programming Language. It can be obtained via dub, but we might as well add it here as well. Also adds a note as to why dman isn't there.
Diffstat (limited to 'testing')
-rw-r--r--testing/dtools/APKBUILD28
1 files changed, 22 insertions, 6 deletions
diff --git a/testing/dtools/APKBUILD b/testing/dtools/APKBUILD
index 89acdda178..635e5ad1c2 100644
--- a/testing/dtools/APKBUILD
+++ b/testing/dtools/APKBUILD
@@ -1,5 +1,13 @@
# Contributor: Mathias LANG <pro.mathias.lang@gmail.com>
# Maintainer: Mathias LANG <pro.mathias.lang@gmail.com>
+#
+# There are 4 'public' tools in the repository as of v2.090.1
+# In addition, there are a few 'build' tools which could be
+# useful (and can be trivially added if needed).
+#
+# Out of those 4 public tools, only 'dman' has heavy dependencies,
+# as it rely on building dlang.org (and by extension DMD & co),
+# so it is excluded from this package.
pkgname=dtools
pkgver=2.090.1
pkgrel=0
@@ -11,21 +19,24 @@ makedepends="ldc"
subpackages="$pkgname-ddemangle $pkgname-rdmd"
source="tools-$pkgver.tar.gz::https://github.com/dlang/tools/archive/v$pkgver.tar.gz"
builddir="$srcdir/tools-$pkgver/"
+_outputdir="$builddir/alpine-build/"
build() {
- ldmd2 -O -release "$builddir/ddemangle.d" -od"$builddir" -ofddemangle
- ldmd2 -O -release "$builddir/rdmd.d" -od"$builddir" -ofrdmd
+ ldmd2 -O -release "$builddir/ddemangle.d" -of"$_outputdir/ddemangle"
+ ldmd2 -O -release "$builddir/DustMite/dustmite.d" "$builddir/DustMite/splitter.d" -of"$_outputdir/dustmite"
+ ldmd2 -O -release "$builddir/rdmd.d" -of"$_outputdir/rdmd"
}
check() {
- ldmd2 -run "$builddir/rdmd_test.d" --rdmd-default-compiler=ldmd2 "$builddir/rdmd"
+ ldmd2 -run "$builddir/rdmd_test.d" --rdmd-default-compiler=ldmd2 "$_outputdir/rdmd"
}
package() {
- depends="$pkgname-ddemangle $pkgname-rdmd"
+ depends="$pkgname-ddemangle $pkgname-dustmite $pkgname-rdmd"
- install -s -D "$builddir/ddemangle" "$pkgdir/usr/bin/ddemangle"
- install -s -D "$builddir/rdmd" "$pkgdir/usr/bin/rdmd"
+ install -s -D "$_outputdir/ddemangle" "$pkgdir/usr/bin/ddemangle"
+ install -s -D "$_outputdir/dustmite" "$pkgdir/usr/bin/dustmite"
+ install -s -D "$_outputdir/rdmd" "$pkgdir/usr/bin/rdmd"
}
ddemangle() {
@@ -33,6 +44,11 @@ ddemangle() {
mv "$pkgdir/usr/bin/ddemangle" "$subpkgdir/usr/bin/ddemangle"
}
+dustmite() {
+ mkdir -p "$subpkgdir/usr/bin/"
+ mv "$pkgdir/usr/bin/dustmite" "$subpkgdir/usr/bin/dustmite"
+}
+
rdmd() {
mkdir -p "$subpkgdir/usr/bin/"
mv "$pkgdir/usr/bin/rdmd" "$subpkgdir/usr/bin/rdmd"