summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2021-08-22 16:14:46 +0300
committerAqua-sama <aqua@iserlohn-fortress.net>2021-08-22 16:14:46 +0300
commiteb65c2653b7c51295cb04f2632a6eccb131f06be (patch)
treee40176c09f5d1584477d5061a8c21fb5865cc2bb
parentUpdate PKGBUILD to support 0.6.0 (diff)
downloadzig-git-eb65c2653b7c51295cb04f2632a6eccb131f06be.tar.xz
grep the version once cmake is configured
Using the git tag yields the latest stable version instead. - run zig tests in check(); use makepkg --nocheck to skip
-rw-r--r--.SRCINFO3
-rw-r--r--PKGBUILD17
2 files changed, 11 insertions, 9 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 2ec1f2a..9b202dd 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = zig-git
pkgdesc = a programming language prioritizing robustness, optimality, and clarity
- pkgver = 0.6.0
+ pkgver = 0.9.0.r844.g4ac37eb48
pkgrel = 1
url = https://ziglang.org
arch = i686
@@ -17,4 +17,3 @@ pkgbase = zig-git
md5sums = SKIP
pkgname = zig-git
-
diff --git a/PKGBUILD b/PKGBUILD
index ff29003..11cb020 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,7 +1,8 @@
-# Maintainer: Marc Tiehuis <marctiehuis at gmail.com>
+# Maintainer: aqua <aqua@iserlohn-fortress.net>
+# Maintainer: (AUR) Marc Tiehuis <marctiehuis at gmail.com>
pkgname=zig-git
-pkgver=0.6.0.r813.g130c7fd23
+pkgver=0.9.0.r844.g4ac37eb48
pkgrel=1
pkgdesc="a programming language prioritizing robustness, optimality, and clarity"
arch=('i686' 'x86_64')
@@ -15,19 +16,21 @@ source=("git+https://github.com/zig-lang/zig.git")
md5sums=('SKIP')
pkgver() {
- git -C zig describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+ mkdir -p build
+ cd build
+ cmake ../zig -DCMAKE_BUILD_TYPE=None -DCMAKE_INSTALL_PREFIX=/usr -DZIG_PREFER_CLANG_CPP_DYLIB=ON > /dev/null
+
+ grep ZIG_VERSION_STRING config.h | sed 's/#define\ ZIG_VERSION_STRING\ //;s/-dev\./.r/;s/+/.g/;s/\"//g'
}
build() {
- mkdir -p build
cd build
- cmake ../zig -DCMAKE_BUILD_TYPE=None -DCMAKE_INSTALL_PREFIX=/usr -DZIG_PREFER_CLANG_CPP_DYLIB=ON
make DESTDIR=.
}
check() {
- # omit full compiler test since it takes ages
- build/zig version
+ cd zig
+ ../build/zig build test
}
package() {