diff options
author | George Rawlinson | 2023-09-28 07:37:41 +0000 |
---|---|---|
committer | George Rawlinson | 2023-09-28 07:37:41 +0000 |
commit | 6c4b803ac22419fb85e58ada8a81dc37b0ca904d (patch) | |
tree | f39ec8d75b9a1e76f57d3dda6826e4861d2edc37 | |
download | aur-6c4b803ac22419fb85e58ada8a81dc37b0ca904d.tar.gz |
addpkg: uiua
-rw-r--r-- | .SRCINFO | 17 | ||||
-rw-r--r-- | PKGBUILD | 54 |
2 files changed, 71 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..a24a5570260e --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,17 @@ +pkgbase = uiua + pkgdesc = An array-oriented stack programming language + pkgver = r1249.g1ec1901 + pkgrel = 1 + url = https://www.uiua.org + arch = x86_64 + license = MIT + makedepends = git + makedepends = rust + depends = glibc + depends = gcc-libs + depends = alsa-lib + options = !lto + source = uiua::git+https://github.com/uiua-lang/uiua#commit=1ec1901eae24f75343af2ae02df36b5dc131c8ba + b2sums = SKIP + +pkgname = uiua diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..430eb17e5fda --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,54 @@ +# Maintainer: George Rawlinson <grawlinson@archlinux.org> + +pkgname=uiua +pkgver=r1249.g1ec1901 +pkgrel=1 +pkgdesc='An array-oriented stack programming language' +arch=('x86_64') +url='https://www.uiua.org' +license=('MIT') +depends=('glibc' 'gcc-libs' 'alsa-lib') +makedepends=('git' 'rust') +options=('!lto') +_commit='1ec1901eae24f75343af2ae02df36b5dc131c8ba' +source=("$pkgname::git+https://github.com/uiua-lang/uiua#commit=$_commit") +b2sums=('SKIP') + +pkgver() { + cd "$pkgname" + + printf 'r%s.g%s' "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +prepare() { + cd "$pkgname" + + # download dependencies + cargo fetch --locked --target "$CARCH-unknown-linux-gnu" +} + +build() { + cd "$pkgname" + + cargo build --frozen --release --all-features +} + +check() { + cd "$pkgname" + + cargo test --frozen --all-features +} + +package() { + cd "$pkgname" + + # binary + install -vDm755 -t "$pkgdir/usr/bin" "target/release/$pkgname" + + # documentation + install -vDm644 -t "$pkgdir/usr/share/doc/$pkgname" readme.md + cp -vr site "$pkgdir/usr/share/doc/$pkgname" + + # license + install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" license +} |