summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 76bc161469b4e279aab3453a00f1c8d3063fc239 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
pkgname=kakoune-git
pkgver=2023.08.05
pkgrel=2
pkgdesc="Multiple-selection, UNIX-flavored modal editor"
arch=("x86_64" "armv7h")
url="https://github.com/mawww/kakoune"
license=("custom:unlicense")
depends=("gcc-libs")
optdepends=(
    "aspell: spell check, correct text"
    "clang: error reporting and diagnostics, completion"
    "ctags-git: complete and describe a symbol, jump to its definition"
    "editorconfig-core-c: set formatting options project-wide"
    "git: display and cycle through hunks, blame lines, handle file status"
    "kak-lsp: Language Server Protocol (LSP) client"
    "tmux: split windows, spawn tabs"
    "xdotool: X11 window management"
    "xorg-xmessage: print detailed crash information in a separate window"
)
makedepends=(
    "git"
)
provides=("kakoune=${pkgver}")
conflicts=("kakoune")
source=("${pkgname}::git+https://github.com/mawww/kakoune.git")
sha256sums=("SKIP")
options=("!buildflags")

pkgver() {
    cd "${srcdir}/${pkgname}"
    git describe --tags | tr "-" "_" | sed "s/^v//; s/_/_r/"
}

check() {
    cd "${srcdir}/${pkgname}"
    make test
}

build() {
    cd "${srcdir}/${pkgname}"
    make
}

package() {
    cd "${srcdir}/${pkgname}"
    make install-strip DESTDIR="${pkgdir}" PREFIX=/usr libexecdir="${pkgdir}"/usr/lib/kak
    install -D UNLICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}