[arch-commits] Commit in zig/repos (2 files)
Daurnimator
daurnimator at archlinux.org
Tue Apr 14 14:53:54 UTC 2020
Date: Tuesday, April 14, 2020 @ 14:53:54
Author: daurnimator
Revision: 614069
archrelease: copy trunk to community-staging-x86_64
Added:
zig/repos/community-staging-x86_64/
zig/repos/community-staging-x86_64/PKGBUILD
(from rev 614068, zig/trunk/PKGBUILD)
----------+
PKGBUILD | 43 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 43 insertions(+)
Copied: zig/repos/community-staging-x86_64/PKGBUILD (from rev 614068, zig/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD (rev 0)
+++ community-staging-x86_64/PKGBUILD 2020-04-14 14:53:54 UTC (rev 614069)
@@ -0,0 +1,43 @@
+# Maintainer: Daurnimator <daurnimator at archlinux.org>
+# Contributor: Marc Tiehuis <marctiehuis at gmail.com>
+
+pkgname=zig
+pkgver=0.6.0
+pkgrel=1
+pkgdesc='a general-purpose programming language and toolchain for maintaining robust, optimal, and reusable software'
+arch=('x86_64')
+url='https://ziglang.org/'
+license=('MIT')
+depends=('clang' 'llvm-libs' 'lld')
+makedepends=('cmake' 'llvm')
+source=("https://ziglang.org/download/$pkgver/zig-$pkgver.tar.xz")
+sha256sums=('5d167dc19354282dd35dd17b38e99e1763713b9be8a4ba9e9e69284e059e7204')
+
+build() {
+ cd "$pkgname-$pkgver"
+
+ mkdir -p build
+ cd build
+ # The zig CMakeLists uses build type Debug if not set
+ # override it back to None so makepkg env vars are respected
+ cmake \
+ -DCMAKE_BUILD_TYPE=None \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DZIG_PREFER_CLANG_CPP_DYLIB=ON \
+ ..
+ make
+}
+
+check() {
+ cd "$pkgname-$pkgver/build"
+
+ ./zig build test
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+
+ install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+
+ make -C build DESTDIR="$pkgdir" install
+}
More information about the arch-commits
mailing list