diff options
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | PKGBUILD | 35 |
2 files changed, 49 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 0000000..407a3ab --- /dev/null +++ b/.SRCINFO | |||
@@ -0,0 +1,14 @@ | |||
1 | pkgbase = efm-langserver | ||
2 | pkgdesc = General purpose Language Server | ||
3 | pkgver = 0.0.22 | ||
4 | pkgrel = 1 | ||
5 | url = https://github.com/mattn/efm-langserver | ||
6 | arch = x86_64 | ||
7 | license = MIT | ||
8 | makedepends = go | ||
9 | depends = glibc | ||
10 | source = https://github.com/mattn/efm-langserver/archive/v0.0.22/efm-langserver-v0.0.22.tar.gz | ||
11 | b2sums = 5f29002c3fd80a759102201fac9e973dfe134cab53c96ace10b8a6d06dd690141b0f2e867174a634492c3c5eb87c2f389393a13ced4cb87d1c3781b58b946740 | ||
12 | |||
13 | pkgname = efm-langserver | ||
14 | |||
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..38e654a --- /dev/null +++ b/PKGBUILD | |||
@@ -0,0 +1,35 @@ | |||
1 | # Maintainer: Daniel M. Capella <polyzen@archlinux.org> | ||
2 | # Contributor: dianlujitao <dianlujitao at gmail dot com> | ||
3 | |||
4 | pkgname=efm-langserver | ||
5 | pkgver=0.0.22 | ||
6 | pkgrel=1 | ||
7 | pkgdesc='General purpose Language Server' | ||
8 | arch=('x86_64') | ||
9 | url=https://github.com/mattn/efm-langserver | ||
10 | license=('MIT') | ||
11 | depends=('glibc') | ||
12 | makedepends=('go') | ||
13 | source=("$url/archive/v$pkgver/$pkgname-v$pkgver.tar.gz") | ||
14 | b2sums=('5f29002c3fd80a759102201fac9e973dfe134cab53c96ace10b8a6d06dd690141b0f2e867174a634492c3c5eb87c2f389393a13ced4cb87d1c3781b58b946740') | ||
15 | |||
16 | build() { | ||
17 | cd $pkgname-$pkgver | ||
18 | export CGO_CPPFLAGS="$CPPFLAGS" | ||
19 | export CGO_CFLAGS="$CFLAGS" | ||
20 | export CGO_CXXFLAGS="$CXXFLAGS" | ||
21 | export CGO_LDFLAGS="$LDFLAGS" | ||
22 | export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw" | ||
23 | go build . | ||
24 | } | ||
25 | |||
26 | check() { | ||
27 | cd $pkgname-$pkgver | ||
28 | go test -v ./... | ||
29 | } | ||
30 | |||
31 | package() { | ||
32 | cd $pkgname-$pkgver | ||
33 | install -Dt "$pkgdir"/usr/bin efm-langserver | ||
34 | install -Dm644 -t "$pkgdir"/usr/share/licenses/$pkgname README.md # Only mention of license | ||
35 | } | ||