summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO9
-rw-r--r--PKGBUILD20
-rw-r--r--install5
-rwxr-xr-xstart-stanza.sh3
4 files changed, 23 insertions, 14 deletions
diff --git a/.SRCINFO b/.SRCINFO
index d6c695fa72a6..0c87a52dba03 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,16 +1,19 @@
# Generated by mksrcinfo v8
-# Sat Sep 30 07:05:51 UTC 2017
+# Mon Oct 2 08:17:03 UTC 2017
pkgbase = stanza
- pkgdesc = The reference compiler for Stanza, a high-level multi-paradigm optionally typed programming language.
+ pkgdesc = The reference compiler for Stanza, a high-level multi-paradigm optionally-typed programming language.
pkgver = 0.11.7
- pkgrel = 1
+ pkgrel = 2
url = http://lbstanza.org/
install = install
arch = x86_64
license = GPL
+ depends = gcc5
noextract = lstanza_0_11_7.zip
source = http://lbstanza.org/resources/stanza/lstanza_0_11_7.zip
+ source = start-stanza.sh
sha256sums = 87f59bf4ad42c76bee7b141fc860c79ee39890acbcf46effec58cb0a17350ffb
+ sha256sums = 0439b9637691d406cec99e74d22c7899e4368954c99746b35a21fbc5f98dbe21
pkgname = stanza
diff --git a/PKGBUILD b/PKGBUILD
index 73155bf2e279..805d6ff02224 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,14 +2,15 @@
pkgname='stanza'
pkgver='0.11.7'
-pkgrel=1
-pkgdesc='The reference compiler for Stanza, a high-level multi-paradigm optionally typed programming language.'
+pkgrel=2
+pkgdesc='The reference compiler for Stanza, a high-level multi-paradigm optionally-typed programming language.'
arch=('x86_64')
groups=()
url='http://lbstanza.org/'
license=('GPL')
depends=(
+ 'gcc5'
)
makedepends=(
)
@@ -23,17 +24,21 @@ conflicts=(
_srcfile='lstanza_0_11_7.zip'
source=(
"http://lbstanza.org/resources/stanza/$_srcfile"
+ 'start-stanza.sh'
)
-noextract=("$_srcfile")
-sha256sums=('87f59bf4ad42c76bee7b141fc860c79ee39890acbcf46effec58cb0a17350ffb')
+noextract=("$_srcfile") # Don't extract. Archive is weird. See prepare().
+sha256sums=('87f59bf4ad42c76bee7b141fc860c79ee39890acbcf46effec58cb0a17350ffb'
+ '0439b9637691d406cec99e74d22c7899e4368954c99746b35a21fbc5f98dbe21')
install='install'
prepare() {
+ # Archive has no parent folder. Make one.
if [[ -d "$pkgname" ]]; then
rm -r "$pkgname"
fi
mkdir "$pkgname"
+ # OK, now extract.
cd "$pkgname"
bsdtar xf "$srcdir/$_srcfile"
}
@@ -45,6 +50,9 @@ package() {
mkdir "$pkgdir/opt"
cp -pr "$srcdir/$pkgname" "$pkgdir/opt"
- mkdir -p "$pkgdir/usr/bin"
- ln -s "/opt/$pkgname/stanza" "$pkgdir/usr/bin/stanza"
+ install -D "$srcdir/start-stanza.sh" "$pkgdir/usr/bin/stanza"
+
+ # For redirecting stanza from gcc 7 to gcc 5.
+ mkdir "$pkgdir/opt/stanza/bin"
+ ln -s "/usr/bin/gcc-5" "$pkgdir/opt/stanza/bin/cc"
}
diff --git a/install b/install
index 29fc8a2e4c06..ab65cb45ff95 100644
--- a/install
+++ b/install
@@ -1,16 +1,11 @@
#!/bin/bash
message='NOTE: If stanza fails with the error message
-
Could not locate .stanza configuration file.
-
then run the command (NOT AS ROOT!)
-
$ cd /opt/stanza && stanza install -platform linux
-
to generate ~/.stanza. The command must be run with current directory
/opt/stanza, or else it will fail with the error message
-
Could not determine Stanza installation directory.'
# arg 1: the new package version
diff --git a/start-stanza.sh b/start-stanza.sh
new file mode 100755
index 000000000000..04e3f9e85b2c
--- /dev/null
+++ b/start-stanza.sh
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+PATH="/opt/stanza/bin:$PATH" exec /opt/stanza/stanza "$@"